渗透思路:
nmap扫描----通过robots.txt得到/dev_shell目录----利用RCE得到反弹shell----找到.gpg文件密码并解密----sudo su提权
环境信息:
靶机:192.168.101.63
攻击机:192.168.101.34
具体步骤:
1、nmap扫描
sudo nmap -sV -sC -p- 192.168.101.63
扫描到2个端口:80(http)、25468(ssh)
2、利用RCE得到反弹shell
注意到nmap扫描http端口的时候扫描到了robots.txt,其中有4个disallowed entries:
/login.php、 /dev_shell.php、 /lat_memo.html 、/passwords.html
一一访问这几个页面,发现其中http://192.168.101.63/dev_shell.php可以执行系统命令
不幸的是,很多命令都是不让执行的,比如ls