Brooklyn99 CTF (THM)
————————————————————————————————————————————————————————————————————————————————————————
Nmap Scan
I found a ftp server running at port 21, SSH server running at port 22, and a web server at port 80
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
Enumerating Web Server
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
Login into FTP (using anonymous login)
I got file ‘’note_to_jake.txt’’ and downloaded it into my local machine
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
Reading the ‘note’
————————————————————————————————————————————————————————————————————————————————————————
So I got a username and we know that password is weak after reading the note
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
Brute Forcing Using Hydra
————————————————————————————————————————————————————————————————————————————————————————
Finally I got a ‘’password’’ using brute-forcing. Let’s login into ssh.
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
Login Into SSH
————————————————————————————————————————————————————————————————————————————————————————
I could not find the user flag as I can’t access other user directories.
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
PrivEssc
I found out that as ‘’Jake’’. I can run ‘’less’’ binary as superuser.
————————————————————————————————————————————————————————————————————————————————————————
I found the command on GTFO bin website and finally got the root shell.
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
————————————————————————————————————————————————————————————————————————————————————————
Last updated
Was this helpful?