I'm not too sure what i'm doing wrong or how i fix this but whenever i generate a LARGE payload (only large ones do this for me) using the following commands BELOW it gives me an exception "0xc0000409", i do decrypt a encrypted payload at runtime but this shouldn't stop it from executing if i do it correctly, i checked the allocated memory using debugger and start and end bytes match the original, yes my program matches subsystem and arch for the shellcode, im a bit tired as of making this post so i might not have put as much info as i should, anyways i would much appreciate any further questions or information.
COMMANDS I USED:
"cl main.cpp /EHsc"
"donut -a 3 -f 1 -e 1 -i main.exe -o main.bin"
EXECUTION FLOW:
void* Address = VirtualAlloc(NULL, Decoded.size(), MEM_COMMIT | MEM_RESERVE, PAGE_EXECUTE_READWRITE);
SIZE_T Written;
WriteProcessMemory(GetCurrentProcess(), Address, Decoded.data(), Decoded.size(), &Written);
std::cout << "WRITTEN : " << Written << "\n";
^^ RESPONDS WITH CORRECT LENGTH
MY OPERATING SYSTEM:
Windows 11 Home
Intel I5-10400F
x64 based
ASUS motherboard
I'm not too sure what i'm doing wrong or how i fix this but whenever i generate a LARGE payload (only large ones do this for me) using the following commands BELOW it gives me an exception "0xc0000409", i do decrypt a encrypted payload at runtime but this shouldn't stop it from executing if i do it correctly, i checked the allocated memory using debugger and start and end bytes match the original, yes my program matches subsystem and arch for the shellcode, im a bit tired as of making this post so i might not have put as much info as i should, anyways i would much appreciate any further questions or information.
COMMANDS I USED:
"cl main.cpp /EHsc"
"donut -a 3 -f 1 -e 1 -i main.exe -o main.bin"
EXECUTION FLOW:
^^ RESPONDS WITH CORRECT LENGTH
MY OPERATING SYSTEM:
Windows 11 Home
Intel I5-10400F
x64 based
ASUS motherboard