<?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 tehooo on Medium]]></title>
        <description><![CDATA[Stories by tehooo on Medium]]></description>
        <link>https://medium.com/@tehoooo12?source=rss-6aff1f079ca3------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*cI9qy9rCRFmPedfa</url>
            <title>Stories by tehooo on Medium</title>
            <link>https://medium.com/@tehoooo12?source=rss-6aff1f079ca3------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 23 Nov 2026 02:15:47 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@tehoooo12/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[RootMe — TryHackMe room]]></title>
            <link>https://medium.com/@tehoooo12/rootme-tryhackme-room-f136b904faa7?source=rss-6aff1f079ca3------2</link>
            <guid isPermaLink="false">https://medium.com/p/f136b904faa7</guid>
            <category><![CDATA[tryhackme-writeup]]></category>
            <category><![CDATA[tryhackme-rootme]]></category>
            <category><![CDATA[tryhackme]]></category>
            <category><![CDATA[ctf-writeup]]></category>
            <category><![CDATA[ctf]]></category>
            <dc:creator><![CDATA[tehooo]]></dc:creator>
            <pubDate>Mon, 26 Oct 2026 12:16:01 GMT</pubDate>
            <atom:updated>2026-10-26T12:16:01.610Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/411/1*rp6a-MU1c_UAr3ifEK6fmQ.png" /><figcaption>A ctf for beginners, can you root me?</figcaption></figure><p><strong>Reconnaissance</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/657/1*eRRoydLi1iYc5vumfVXFFg.png" /><figcaption>nmap -sC -sV 10.48.139.132</figcaption></figure><p>The scan reveals two open services: SSH on port 22 and HTTP on port 80.</p><ul><li>Scan the machine, how many ports are open? <strong>2</strong></li><li>What version of Apache is running? <strong>2.4.41</strong></li><li>What service is running on port 22? <strong>ssh</strong></li></ul><blockquote><a href="http://10.48.139.132/">http://10.48.139.132</a></blockquote><p>This website doesn’t have much inside it.</p><p><strong>Enumeration</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/659/1*zrO-Ov90_KarU6ya9BkUNw.png" /><figcaption>gobuster dir -u <a href="http://10.48.139.132/">http://10.48.139.132</a> -w /usr/share/wordlists/dirb/common.txt</figcaption></figure><p>Lets take a look at /panel</p><ul><li>What is the hidden directory? <strong>/panel</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*OntHKcuu0ykumfOOoiNnsA.png" /><figcaption><a href="http://10.48.139.132/panel/">http://10.48.139.132/panel/</a></figcaption></figure><p>This upload point gives us an easy path to code execution. I’ll be using <a href="https://github.com/pentestmonkey/php-reverse-shell/blob/master/php-reverse-shell.php"><strong>Pentest Monkey’s</strong> PHP reverse shell</a>.</p><blockquote><a href="https://github.com/pentestmonkey/php-reverse-shell/blob/master/php-reverse-shell.php">https://github.com/pentestmonkey/php-reverse-shell/blob/master/php-reverse-shell.php</a></blockquote><p>I modified the script to use my IP and a port of my choice, 6900.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/766/1*swVViMrfLDm15BwtPIgqtA.png" /><figcaption>PHP file upload</figcaption></figure><p>I attempted to upload the PHP script, but the website did not allow it. After some research, I found a workaround by saving the script as an phtml instead of php.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/765/1*87Au1gJ-4kCKj2QEc9bGuA.png" /><figcaption>phtml file upload</figcaption></figure><p>The script saved as a phtml file worked! Now that the shell is on the server, we just have to catch the callback. Start a listener, navigate to the file, and trigger it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/767/1*ano7NAhOpqhR8F9nK3mTdg.png" /><figcaption><a href="http://10.48.139.132/uploads/">http://10.48.139.132/uploads/</a></figcaption></figure><p>We have a shell now!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/818/1*Mw2klMaL4P8vog9qAqFxEg.png" /></figure><p><strong>Finding the user flag</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/518/1*SxIHl_bxzuZJZNTKPbhmbQ.png" /><figcaption>THM{y0u_g0t_a_sh3ll}</figcaption></figure><ul><li>user.txt? <strong>THM{y0u_g0t_a_sh3ll}</strong></li></ul><p><strong>Privilege escalation</strong></p><p>Next, we need to enumerate binaries with the SUID bit set.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/663/1*C-31GlTTOwy8D_kG5505QQ.png" /><figcaption>find / -user root -perm /4000 2&gt; /dev/null</figcaption></figure><p>Python with SUID set is an unusual find and an obvious target.</p><ul><li>Search for files with SUID permission, which file is weird? <strong>/usr/bin/python</strong></li></ul><p>Time to check <a href="https://gtfobins.github.io/#">GTFOBins </a>for an SUID bypass payload.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/810/1*-OqM3BJUKgtFv8c2utqYbQ.png" /></figure><p>Just like that, we have root access!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/526/1*aHvdIU3xBGgaa7ewI2j_Aw.png" /></figure><ul><li>root.txt? <strong>THM{pr1v1l3g3_3sc4l4t10n}</strong></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f136b904faa7" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>