Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > C/C++
You last visited: Today at 14:07

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Calling Internal functions from a second program question.

Discussion on Calling Internal functions from a second program question. within the C/C++ forum part of the Coders Den category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Mar 2012
Posts: 1
Received Thanks: 0
Calling Internal functions from a second program question.

I wanted to question how to call a function of a program with a second independent program.

First is a program that prints a int variable once every 5 seconds. It contains an uncalled function that turns the int into int++. However this function isn't called by said program.

The second program would be able call the programs uncalled function. Just wanting to know a point in the right detection.
Algaru is offline  
Old 03/08/2012, 09:16   #2
 
elite*gold: 0
Join Date: Jul 2010
Posts: 388
Received Thanks: 196
Easiest way would be to inject a .dll that calls the function from within the process. You could also pick a function that gets called very often, many Windows functions get called several times per second, write a jump to a codecave into it, call your function in the codecave, execute the overwritten Opcodes and then return to the hooked function. This can be done without injecting a .dll.
SmackJew is offline  
Old 03/08/2012, 21:54   #3
 
Threk's Avatar
 
elite*gold: 0
Join Date: Oct 2010
Posts: 309
Received Thanks: 272
Quote:
Originally Posted by Algaru View Post
I wanted to question how to call a function of a program with a second independent program.

First is a program that prints a int variable once every 5 seconds. It contains an uncalled function that turns the int into int++. However this function isn't called by said program.

The second program would be able call the programs uncalled function. Just wanting to know a point in the right detection.
You could use code injection.
Assemble your asm code to opcodes ( for example with fasm) and then inject it via CreateRemoteThread.

Or use Dll Injection.

If you have the source code for both programs you could also use IPC (for example a named pipe).
Threk is offline  
Old 04/04/2012, 23:07   #4
 
elite*gold: 0
Join Date: Dec 2009
Posts: 27
Received Thanks: 3
If the target routine has only one argument it would be possible to call the function directly with CreateRemoteThread.
If thats not the case you will have to inject a dll/asm-code because CreateRemoteThread is not able to deliver more than one argument.
mfg @night@
@night@ is offline  
Reply


Similar Threads Similar Threads
[Tutorial] Modifying/Using client-internal Functions
12/14/2011 - 4Story Hacks, Bots, Cheats & Exploits - 5 Replies
while analyzing the client with your favorite debugger, you might run into some client functions... especially if you're trying to break/bypass some special stuff, you'll allways have to find the client function, which handles it. if you wanna break the swearfilter (badword-filter) in the client, you'll allways start with searching for the ChatInputHandler function =) in this tutorial, i'm not going to explain, how to trace through the client, to find such things. if you're intrested...
C# client internal functions, problem
08/24/2011 - SRO Coding Corner - 10 Replies
I have a problem to use Client internal function in C# for SRO, my source doesnt work at the moment and i dont know why. Here is my source: #region WriteChatText uint chatFunc = VirtualAllocEx(SroProcessHandle, IntPtr.Zero, 26, 0x1000, 0x4); //uint message = VirtualAllocEx(SroProcessHandle, IntPtr.Zero, 47, 0x1000, 0x4); byte Text = { 0x60, //Pushad 0x8B, 0x0D, //mov ecx, dword ptr ds: ...
[Guide] Using Client (internal) Functions
02/21/2011 - SRO PServer Guides & Releases - 0 Replies
since many people are asking for sources of my Loaders, here are some asm code pieces directly out of the zszc client. you should be able to use them in almost all coding languages... hope this will be useful for coders in the pserv sections. its also possible to send/recyve packets directly through the client, but that would require some hooks in the client, so i won't really explain how to do that in this post (since its not/hardly realizable in scripting languages)... if u're interested...
Scan image program. I'm calling some experts!
05/20/2009 - Cabal Online - 0 Replies
Nevermind close please
"need help" on debugger and calling functions
08/25/2008 - General Coding - 2 Replies
ok..what programs do i need to do this? do you have any guides? thx..any help would be much appreciated.. i want to learn on how to do this things



All times are GMT +2. The time now is 14:07.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.