-
May 16th, 2005, 08:47 AM
#1
How to determine a DLL function's prototype
I have a third party DLL which has some functions exported. Now I wish to call one of the functions of the DLL but I do not know the prototype of the same. How can I call it? In other words how can I know the prototype?
I only have the DLL i.e. no lib nothing.
-
May 16th, 2005, 09:06 AM
#2
Re: How to determine a DLL function's prototype
This is not easy.
It's easy to find which functions exist. But to find the parameters a bit more tricky. I used OllyDebug to do the same. OllyDebug is a Disassembler/Debugger.
I launched OllyDebug with the other software that used the DLL and added breakpoints where the DLL was called. There you can see how many parameters is pushed. Then you have to backtrack a bit to check where the parameters is loaded to be able to figure out what they contain.
But dont do any of this if you don't have good knowlegde about how the internals of software works. Some Assembly knowlegde is also neccasary.
OllyDebug can be found at: http://home.t-online.de/home/Ollydbg/
"The making of software, like the making of sausages, should never be watched."
http://blog.gauffin.org - .NET Coding/Architecture
-
May 17th, 2005, 12:36 AM
#3
Re: How to determine a DLL function's prototype
Thanks for your reply.
Though I am not very comfortable with assembly still I need to do this very urgently so could you please guide me as to how can I accomplish this using OllyDbg?
-
May 17th, 2005, 02:13 AM
#4
Re: How to determine a DLL function's prototype
Sorry no. It's not easy at all and very time consuming. I spent about a month to find to idenitfy 20 functions in a DLL since it used various structs as parameters.
"The making of software, like the making of sausages, should never be watched."
http://blog.gauffin.org - .NET Coding/Architecture
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|