How it works...

msfvenom helps us create payloads from the extensive list of Metasploit's payloads, and incorporates them into source code in many languages, or creates scripts and executable files, as we did in this recipe. The parameters we used here were the payload to use (linux/x86/meterpreter/reverse_tcp), the host and port to connect back (lhost and lport), and the output format (-f elf), redirecting the standard output to a file to have it saved as cute_dolphin.bin.

The exploit/multi/handler module of Metasploit is a payload handler. This means it doesn't actually perform any exploitation; instead it only processes connections with payloads executed in compromised hosts. In this case, we used it to listen for the connection and after the connection was established, it ran the meterpreter payload.

Meterpreter is Metasploit's version of a shell on steroids. Although meterpreter for Linux is more limited than its Windows counterpart, which contains modules to sniff on a victim's network and to perform privilege escalation and password extraction, we can still use it as a pivot point to access the victim's local network, or to exploit the host further by using the local and post-exploitation Metasploit modules.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.133.12.172