Installing Metasploit
Installing Metasploit
http://www.darkoperator.com/installing-metasploit-in-ubunt/
HELL
I O N LY
THE
BEGINNING
When getting shell is only the start of the journey.
BLOG
I N F O E C TA C T I C O P O D C A T
BLOG ERIE
EARCH
M F I N TA L L AT I O N G U I D E
PROJECT
ABOUT ME
1 of 8
23 09:06 2016 ,
http://www.darkoperator.com/installing-metasploit-in-ubunt/
Installing Dependencie
We start b making sure that we have the latest
packages b updating the sstem using apt-get:
2 of 8
23 09:06 2016 ,
http://www.darkoperator.com/installing-metasploit-in-ubunt/
cd ~
git clone git://github.com/sstephenson/rbenv.git
.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >>
~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
exec $SHELL
3 of 8
23 09:06 2016 ,
http://www.darkoperator.com/installing-metasploit-in-ubunt/
exec $SHELL
Installing Nmap
One of the external tools that Metasploit uses for
scanning that is not included with the sources is Nmap.
Here we will cover downloading the latest source code
for Nmap, compiling and installing:
mkdir ~/Development
cd ~/Development
svn co https://svn.nmap.org/nmap
cd nmap
./configure
make
sudo make install
make clean
4 of 8
23 09:06 2016 ,
http://www.darkoperator.com/installing-metasploit-in-ubunt/
sudo -s
su postgres
createuser msf -P -S -R -D
createdb -O msf msf
exit
exit
cd /opt
sudo git clone https://github.com/rapid7/metasploitframework.git
sudo chown -R `whoami` /opt/metasploit-framework
cd metasploit-framework
cd metasploit-framework
5 of 8
23 09:06 2016 ,
http://www.darkoperator.com/installing-metasploit-in-ubunt/
cd metasploit-framework
sudo bash -c 'for MSF in $(ls msf*); do ln -s
/opt/metasploit-framework/$MSF /usr/local
/bin/$MSF;done'
6 of 8
23 09:06 2016 ,
http://www.darkoperator.com/installing-metasploit-in-ubunt/
curl -# -o /tmp/armitage.tgz
http://www.fastandeasyhacking.com/download/armitagelatest.tgz
sudo tar -xvzf /tmp/armitage.tgz -C /opt
sudo ln -s /opt/armitage/armitage /usr/local
/bin/armitage
sudo ln -s /opt/armitage/teamserver /usr/local
/bin/teamserver
sudo sh -c "echo java -jar /opt/armitage
/armitage.jar \$\* > /opt/armitage/armitage"
sudo perl -pi -e 's/armitage.jar/\/opt\/armitage
\/armitage.jar/g' /opt/armitage/teamserver
production:
adapter: postgresql
database: msf
username: msf
password:
host: 127.0.0.1
port: 5432
pool: 75
7 of 8
23 09:06 2016 ,
http://www.darkoperator.com/installing-metasploit-in-ubunt/
timeout: 5
source /etc/profile
First Run
Now we are read to run Metasploit for the first time. M
recommendation is to run it first under a regular user so
the folders create under our home director have the
proper permissions. First time it runs it will create the
entries needed b Metasploit in the database so it will
take a while to load.
msfconsole
8 of 8
23 09:06 2016 ,