RemoteExecute, Function adress specify?
Posted: Tue Jul 10, 2007 12:42 am
Hi once again Madshi. As usual, your library are easy to use when you most need it. However.
I don't know if it's because im tired like crap, or if simply missunderstood the usage of RemoteExecute.
This is my Function header.
type TRemoteExecuteFunction = function DrawText(zero: dword; messagetype: dword; color: dword; textpoint:pointer) : dword; stdcall;
This is the RemoteExecute usage(Madshi, you should know it pretty well):
function RemoteExecute (processHandle : dword;
func : TRemoteExecuteFunction;
var funcResult : dword;
params : pointer = nil;
size : dword = 0 ) : bool; stdcall;
What i see here is, RemoteExecute(processHandle, @DrawText, len, @arrCh, MAX_PATH)
However, Since the functio ni want. Is not being exported. But singly exists, because i know where the function call is being made, and i know the arguments. Let's say we have a function call in asm like this:
05A7A6D7 CALL 05A6BED0(DrawText)
Where we have the asm:
0012E334 05A7A624 GameWindow.05A7A624
0012E338 0012E394 |Arg1 = 0012E394
0012E33C FF408CFF |Arg2 = FF408CFF
0012E340 00000011 |Arg3 = 00000011
0012E344 00000000 \Arg4 = 00000000
I want to be able to use that call. And With RemoteExecute i can't specify which adress i want to place the RemoteExecute on.
With CreateRemoteThreadEx(); Its the same thing. I can specify i function i want to place into the specified process.
What i want todo is something like:
RemoteExecute(processHandle, $05A7A6D7 , @DrawText)
Where then $05A7A6D7 is the adress, where the function call is being made. Then I want the arguments from DrawText being sent.
The function which i want to use, Will Draw Text onto the screen in a game. What i want to be able todo is, Calling that function, adding the arguments. So, Sort of a function hook, but i just want to use the function.
Could you please guide me on this matter?
Keep rocking
Cal
I don't know if it's because im tired like crap, or if simply missunderstood the usage of RemoteExecute.
This is my Function header.
type TRemoteExecuteFunction = function DrawText(zero: dword; messagetype: dword; color: dword; textpoint:pointer) : dword; stdcall;
This is the RemoteExecute usage(Madshi, you should know it pretty well):
function RemoteExecute (processHandle : dword;
func : TRemoteExecuteFunction;
var funcResult : dword;
params : pointer = nil;
size : dword = 0 ) : bool; stdcall;
What i see here is, RemoteExecute(processHandle, @DrawText, len, @arrCh, MAX_PATH)
However, Since the functio ni want. Is not being exported. But singly exists, because i know where the function call is being made, and i know the arguments. Let's say we have a function call in asm like this:
05A7A6D7 CALL 05A6BED0(DrawText)
Where we have the asm:
0012E334 05A7A624 GameWindow.05A7A624
0012E338 0012E394 |Arg1 = 0012E394
0012E33C FF408CFF |Arg2 = FF408CFF
0012E340 00000011 |Arg3 = 00000011
0012E344 00000000 \Arg4 = 00000000
I want to be able to use that call. And With RemoteExecute i can't specify which adress i want to place the RemoteExecute on.
With CreateRemoteThreadEx(); Its the same thing. I can specify i function i want to place into the specified process.
What i want todo is something like:
RemoteExecute(processHandle, $05A7A6D7 , @DrawText)
Where then $05A7A6D7 is the adress, where the function call is being made. Then I want the arguments from DrawText being sent.
The function which i want to use, Will Draw Text onto the screen in a game. What i want to be able todo is, Calling that function, adding the arguments. So, Sort of a function hook, but i just want to use the function.
Could you please guide me on this matter?
Keep rocking
Cal