Raised This Month: $51 Target: $400
 12% 

Detect function call?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Spirit_12
Veteran Member
Join Date: Dec 2012
Location: Toronto, CA
Old 08-15-2018 , 00:31   Detect function call?
Reply With Quote #1

I know this might be asking too much, but is there a way to detect what function is being called in the library? I'm talking about SDK functions here to be specific.

What would be the best way to detect what function is being called? Would it be possible to create some sort of listener which can detect when a function is being called?
__________________
Spirit_12 is offline
nosoop
Veteran Member
Join Date: Aug 2014
Old 08-15-2018 , 03:48   Re: Detect function call?
Reply With Quote #2

With known arbitrary function(s)? You'll most likely have to detour them with detour-supported DHooks or an extension.

If you're not at the point where you know what function to hook, load up the binary in IDA and look at some likely candidates (if your desired function fires any events or usermessages, you can cross-reference any used strings with the string view; otherwise hopefully your game has debugging symbols present and you can find some named functions that sound like something you're looking for).
__________________
I do TF2, TF2 servers, and TF2 plugins.
I don't do DMs over Discord -- PM me on the forums regarding inquiries.
AlliedModders Releases / Github / TF2 Server / Donate (BTC / BCH / coffee)
nosoop is offline
Spirit_12
Veteran Member
Join Date: Dec 2012
Location: Toronto, CA
Old 08-15-2018 , 14:06   Re: Detect function call?
Reply With Quote #3

I do have the IDA disassembly with symbols. Just hard to predict the chain of events.
__________________
Spirit_12 is offline
psychonic

BAFFLED
Join Date: May 2008
Old 08-15-2018 , 14:26   Re: Detect function call?
Reply With Quote #4

If you're on Linux and if on a game where the current binary has symbols, you can run under GDB and set breakpoints. Then, you can do a backtrace when the breakpoint gets hit to get the function call hierarchy.
psychonic is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 16:37.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode