This is the AMP version of this page.
If you want to load the real page instead, click this text.

Solved Hooking functions .so

Status
Not open for further replies.

SecretMyAss

Platinian
Original poster
Skilled
Jul 16, 2018
17
56
13
23
Netherlands
Oi,

Do any one you have a working code for hooking functions?
I tried to get Substrate working, but got errors which I wasn't able to fix.

I need to hook functions in order to unlink the features, but can't seem to find any working template for it...

Any help?
 

AndnixSH

PMT Elite Modder
Staff member
Modding-Team
Jun 27, 2017
4,539
302,616
1,213
Modding World
I fixed some part of jbro project. You can get my forked project here
AndnixSH/Unity-Substrate-Hook-Android

Compile it with NDK 16b using CMD

Code:
(path to NDK)\ndk-build NDK_PROJECT_PATH=(path to project) NDK_APPLICATION_MK=(path to project\jni\Application.mk)
Code:
E:\android-ndk-r16b\ndk-build NDK_PROJECT_PATH=D:\Project\Github\Unity-Substrate-Hook-Android-master NDK_APPLICATION_MK=D:\Project\Github\Unity-Substrate-Hook-Android-master\jni\Application.mk
 
Last edited:

Del777319

Platinian
Jan 13, 2020
7
3
3
21
Moscow
After I built my lib and pointed it to smali, when I start the game, the process immediately dies and the game crashes with an error, the application is stopped, can you help me?
 

Del777319

Platinian
Jan 13, 2020
7
3
3
21
Moscow
MSHookFunction((void*)getAbsoluteAddress("libil2cpp.so", 0x00000), (void*)&_PlayerInfo, (void**)&PlayerInfo);
 
Reactions: dominca

DaRealPanDa

Co-Administrator
Staff member
Supporting-Team
Global Moderator
Social Media
Mar 12, 2018
6,771
15,652
2,120
27
Skyrim
If you are testing on Android 10, make sure libs are in arm64.
Your Android Version has nothing to do with that.
The libs are based on your CPU Arch. ARM Chips, x86 chips etc
When you have a android 10 device, which doesn't support arm64, then you will be fucked lol
the only arch which works on every device including emulators is armv7.
 
Status
Not open for further replies.