Kong - hooking package.

Neal Alexander wqeqweuqy at hotmail.com
Thu Dec 27 15:48:33 PST 2007


Bill Baxter wrote:
> Vladimir Panteleev wrote:
>> On Wed, 26 Dec 2007 23:15:23 +0200, Walter Bright 
>> <newshound1 at digitalmars.com> wrote:
>>
>>> 2) It needs more explanation of what code hooking is and what you can do
>>> with it.
>>
>> IMO if you don't know what it is, you probably don't need it ;) it's 
>> like having to explain what programming or a compiler is on the DMD 
>> homepage.
>>
>> There's a bit of info on Wikipedia: http://en.wikipedia.org/wiki/Hooking
> 
> I disagree.  I didn't know what the announcement was talking about from 
> the original announcement, but after reading more, I think it sounds 
> like something that could be useful to me.  It sounds like it could be 
> used to do what I've heard called "interception" or "wrapping" of dlls. 
>  Like here: http://glintercept.nutty.org/index.html
> 
> --bb
Yea you just hook the allocator for an interface and have it return a 
proxy object. I have some old directx8 wrapping code that i can strip 
and turn into a demo of this.


Anyway, i added an intro to the site:

"""Hooking represents a useful method of modifying the runtime behavior 
of an application. This is achieved through rerouting API/function calls 
to alternate code locations while still allowing the original code to be 
called from other contexts (ie. from the replacement function). Hooking, 
combined with class wrapping, such as the case with COM objects, can 
completely alter the behavior of the target application without having 
access to its source code.

Executable image parsing allows this to be extended further. Instead of 
globally hooking a procedure we can now modify behavior privately, 
within the context of each DLL or shared object (IAT/PLT:GOT hooking 
method). """


I'm gonna try to get the project setup on dsource.org for SVN / forums. 
  The code and documentation need polishing and whatever feedback is 
appreciated.



More information about the Digitalmars-d-announce mailing list