I used objection to inject frida gadget to a game apk.
i could connect to it and execute some javascript scripts.
however when i try to use the javascript api i get the error that it is not available
I did enumerate the loaded modules and at first they were very little so i edited the smali to load the gadget around the end of the oncreate function of the main unity activity.
this did cause some more modules to appear like libunity and libmain (no il2cpp for some reason)
and still the java api is no where to be found
loaded modules: libdl.so ld-android.so libsigchain.so libunwindstack.so libc++.so libc.so libm.so libbase.so liblog.so liblzma.so libmain.so libunity.so libandroid.so libz.so libEGL.so libcutils.so libgraphicsenv.so libnativewindow.so libvndksupport.so android.hardware.configstore@1.0.so android.hardware.configstore-utils.so libhidlbase.so libnativebridge_lazy.so libnativeloader_lazy.so libutils.so libSurfaceFlingerProp.so libbinder.so libdl_android.so libui.so libbinder_ndk.so android.hardware.graphics.common@1.1.so android.hardware.configstore@1.1.so android.hardware.graphics.common@1.2.so libapexsupport.so android.hardware.graphics.common-V5-ndk.so android.hardware.graphics.allocator-V2-ndk.so android.hardware.graphics.allocator@2.0.so android.hardware.graphics.allocator@3.0.so android.hardware.graphics.allocator@4.0.so android.hardware.graphics.mapper@2.0.so android.hardware.graphics.mapper@2.1.so android.hardware.graphics.mapper@3.0.so android.hardware.graphics.mapper@4.0.so libgralloctypes.so libsync.so android.hardware.graphics.common@1.0.so android.hardware.common-V2-ndk.so
the error
[Remote::Gadget ]-> Java.performNow(); Error: Java API not available at _checkAvailable (/frida/bridges/java.js:8) at performNow (/frida/bridges/java.js:8) at <eval> (<input>:1) [Remote::Gadget ]-> Java.perform(); Error: Java API not available at _checkAvailable (/frida/bridges/java.js:8) at perform (/frida/bridges/java.js:8) at <eval> (<input>:1) [Remote::Gadget ]->
I used objection to inject frida gadget to a game apk.
i could connect to it and execute some javascript scripts.
however when i try to use the javascript api i get the error that it is not available
I did enumerate the loaded modules and at first they were very little so i edited the smali to load the gadget around the end of the oncreate function of the main unity activity.
this did cause some more modules to appear like libunity and libmain (no il2cpp for some reason)
and still the java api is no where to be found
loaded modules: libdl.so ld-android.so libsigchain.so libunwindstack.so libc++.so libc.so libm.so libbase.so liblog.so liblzma.so libmain.so libunity.so libandroid.so libz.so libEGL.so libcutils.so libgraphicsenv.so libnativewindow.so libvndksupport.so android.hardware.configstore@1.0.so android.hardware.configstore-utils.so libhidlbase.so libnativebridge_lazy.so libnativeloader_lazy.so libutils.so libSurfaceFlingerProp.so libbinder.so libdl_android.so libui.so libbinder_ndk.so android.hardware.graphics.common@1.1.so android.hardware.configstore@1.1.so android.hardware.graphics.common@1.2.so libapexsupport.so android.hardware.graphics.common-V5-ndk.so android.hardware.graphics.allocator-V2-ndk.so android.hardware.graphics.allocator@2.0.so android.hardware.graphics.allocator@3.0.so android.hardware.graphics.allocator@4.0.so android.hardware.graphics.mapper@2.0.so android.hardware.graphics.mapper@2.1.so android.hardware.graphics.mapper@3.0.so android.hardware.graphics.mapper@4.0.so libgralloctypes.so libsync.so android.hardware.graphics.common@1.0.so android.hardware.common-V2-ndk.sothe error
[Remote::Gadget ]-> Java.performNow(); Error: Java API not available at _checkAvailable (/frida/bridges/java.js:8) at performNow (/frida/bridges/java.js:8) at <eval> (<input>:1) [Remote::Gadget ]-> Java.perform(); Error: Java API not available at _checkAvailable (/frida/bridges/java.js:8) at perform (/frida/bridges/java.js:8) at <eval> (<input>:1) [Remote::Gadget ]->