ByteHook v1.0.3
Bugs fixed
Fix an occasional carsh bug
Fix an occasional crash bug caused by GOT table data reading.
Improve
Enhanced hook capability
In some special cases, the dynamic library will call its own function through PLT, but the called function is not an exported function, so it is not in .hash and .gnu.hash. In the previous implementation, this kind of PLT call could not be hooked.
Improve the performance of the proxy function
In the previous implementation, when a thread executes a proxy function for the first time, it will call mmap
and prctl
once.
Added hook / unhook operation recording module
We have added a module for recording hook / unhook operation records and the corresponding data export interface. You can use these data to count the success rate of hook / unhook, the reason for operation failure, etc. You can also make a comprehensive analysis of these data and app crash information.
Bugs 修复
修复了一个偶现的崩溃 bug
修复了一个偶现的读取 GOT 表数据引起崩溃的 bug。
改进
增强 hook 能力
某些特殊情况下,动态库会通过 PLT 调用自身的函数,但是被调用函数不是导出函数,因此不在 .hash 和 .gnu.hash 中。在之前的实现中,这种 PLT 调用是 hook 不到的。
改进 proxy 函数的性能
在之前的实现中,线程第一次执行到一个 proxy 函数时,会调用一次 mmap
和一次 prctl
。
增加 hook / unhook 操作记录模块
我们增加了一个用于记录 hook / unhook 操作记录的模块,以及对应的数据导出接口。你可以用这些数据统计 hook / unhook 的成功率,操作失败的原因等,也可以把这些数据和 app 的崩溃信息一起做综合分析。