LuckyPray / DexKit

An easy-to-use, high-performance dex deobfuscation library.
https://luckypray.org/DexKit/
GNU Lesser General Public License v3.0
429 stars 53 forks source link

Can't load library dexutils #27

Open DHD2280 opened 1 month ago

DHD2280 commented 1 month ago

Hello.

I get the error: java.lang.UnsatisfiedLinkError: LspModuleClassLoader[module=/data/app/~~oJ3Sbpdmqwd7l_PYKBCkVg==/it.dhd.oxygencustomizer-ujffWgUx6hc7D0DhKmYP9Q==/base.apk, l0[DexPathList[[dex file "InMemoryDexFile[cookie=[0, -5476376665281513568, -5476376665281512672, -5476376665281512224]]"],nativeLibraryDirectories=[/data/app/~~oJ3Sbpdmqwd7l_PYKBCkVg==/it.dhd.oxygencustomizer-ujffWgUx6hc7D0DhKmYP9Q==/base.apk!/lib/arm64-v8a, /system/lib64, /system_ext/lib64]]]] couldn't find "libdexkit.so"

When trying to load dexkit library.

Class Example

DexKitUtils

This is the project

teble commented 1 month ago

Have you checked if libdexkit.so exists in the lib/arm64-v8a directory of the apk file?

DHD2280 commented 1 month ago

The lib doesn't exist in the app folder.

IMG_20240518_150923.jpg

There is only arm64 folder and it is empty.

teble commented 1 month ago

It seems that you opened the wrong directory, the apk file instead of the installation path

DHD2280 commented 1 month ago

Checked now, the libs are in: *\app\build\intermediates\merged_native_libs\release\mergeReleaseNativeLibs\out\lib & in *\app\build\intermediates\stripped_native_libs\release\stripReleaseDebugSymbols\out\lib and there are arm64-v8a, armeabi-v7a, x86 and x86_64.

But everytime I get the error when loading library.

teble commented 1 month ago

Please make sure the libdexkit.so file is packaged into the apk image

DHD2280 commented 1 month ago

After a lot of try and invalidating cache a lot of times it worked... Don't know why this strange behaivour. Anyway thanks for your support 💯

DHD2280 commented 1 month ago

Tried again, the lib is inside the apk but it fails to load library :(

teble commented 1 month ago

please provide error log

再次尝试,lib 位于 apk 内,但无法加载库:(

DHD2280 commented 1 month ago

java.lang.UnsatisfiedLinkError: LspModuleClassLoader[module=/data/app/~~VvsEdRdo9J1gJUGXer-vCw==/it.dhd.oxygencustomizer-2MA5epBfQhDC_sybq97PpQ==/base.apk, l0[DexPathList[[dex file "InMemoryDexFile[cookie=[0, -5476376665281513568, -5476376665281512672, -5476376665281512224]]"],nativeLibraryDirectories=[/data/app/~~VvsEdRdo9J1gJUGXer-vCw==/it.dhd.oxygencustomizer-2MA5epBfQhDC_sybq97PpQ==/base.apk!/lib/arm64-v8a, /system/lib64, /system_ext/lib64]]]] couldn't find "libdexkit.so" (Ask Gemini) at java.lang.Runtime.loadLibrary0(Runtime.java:1078) at java.lang.Runtime.loadLibrary0(Runtime.java:1003) at java.lang.System.loadLibrary(System.java:1661) at it.dhd.oxygencustomizer.xposed.utils.DexKitUtils.create(DexKitUtils.java:8) at it.dhd.oxygencustomizer.xposed.hooks.screenshot.ScreenshotPng.handleLoadPackage(ScreenshotPng.java:51) at it.dhd.oxygencustomizer.xposed.XPLauncher.loadModpacks(XPLauncher.java:136) at it.dhd.oxygencustomizer.xposed.XPLauncher.onXPrefsReady(XPLauncher.java:120) at it.dhd.oxygencustomizer.xposed.XPLauncher.waitForXprefsLoad(XPLauncher.java:161) at it.dhd.oxygencustomizer.xposed.XPLauncher.-$$Nest$mwaitForXprefsLoad(Unknown Source:0) at it.dhd.oxygencustomizer.xposed.XPLauncher$2.afterHookedMethod(XPLauncher.java:100) at AQ.Qx.ewrIhKd.TLZ.DOss.XposedBridge$LegacyApiSupport.handleAfter(Unknown Source:33) at J.callback(Unknown Source:292) at LSPHooker_.newApplication(Unknown Source:17) at android.app.LoadedApk.makeApplicationInner(LoadedApk.java:1545) at android.app.LoadedApk.makeApplicationInner(LoadedApk.java:1463) at android.app.ActivityThread.handleBindApplication(ActivityThread.java:7526) at android.app.ActivityThread.-$$Nest$mhandleBindApplication(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2419) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loopOnce(Looper.java:257) at android.os.Looper.loop(Looper.java:368) at android.app.ActivityThread.main(ActivityThread.java:8826) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:572) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1049)

teble commented 1 month ago

https://luckypray.org/DexKit/en/guide/quick-start.html#environment-requirements

see Notice,try to manually unzip the libdexkit.so file to load it