Metasploit Cheat Sheet

To supplement the courses in our Cyber Security Career Development Platform, here is our ​Metasploit Cheat Sheet.

You may download the PDF version of this cheat sheet here.

Networking Commands

ipconfig:Show network interface configuration
portfwd:Forward packets
route:View / edit network routing table

Meterpreter Commands

sysinfoDisplay system in formation
psList and display running processes
kil​l (PID)Terminate a running process
getuidDisplay user ID
upload or downloadUpload / download a file
pwd or lpwdPrint working directory ( local / remote)
cd or lcdChange directory ( local or remote)
catDisplay file content
bglistshow background running scripts
bgrunmake a script run in the background
bgkillterminate a background process
backgroundMove active session to background
edit <FILE Name>Edit a file in vi editor
shellAccess shell on the target machine
migrate <PID>Switch to another process
idletimeDisplay idle time of user
screenshotTake a screenshot
clearevClear the system logs
? or HelpHelp sho​wing all the commands
exit / quit :Exit the Meterpreter session
shutdown / rebootRestart the system
useExtension load
channelShow active channels

Process Handling Commands

getpid:Display the process ID
getuid:Display the user ID
ps:Display running process
Kill:Stop and terminate a process
getprivsShows multiple privileges as possible
regAccess target machine registry
ShellAccess target machine shell
execute:Run a specified
migrate:Move to a given destination process ID

Interface / Output Commands

enumdesktopsShow all available desktops
GetdesktopDisplay current desktop
keyscan_ startStart keylogger in target macahine
Keyscan_ stopStop keylogger in target machine
set _desktopConfigure desktop
keyscan_dumpDump keylogger content

Password Management Commands

hashdumpAccess content of password file – Hash file

MSF Venom Command Options

-p– p (Payload option)Display payload standard options
– l– l ( list type)List module type i .e payload, encoders
– f– f ( format )output format
– e-e (encoder)Define which encoder to use
-a– a (Architecture or platformDefine which platform to use
-s-s (Space)Define maximum payload capacity
-b-b (characters)Define set of characters not to use
– i– i (Number of times)Define number of times to use encoder
-x-x (File name)Define a custom file to use as template
– o-o (output)Save a payload
– h-hHelp
  • Alishia says:

    Metasploit is an important aid in penetration testing and using it pen testing teams can detect weak spots in a network. Thanks Nathan for sharing this cheat sheet.

  • Milciades says:

    This is a great information. I need to learn more about Metasploit. At the present time I am completing one of your courses. Great course. Thanks.

  • Anthony Wade Nelson-Bey says:



  • >