|
Listing 1. Pseudocode for executing the decoded shellcode using FountainDecoder. |
Function ExecuteShellcode()
// Initialize FountainDecoder
Set decoder = Initialize FountainDecoder WITH:
- shellcodeSize
- sliceSize
-~seed
// Receive encoded packets
FOR EACH packet IN encodedPackets
Call ReceivePacket(packet)
END~FOR
// Allocate memory for shellcode
Set funcAddr = Call VirtualAlloc WITH:
- BaseAddress: NULL
- Size: LENGTH(shellcode)
- State: MEM_COMMIT
- Protection: PAGE_EXECUTE_READWRITE
|