top of page
Search

TryHackMe! Fowsniff CTF!

  • Writer: Srivathsa Dhanvantri
    Srivathsa Dhanvantri
  • Aug 29, 2020
  • 2 min read

TryHackMe is an online platform that teaches Cybersecurity through hands-on virtual labs. Whether you are an expert or beginner, learn through a virtual room structure to understand theoretical and practical security elements.

ree

Fowsniff CTF is an easy room on TryHackMe for beginners to explore.

You have to first signup to join the room. There are few simple steps that you can follow in the Signup page. Next follow the steps in the Welcome room to configure the VPN connectivity.


I have connected to TryHackMe network using OpenVPN on Kali Linux. Once you connect, the access page will confirm the status by confirming your IP address and status.

ree

Click on Deploy to start the target machine.

ree

The IP address of the target is displayed.

Start Enumeration using nmap. The -sV option will do a service fingerprinting. - A is for aggressive scan. -p- will check all the ports.

ree

From the scan result, it can be seen that port 80 is open and Apache server is running. Let us start checking each of these services listed in nmap scan result. Explore http service using a web browser.

ree

There is a message on the web page that the website is down temporarily. It is always a good idea to check page source.

ree

Looks like blackhat hackers have attacked the website and also taken over their twitter account. And the attackers may have uploaded sensitive information on twitter account. Please check the twitter account.

ree

There is a post on twitter account by attackers that passwords have been posted on pastebin site. Check the pastebin site by following the link posted on twitter.

ree

Note down all the credentials leaked on pastebin. From the nmap scan results we had seen that port 110 is also open and it is running pop3 service. Explore the pop3 service using netcat.

ree

User seina's credentials worked and we are able to see the messages in the inbox. Check all the messages to find more information.

ree

From the first email in the inbox, we can see a temporary password for SSH. Note it down. The SSH for siena or stone didn't work. Check the second message.

ree

The second email is from baksteen. Probably another user. Try doing ssh using baksteen and the password from first email.

ree

You are able to login as baksteen. Now run sudo -l command to check if the user has sudo permissions on this machine.

The sudo -l revealed that baksteen is not a sudo user. Get more information about the target machine using uname.

ree

uname revealed the kernel version. Check if there are any exploits available on exploit-db for this kernel version to escalate privilege.

ree

The google search result revealed there seems to be an exploit.

ree

Download the exploit from the exploit db. Use gcc to compile the c program.

ree

Start a python server on your Kali or whichever machine you are using for attacking.

ree

Using wget command, download the complied code on the target machine. Give execution permissions to the downloaded exploit file using chmod command. Execute the exploit.

ree

Note the root shell has been obtained. Check what's in root's home directory. By now you would have got all the answers for the questions in the TryHackMe room.

Congratulations!! you solved this room.

ree

I hope this write-up was informative for you. Please leave a feedback. Thank you

-Srivathsa Dhanvantri

 
 
 

Comments


©2025 by Srivathsa.

bottom of page