facebook / fishhook

A library that enables dynamically rebinding symbols in Mach-O binaries running on iOS.
BSD 3-Clause "New" or "Revised" License
5.2k stars 966 forks source link

hook not successfully when symbols is lazy bindings #10

Open ritchiejin opened 9 years ago

ritchiejin commented 9 years ago

I use it in mac os x, as dyld_interposing does not works sometimes. I used it the hook a system api(LSOpenCFURLRef), but this symbol is lazy binding. And I cannot hook it successfully. Any idea? Thanks!

grp commented 9 years ago

Yeah, this is an issue with fishhook. For that, I'd suggest checking out @landonf's PLPatchMaster — it does a lot more, but it includes hooking lazy/indirect symbols.