jmpews / Dobby

a lightweight, multi-platform, multi-architecture hook framework.
Apache License 2.0
3.89k stars 796 forks source link

Crash with few functions while hooking them twice or more? #208

Open RusJJ opened 1 year ago

RusJJ commented 1 year ago

So, in a GTA:SA for Android we have a function for handling screen touching. It's name is AND_TouchEvent. If you hook it twice, it will crash the whole game with SIGBUS. The function starts with: HEX:

F0 B5 03 AF 2D E9 00 0F 8D B0 44 F2 40 26 01 28 99 46 93 46 8A 46 4F F0 00 05

Disasm (IDA):

.text:002697C0 PUSH {R4-R7,LR} .text:002697C2 ADD R7, SP, #0xC .text:002697C4 PUSH.W {R8-R11} .text:002697C8 SUB SP, SP, #0x34 .text:002697CA MOVW R6, #IDA Failed Here .text:002697CE CMP R0, #1

Cydia Substrate and Inline hook is failed on it too. What may be wrong with that?

jmpews commented 1 year ago

only crash with hooked twice ?

RusJJ commented 1 year ago

Sure. That happens using Cydia tho

RusJJ commented 1 year ago

Have you tried anything?

RusJJ commented 1 year ago

So it's abandoned? Damn man