admin管理员组文章数量:1609965
EHook
A hooking framework for commercial Android emulators (雷电模拟器, NOX, BlueStacks).
As you may know, these commercail emulators use x86 (kernel) and arm (user land) mixed-mode method to accelerate the emulation and this makes it difficult to hook the native arm libraries. This emulator hooking framework is intented to solve this problem.
Usage
Modify the jni/realinject.c file. You can hook functions both by address or by the function's symbol name:
static struct hook_t eph1;
static struct hook_t eph_sendto;
...
...
/*On BlueStacks*/
//hook_by_addr(&eph1, "arm/libc.so", target_addr, hook_func1);
/*Other emulators*/
hook_by_name(&eph_sendto, "nb/libc.so", "sendto", hook_sendto);
Notice: If you are hooking system libraries like "libc.so", please make sure you are giving the right path of the arm version binary.
Run ndk-build
Push the following 3 binary to android /data/local/tmp directory:
libs/x86/stalker
libs/x86/libinject.so
libs/armeabi/librealinject.so
Or just run push.cmd.
On android, type ./stalker [pid].
Notice
For NOX emulator, you should use the Android 5.1.1 instead of the default 4.4.2.
Also see this repo: XEHook.
acknowledgement
版权声明:本文标题:android 雷电模拟器 hook,GitHub - chagoEHook: A hooking framework for commercial Android emulators (雷电模拟器... 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:https://www.elefans.com/xitong/1728587197a1165030.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论