安装

sudo curl https://raw.githubusercontent.com/rapid7/metasploit-omnibus/master/config/templates/metasploit-framework-wrappers/msfupdate.erb > msfinstall && \
  chmod 755 msfinstall && \
  ./msfinstall

安装完成后

$ ls /opt/metasploit-framework/bin                                   [21:32:03]
metasploit-aggregator msfelfscan            msfrpc
msfbinscan            msfmachscan           msfrpcd
msfconsole            msfpescan             msfupdate
msfd                  msfremove             msfvenom
msfdb                 msfrop

执行

$ /opt/metasploit-framework/bin/msfconsole

 ** Welcome to Metasploit Framework Initial Setup **
    Please answer a few questions to get started.

Would you like to add msfconsole and other programs to your default PATH? y
You may need to start a new terminal or log in again for this to take effect.

Would you like to use and setup a new database (recommended)? y
Creating database at /Users/kerwin/.msf4/db
Starting database at /Users/kerwin/.msf4/db...success
Creating database users
Creating initial database schema

       =[ metasploit v4.17.3-dev-0139f123a1301b6eb806ca7ad04b5144a3f2335a]
+ -- --=[ 1795 exploits - 1019 auxiliary - 310 post       ]
+ -- --=[ 538 payloads - 41 encoders - 10 nops            ]
+ -- --=[ Free Metasploit Pro trial: http://r-7.co/trymsp ]

msf >

创建快捷方式

$ sudo ln -s /opt/metasploit-framework/bin/msfconsole /usr/bin/msfconsole

最后修改:2022 年 09 月 07 日
-