tiann / FreeReflection

A library that lets you use reflection without any restriction above Android P

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NoSuchMethodException: dalvik.system.VMRuntime.setHiddenApiExemptions

eleven-di opened this issue · comments

reflect bootstrap failed:
java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invoke(Native Method)
at me.weishu.reflection.BootstrapClass.(BootstrapClass.java:29)
at me.weishu.reflection.BootstrapClass.exemptAll(BootstrapClass.java:72)
at me.weishu.reflection.Reflection.unseal(Reflection.java:35)
at com.example.hide.Main.onCreate(Main.java:13)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1226)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:7036)
at android.app.ActivityThread.access$1800(ActivityThread.java:253)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2183)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:233)
at android.os.Looper.loop(Looper.java:344)
at android.app.ActivityThread.main(ActivityThread.java:8191)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:584)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1034)
Caused by: java.lang.NoSuchMethodException: dalvik.system.VMRuntime.setHiddenApiExemptions [class [Ljava.lang.String;]
at java.lang.Class.getMethod(Class.java:2103)
at java.lang.Class.getDeclaredMethod(Class.java:2081)
at java.lang.reflect.Method.invoke(Native Method) 
at me.weishu.reflection.BootstrapClass.(BootstrapClass.java:29) 
at me.weishu.reflection.BootstrapClass.exemptAll(BootstrapClass.java:72) 
at me.weishu.reflection.Reflection.unseal(Reflection.java:35) 
at com.example.hide.Main.onCreate(Main.java:13) 
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1226) 
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:7036) 
at android.app.ActivityThread.access$1800(ActivityThread.java:253) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2183) 
at android.os.Handler.dispatchMessage(Handler.java:106) 
at android.os.Looper.loopOnce(Looper.java:233) 
at android.os.Looper.loop(Looper.java:344) 
at android.app.ActivityThread.main(ActivityThread.java:8191) 
at java.lang.reflect.Method.invoke(Native Method) 
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:584) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1034) 
om.example.hid com.example.hide W Opening an oat file without a class loader. Are you using the deprecated DexFile APIs?
om.example.hid com.example.hide W DexFile /data/user/0/com.example.hide/code_cache/1695870531295.dex is in boot class path but is not in a known location

@eleven-di this does not affect result, hideen api restriction have been cracked.

@eleven-di this does not affect result, hideen api restriction have been cracked.

Really? Why does my program flash back and call the third-party jar after I use it will not throw this error? How should I verify it.

@eleven-di You can verify by using the hidden API, and you will find that even with this error, the hidden API can still be called normally

企业微信截图_17054825268424
能否解释下,为什么即使出现异常,也不影响使用?
Can you explain why even if there is an exception, it does not affect the use?