What bug was encountered when using the automatically generated ROP chain from mona, and why did it cause VirtualProtect to fail?
The automatically generated ROP chain unintentionally overwrote the SEH chain (Structured Exception Handler), corrupting the parameters passed to the VirtualProtectEx function. As a result, the function call returned 0, indicating failure. This bug forces the exploit developer to manually verify and fix the ROP chain based on the specific execution environment, as described in the debugging section of Windows Shellcode Study Notes - Bypassing DEP via VirtualProtect.
SEH chainVirtualProtectExROP chain bugfunction call failuredebugging