WriteProcessMemory() doesnt work for me as I get an access denied error.
I am currently launching the process using
CreateProcess(wcImageName, wcCommandLine, NULL, NULL, false, DEBUG_PROCESS, NULL, NULL, &stStartupInfo, &stProcessInfo);
How do I modify this to gain write access?
I am launching this process on the same machine. How can I get write access without providing username and password?
Make sure you are calling
WriteProcessMemorywith correct handle, and in the debugger loop. You may read this article.When you create process, you do have full rights – and when you launch with DEBUG_PROCESS or
DEBUG_ONLY_THIS_PROCESSyou have more rights!