i run frida with genymotion and installed free fire game x86 version and i was able to get base address of libil2cpp.so but when i use the offset to hook the functions i get nothing from frida i tryed with multiple functions and the result is the same this is the code i use :
JavaScript:
console.log("Script loaded successfully ..... ");
function awaitForCondition(callback) {
var i = setInterval(function () {
var addr = Module.findBaseAddress('libil2cpp.so');
console.log("Address found:", addr);
if (addr) {
clearInterval(i);
callback(+addr);
}
}, 2);
}
var il2cpp = null;
Java.perform(function () {
awaitForCondition(function (base) {
il2cpp = ptr(base);
var offset= il2cpp.add(0x8B1824);
Interceptor.attach(offset, {
onEnter: function(args) {
console.log('func called!');
this.instance = args[0];
},
onLeave: function(ret_val) {
console.log('func leave!');
}
})
})
});