TryHackMe : OVERPASS Walkthrough
Task 1
Deploy the machine after connecting to openvpn.
Lets Dig in.
Scan for the open ports.
then we got http and ssh as open port. now I am going look http site with this ip.
In this I can’t find anything helpful so I decided to look for hidden directories with help of gobuster.
That’s interesting I got an admin panel (/admin).
so lets see what in there
it is a login page so I tried default credential and SQLi to get logged in
that not works anymore here.😪
Finally I decided to check the response of this request using burp suit repeater.
here we go… the request seems 200 ok but it fails to login which means there is no proper validation.
So I changed the response from first captured request in proxy and forward it by Do intercept option in burp suit as you see below.
and refreshed the page after forwarding the response (turn of the proxy before refreshing).
We got a RSA key of user james. lets connect it through ssh .
RSA connection procedures
- Save the RSA as a text file.
- change the permission into 600. chmod 600 filename
Now try to connect it..
there is a problem we need a passphrase for this RSA key.
Get Solocoderider’s stories in your inbox
Join Medium for free to get updates from this writer.
For that we use ssh2john.py it will change this into an hash and we can crack it with john the ripper.
Now crack this with john.
try to login with this key and passphrase.
We get in successfully. lets read the user.txt
Its Time To Escalate
For this we looking for cron-job.
We are lucky because here root running a cron-job to curl into a hosted service if we can duplicate the hosts in our machine we can execute a reverse shell of root.
We making a directors and file exactly like in cron-job.
and write a script for reverse shell, Then host a python server in parent folder
Now its time to change IP in overpass machine to our server’s IP which is our tunneling IP.
open a new tab and start netcat listner on port 1234
Yess we got the root shell.🥳
check for the flag.
Enter user flag and root flag in tryhackme and complete the challange.
Thank you for reading this writeup. Hope you understand how we get complete. follow me Instagram for updates of latest security reports.









