![]() |
Modifying command line of process |
Post Reply
|
| Author | ||
totti1000
Newbie
Joined: 12 September 2008 Status: Offline Points: 2 |
Post Options
Thanks(0)
Quote Reply
Topic: Modifying command line of processPosted: 12 September 2008 at 12:24pm |
|
|
Hello,
I'm trying to modify the commandline of the current process so that a call to GetCommandLine() will return a modified commandline. I tried changing the commandline information in the PEB of the process but that doesn't affect the result of GetCommandLine. Do you have any suggestions how this can best be done? Here's what I tried so far: peb.c
peb.h
Thanks, totti1000 |
||
![]() |
||
molotov
Moderator Group
Joined: 04 October 2006 Status: Offline Points: 17506 |
Post Options
Thanks(0)
Quote Reply
Posted: 12 September 2008 at 1:59pm |
|
|
Check the return value for the functions you're calling.
|
||
|
Daily affirmation:
net helpmsg 4006 |
||
![]() |
||
molotov
Moderator Group
Joined: 04 October 2006 Status: Offline Points: 17506 |
Post Options
Thanks(0)
Quote Reply
Posted: 12 September 2008 at 2:09pm |
|
|
Also, check out the implementation of GetCommandLineA/W:
It just returns a stored value. |
||
|
Daily affirmation:
net helpmsg 4006 |
||
![]() |
||
totti1000
Newbie
Joined: 12 September 2008 Status: Offline Points: 2 |
Post Options
Thanks(0)
Quote Reply
Posted: 12 September 2008 at 4:46pm |
|
|
ah okay, thank you
|
||
![]() |
||
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |