Print Story Creating a shim DLL on Microsoft Windows
By Rogerborg (Sat Feb 18, 2006 at 07:55:21 AM EST) 1337, virginity, nerd (all tags)
Pip pip, chums.  Ever wanted to replace some functionality in a Windows system DLL with your own, for purposes noble or nefarious?   One way to do it is with a shim DLL, that looks and acts like the real thing but which you can hook your own functionality into on a function by function basis.  Enclosed is some C++ source that will create a shim DLL for any arbitrary DLL, replicating all of its exported functions, and (by default) calling straight through to the real system DLL.

(34 comments, 997 words in story) Full Story