library interposition with dlsym

Posted by ZeeGeek on Stack Overflow See other posts from Stack Overflow or by ZeeGeek
Published on 2009-10-25T18:33:18Z Indexed on 2010/05/17 20:30 UTC
Read the original article Hit count: 215

Filed under:
|
|
|
|

I'm writing an interposition library to track the usage of some library functions in libc, such as open(), close(), connect(), etc. It works generally well on most of the applications. However, when I try it with PHP, using PHP's MySQL module in particular, none of the function calls to libc inside this module is been tracked (so no connect(), no socket(), etc.). 'strace' told me that the system calls socket(), connect(), etc., took place. Running 'file' on the module and libmysqlclient.so.16.0.0 said that they are all dynamically linked. So it shouldn't be a problem caused by static linkage. What might be the problem?

I'm using Fedora 11 64-bit version.

Thank you.

© Stack Overflow or respective owner

Related posts about library

Related posts about dlsym