Exploitationmetasploitpayloadmeterpretermsfvenomreversebind

MSFvenom Payload Creator (MSFPC)

MSFvenom Payload Creator (MSFPC) is a quick way to generate various basic Meterpreter payloads using msfvenom from the Metasploit framework. It automates payload creation with options for different platforms, connection types, and protocols.

Description

MSFPC simplifies the generation of Meterpreter payloads for penetration testing and red team operations. It supports multiple payload types including Windows executables, Linux ELF binaries, APK files, and various scripting languages like Bash, Perl, and Python. Users can specify target platforms, IP addresses or interfaces, ports, and connection directions (bind or reverse) to create tailored payloads.

The tool is particularly useful for generating staged or stageless payloads that communicate over TCP, HTTP, HTTPS, or by finding open ports. It defaults to reverse connections on port 443 using the eth0 interface IP when parameters are omitted, making it convenient for rapid payload deployment. Generated payloads include corresponding Metasploit handler resource files (.rc) for easy listener setup.

Common use cases include creating Windows Meterpreter shells for bind or reverse connections, Linux payloads, and multi-platform batches for comprehensive testing scenarios. MSFPC handles interface detection and provides verbose output for detailed command construction and file information like size, MD5, and SHA1 hashes.

How It Works

MSFPC constructs msfvenom commands based on user-specified parameters for payload type (e.g., windows/meterpreter/reverse_tcp), architecture (x86), encoding (generic/none), format (exe, elf), LHOST/LPORT, and staging (staged/stageless). It detects IP addresses from network interfaces like eth0 or wan, defaults to reverse_tcp on port 443, and generates both the payload executable and an MSF handler .rc file. Communication protocols include raw TCP, HTTP/HTTPS for evasion, or FIND_PORT to scan for outbound paths, with staged payloads relying on Metasploit for second-stage download.

Installation

bash
sudo apt install msfpc

Flags

<TYPE>Payload type: APK, ASP, ASPX, Bash [.sh], Java [.jsp], Linux [.elf], OSX [.macho], Perl [.pl], windows, and more
<DOMAIN/IP>Target domain or IP address; use interface name (eth0, wan) for auto-detection or omit for IP menu
<PORT>Listener port; defaults to 443 if omitted
<CMD/MSF>CMD for standard shell or MSF for Metasploit shell; defaults to MSF where possible
<BIND/REVERSE>BIND opens port on target, REVERSE connects back to attacker; defaults to REVERSE
<STAGED/STAGELESS>STAGED for smaller multi-part payloads, STAGELESS for standalone; defaults to STAGED where possible
<TCP/HTTP/HTTPS/FIND_PORT>Connection method: TCP (raw), HTTP/HTTPS (protocol masquerade), FIND_PORT (port scanning); defaults to TCP
<BATCH/LOOP>BATCH generates all combinations, LOOP creates one of each type
verboseDisplay more detailed information during execution

Examples

Semi-interactively create a Windows Meterpreter bind shell on port 5555 with verbose output
msfpc windows bind 5555 verbose
Automatically generate a Windows reverse Meterpreter payload using eth0 interface IP on default port 443
msfpc windows eth0
Generate Linux ELF bind payload using eth0 IP on port 4444
msfpc elf bind eth0 4444
Create stageless Python command shell payload using HTTPS
msfpc stageless cmd py https
Generate one payload of each type using eth1 interface IP with verbose output
msfpc verbose loop eth1
Generate all possible Meterpreter payloads using WAN IP
msfpc msf batch wan
Display help screen with additional verbose information
msfpc help verbose
Generate Windows reverse Meterpreter payload using manual IP 192.168.1.10
msfpc windows 192.168.1.10
Updated 2026-04-16kali.org ↗