Re:x86 API Hooking Demystified (2012)
by userbinator on Tuesday July 09, 2019 @10:33PM
(#20398753)
On Linux (and probably other Unices), another way to hook is via the interesting default behaviour of the dynamic linker to only use symbol names instead of qualifying them with the library's filename from which they are to be imported and prefer symbols in already-loaded libraries; I suspect that more often than not, this happens by accident instead of deliberation.
[ Parent
| on HN ]
I mentioned LD_PRELOAD separately in my other comment, but I believe this same behavior is what enables LD_PRELOAD to work.
(I wonder how this interacts with glibc symbol versioning, now that I think about it.)