标签:ubuntu metasploit msf postgres sql
metasploit是一款非常优秀/流行的渗透测试框架,介绍一下它在ubuntu下的安装
1 安装metasploit
curl https://raw.githubusercontent.com/rapid7/metasploit-omnibus/master/config/templates/metasploit-framework-wrappers/msfupdate.erb > msfinstall chmod 755 msfinstall ./msfinstall
以上的三条命令,在metasploit官网上就这样提供的。
2 安装postgresql数据库
apt-get install postgresql su - postgres psql
metasploit会使用到postgres sql数据库,因此需要进行安装。
3 msf的启动
msfconsole
首次进入msf后会提示建立数据库,建立一个名为msf的数据库。
4 连接数据库
db_connect postgres:postgres@127.0.0.1/msf db_status
db_connect是用于连接postgres数据库,这里命令的结构如下:
db_connect postgres用户名:postgres密码@主机地址/数据库名
db_status用于查看连接数据库的状态
在安装metasploit或postgres sql时,可能会报错,报错如下:
Unable to locate package
如果报该错误的话,那么执行以下的命令
sudo apt-get update
在安装完postgres sql后会自动创建一个用户postgres,默认是没有密码的,可以通过如下命令修改postgres sql的密码
xxx@ubuntu:~$ su - postgres Password: su: Authentication failure $ sudo passwd postgres Enter new UNIX password: Retype new UNIX password: passwd: password updated successfull
本文出自 “无觉的BLoG” 博客,请务必保留此出处http://wujue.blog.51cto.com/11999347/1872395
标签:ubuntu metasploit msf postgres sql
原文地址:http://wujue.blog.51cto.com/11999347/1872395