在Windows内插器 [英] interposers on Windows
问题描述
是否有可能替换系统功能,有可能在Linux和Solaris使用LD_ preLOAD
Is it possible to substitute system functions, as is possible on Linux and Solaris using the LD_PRELOAD
例如通过设置环境变量:
LD_ preLOAD = /路径/要/ mymalloc.so
For example by setting the environment variable: LD_PRELOAD=/path/to/mymalloc.so
我有我的更换的malloc函数,而不是在已经安装在系统库的C运行时。在系统dll的所有其他功能将运行正常。
I would have my replacement malloc functions instead of in the C runtime already installed in the system libraries. All other functions in the system dll's would run as normal.
推荐答案
微软研究院有一个名为库的弯路它允许你截获Win32 API调用。
Microsoft Research has a library called Detours which allows you to intercept Win32 API calls.
走弯路是在x86,x64和IA64机插装任意的Win32函数库。弯路通过重新编写内存code为目标函数截取Win32函数。少走弯路软件包还包含水电费任意的DLL和数据段(称为有效载荷)附加到任何Win32的二进制代码。
Detours is a library for instrumenting arbitrary Win32 functions on x86, x64, and IA64 machines. Detours intercepts Win32 functions by re-writing the in-memory code for target functions. The Detours package also contains utilities to attach arbitrary DLLs and data segments (called payloads) to any Win32 binary.
这篇关于在Windows内插器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!