Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to Hide the Magisk app #8268

Open
Unknown78 opened this issue Jul 29, 2024 · 8 comments
Open

Fail to Hide the Magisk app #8268

Unknown78 opened this issue Jul 29, 2024 · 8 comments

Comments

@Unknown78
Copy link

Device: Samsung Galaxy Note 4 SM-N910H
Android version: 7.1.1 Nougat (API 25)
Magisk version name: debug
Magisk version code: 27006 (0495468d) [Download]

Device platform: armeabi-v7a

System:

Boot:


Problem

If I try to Hide the Magisk App then it will fail.

First it asks me to grant superuser access to the proxy app, so I grant it.
The proxy app opened, but a pop up appears that tells me to restore to the original APK.

Screenshot 1 (click to expand)

Screenshot_29 07 24_08 37 29

Screenshot 2 (click to expand)

Screenshot_29 07 24_08 38 09

logcat_Magisk_27006_0495468d_app-debug_2024-07-29T08.36.59.900000.txt

Highlights

07-29 08:37:11.992 29093 29093 I art     : Rejecting re-init on previously-failed class java.lang.Class<j$.nio.file.attribute.r>: java.lang.NoClassDefFoundError: Failed resolution of: Ljava/nio/file/attribute/FileAttribute;
07-29 08:37:11.992 29093 29093 I art     :   at j$.time.Instant j$.time.Instant.ofEpochSecond(long, long) (SourceFile:2)
07-29 08:37:11.992 29093 29093 I art     :   at void j$.time.Instant.<clinit>() (SourceFile:16)
07-29 08:37:11.992 29093 29093 I art     :   at java.lang.String algd.a() (PG:12)
07-29 08:37:11.992 29093 29093 I art     :   at algc algc.a() (PG:1)
07-29 08:37:11.992 29093 29093 I art     :   at void lvb.i() (PG:15)
07-29 08:37:11.992 29093 29093 I art     :   at void lvb.onCreate() (PG:23)
07-29 08:37:11.992 29093 29093 I art     :   at void android.app.Instrumentation.callApplicationOnCreate(android.app.Application) (Instrumentation.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at void android.app.ActivityThread.handleBindApplication(android.app.ActivityThread$AppBindData) (ActivityThread.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at void android.app.ActivityThread.-wrap3(android.app.ActivityThread, android.app.ActivityThread$AppBindData) (ActivityThread.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at void android.app.ActivityThread$H.handleMessage(android.os.Message) (ActivityThread.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at void android.os.Handler.dispatchMessage(android.os.Message) (Handler.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at void android.os.Looper.loop() (Looper.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at void android.app.ActivityThread.main(java.lang.String[]) (ActivityThread.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at java.lang.Object java.lang.reflect.Method.invoke!(java.lang.Object, java.lang.Object[]) (Method.java:-2)
07-29 08:37:11.992 29093 29093 I art     :   at void com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run() (ZygoteInit.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at void com.android.internal.os.ZygoteInit.main(java.lang.String[]) (ZygoteInit.java:-1)
07-29 08:37:11.992 29093 29093 I art     : Caused by: java.lang.ClassNotFoundException: Didn't find class "java.nio.file.attribute.FileAttribute" on path: DexPathList[[zip file "/data/app/com.android.vending-2/base.apk", zip file "/data/app/com.android.vending-2/split_config.armeabi_v7a.apk", zip file "/data/app/com.android.vending-2/split_config.en.apk"],nativeLibraryDirectories=[/data/app/com.android.vending-2/lib/arm, /data/app/com.android.vending-2/base.apk!/lib/armeabi-v7a, /data/app/com.android.vending-2/split_config.armeabi_v7a.apk!/lib/armeabi-v7a, /data/app/com.android.vending-2/split_config.en.apk!/lib/armeabi-v7a, /system/lib, /vendor/lib]]
07-29 08:37:11.992 29093 29093 I art     :   at java.lang.Class dalvik.system.BaseDexClassLoader.findClass(java.lang.String) (BaseDexClassLoader.java:56)
07-29 08:37:11.992 29093 29093 I art     :   at java.lang.Class java.lang.ClassLoader.loadClass(java.lang.String, boolean) (ClassLoader.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at java.lang.Class java.lang.ClassLoader.loadClass(java.lang.String) (ClassLoader.java:-1)
07-29 08:37:11.992 29093 29093 I art     :   at j$.time.Instant j$.time.Instant.ofEpochSecond(long, long) (SourceFile:2)
07-29 08:37:11.992 29093 29093 I art     :   at void j$.time.Instant.<clinit>() (SourceFile:16)
07-29 08:37:11.992 29093 29093 I art     :   at java.lang.String algd.a() (PG:12)
07-29 08:37:11.992 29093 29093 I art     :   at algc algc.a() (PG:1)
07-29 08:37:11.992 29093 29093 I art     :   at void lvb.i() (PG:15)
07-29 08:37:11.992 29093 29093 I art     :   at void lvb.onCreate() (PG:23)
07-29 08:37:11.993 29093 29093 I art     :   at void android.app.Instrumentation.callApplicationOnCreate(android.app.Application) (Instrumentation.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at void android.app.ActivityThread.handleBindApplication(android.app.ActivityThread$AppBindData) (ActivityThread.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at void android.app.ActivityThread.-wrap3(android.app.ActivityThread, android.app.ActivityThread$AppBindData) (ActivityThread.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at void android.app.ActivityThread$H.handleMessage(android.os.Message) (ActivityThread.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at void android.os.Handler.dispatchMessage(android.os.Message) (Handler.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at void android.os.Looper.loop() (Looper.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at void android.app.ActivityThread.main(java.lang.String[]) (ActivityThread.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at java.lang.Object java.lang.reflect.Method.invoke!(java.lang.Object, java.lang.Object[]) (Method.java:-2)
07-29 08:37:11.993 29093 29093 I art     :   at void com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run() (ZygoteInit.java:-1)
07-29 08:37:11.993 29093 29093 I art     :   at void com.android.internal.os.ZygoteInit.main(java.lang.String[]) (ZygoteInit.java:-1)
07-29 08:37:15.636  3446  4529 E ActivityTrigger: activityStartTrigger: not whiteListedotbrgv.n/p.BxY.a8/1
07-29 08:37:21.163 27466 27466 E WindowManager: android.view.WindowLeaked: Activity com.topjohnwu.magisk.ui.MainActivity has leaked window DecorView@625d49e[Hiding the Magisk app…] that was originally added here
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.view.ViewRootImpl.<init>(ViewRootImpl.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.view.WindowManagerGlobal.addView(WindowManagerGlobal.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.view.WindowManagerImpl.addView(WindowManagerImpl.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.app.Dialog.show(Dialog.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.core.tasks.AppMigration.hide(AppMigration.kt:216)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.ui.settings.SettingsViewModel$onItemAction$1.invokeSuspend(SettingsViewModel.kt:108)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.internal.DispatchedContinuationKt.resumeCancellableWith(DispatchedContinuation.kt:367)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.intrinsics.CancellableKt.startCoroutineCancellable(Cancellable.kt:30)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.intrinsics.CancellableKt.startCoroutineCancellable$default(Cancellable.kt:25)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.CoroutineStart.invoke(CoroutineStart.kt:110)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.AbstractCoroutine.start(AbstractCoroutine.kt:126)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.BuildersKt__Builders_commonKt.launch(Builders.common.kt:56)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.BuildersKt.launch(Unknown Source)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.BuildersKt__Builders_commonKt.launch$default(Builders.common.kt:47)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at kotlinx.coroutines.BuildersKt.launch$default(Unknown Source)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.ui.settings.SettingsViewModel.onItemAction(SettingsViewModel.kt:108)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.ui.settings.BaseSettingsItem$Input.onPressed$lambda$5$lambda$4$lambda$2$lambda$1(BaseSettingsItem.kt:89)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.ui.settings.BaseSettingsItem$Input.$r8$lambda$aI6UiGFPvOKeNlFFaYQ-NtKUy0Q(BaseSettingsItem.kt)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.ui.settings.BaseSettingsItem$Input$$ExternalSyntheticLambda3.invoke(D8$$SyntheticClass:0)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.view.MagiskDialog$ButtonViewModel.clicked(MagiskDialog.kt:122)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.databinding.DialogMagiskBaseBindingImpl._internalCallbackOnClick(DialogMagiskBaseBindingImpl.java:562)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.topjohnwu.magisk.generated.callback.OnClickListener.onClick(OnClickListener.java:11)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.view.View.performClick(View.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.widget.TextView.performClick(TextView.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.google.android.material.button.MaterialButton.performClick(MaterialButton.java:1218)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.view.View$PerformClick.run(View.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.os.Handler.handleCallback(Handler.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.os.Handler.dispatchMessage(Handler.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.os.Looper.loop(Looper.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at android.app.ActivityThread.main(ActivityThread.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at java.lang.reflect.Method.invoke(Native Method)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
07-29 08:37:21.163 27466 27466 E WindowManager: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
07-29 08:37:21.163 27466 27466 D ViewRootImpl@dbf92d9[Hiding the Magisk app…]: mHardwareRenderer.destroy()#4
07-29 08:37:21.164  3446 27215 D WindowManager: disposeInputChannel mInputChannel: d67b235 Hiding the Magisk app… (server)
07-29 08:37:21.164  2972  3023 I SurfaceFlinger: id=531 Removed Hiding the Magisk app… (3/6)
07-29 08:37:21.164  2972  8846 I SurfaceFlinger: id=531 Removed Hiding the Magisk app… (-2/6)
07-29 08:37:21.167  3446 27215 D InputTransport: Input channel destroyed: fd=366
07-29 08:37:21.174 29501 29501 I AppsEdgePanelProvider: count=0
07-29 08:37:21.176  3446  6548 D MountService: getExternalStorageMountMode : 1
07-29 08:37:21.177  3446  6548 D MountService: getExternalStorageMountMode : 3
07-29 08:37:21.179 27466 27466 D ViewRootImpl@dbf92d9[Hiding the Magisk app…]: dispatchDetachedFromWindow
07-29 08:37:21.180  3446  6548 D MountService: getExternalStorageMountMode : final mountMode=1, uid : 1000, packageName : com.samsung.android.app.assistantmenu
07-29 08:37:21.180  3446  5078 W WindowManager: Failed looking up window
07-29 08:37:21.180  3446  5078 W WindowManager: java.lang.IllegalArgumentException: Requested window android.os.BinderProxy@5449c6c does not exist
07-29 08:37:23.567 29249 29249 W System.err: android.content.pm.PackageManager$NameNotFoundException: ComponentInfo{otbrgv.n/com.topjohnwu.magisk.ui.MainActivity}
07-29 08:37:23.567 29249 29249 W System.err: 	at android.app.ApplicationPackageManager.getActivityInfoAsUser(ApplicationPackageManager.java)
07-29 08:37:23.567 29659 29659 D TaskEdgePanelProvider: onReceive android.intent.action.PACKAGE_ADDED
07-29 08:37:23.567 29249 29249 W System.err: 	at android.app.ApplicationPackageManager.getActivityInfo(ApplicationPackageManager.java)
07-29 08:37:23.567 29249 29249 W System.err: 	at com.android.internal.policy.PhoneWindow.installDecor(PhoneWindow.java)
07-29 08:37:23.568 29249 29249 W System.err: 	at com.android.internal.policy.PhoneWindow.getDecorView(PhoneWindow.java)
07-29 08:37:23.568 29249 29249 W System.err: 	at androidx.core.view.WindowCompat$Api16Impl.setDecorFitsSystemWindows(WindowCompat.java:150)
07-29 08:37:23.568 29249 29249 W System.err: 	at androidx.core.view.WindowCompat.setDecorFitsSystemWindows(WindowCompat.java:122)
07-29 08:37:23.568 29249 29249 W System.err: 	at com.topjohnwu.magisk.arch.UIActivity.onCreate(UIActivity.kt:74)
07-29 08:37:23.568 29249 29249 W System.err: 	at com.topjohnwu.magisk.ui.MainActivity.onCreate(MainActivity.kt:71)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.app.Activity.performCreate(Activity.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.app.ActivityThread.-wrap14(ActivityThread.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.os.Handler.dispatchMessage(Handler.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.os.Looper.loop(Looper.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at android.app.ActivityThread.main(ActivityThread.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at java.lang.reflect.Method.invoke(Native Method)
07-29 08:37:23.569 29249 29249 W System.err: 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
07-29 08:37:23.569 29249 29249 W System.err: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
07-29 08:37:23.572  2998  2998 W keystore: ENTER abort from uid 10016
07-29 08:37:24.506  3446  5076 E ActivityTrigger: activityStartTrigger: not whiteListedcom.topjohnwu.magisk/com.topjohnwu.magisk.ui.surequest.SuRequestActivity/27006
07-29 08:37:24.584 27466 27466 E AppContext: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.topjohnwu.magisk/com.topjohnwu.magisk.ui.surequest.SuRequestActivity}: java.lang.RuntimeException: Unable to instantiate application com.topjohnwu.magisk.core.App: java.lang.IllegalStateException: Base context already set
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.ActivityThread.-wrap14(ActivityThread.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.os.Handler.dispatchMessage(Handler.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.os.Looper.loop(Looper.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.ActivityThread.main(ActivityThread.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at java.lang.reflect.Method.invoke(Native Method)
07-29 08:37:24.584 27466 27466 E AppContext: 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
07-29 08:37:24.584 27466 27466 E AppContext: Caused by: java.lang.RuntimeException: Unable to instantiate application com.topjohnwu.magisk.core.App: java.lang.IllegalStateException: Base context already set
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.LoadedApk.makeApplication(LoadedApk.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	... 10 more
07-29 08:37:24.584 27466 27466 E AppContext: Caused by: java.lang.IllegalStateException: Base context already set
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.content.ContextWrapper.attachBaseContext(ContextWrapper.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at com.topjohnwu.magisk.core.AppContext.attachApplication(AppContext.kt:74)
07-29 08:37:24.584 27466 27466 E AppContext: 	at com.topjohnwu.magisk.core.App.attachBaseContext(App.kt:24)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.Application.attach(Application.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.Instrumentation.newApplication(Instrumentation.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	at android.app.Instrumentation.newApplication(Instrumentation.java)
07-29 08:37:24.584 27466 27466 E AppContext: 	... 11 more
07-29 08:37:24.680  3446  3468 I ActivityManager: Process com.topjohnwu.magisk (pid 27466) has died(80,1277)
07-29 08:37:40.186  2923  8682 W Magisk  : su: request rejected (10201)
07-29 08:37:40.186  2923  8682 E Magisk  : write failed with 32: Broken pipe
@madzul
Copy link

madzul commented Aug 13, 2024

Got this problem before. My workaround is: change settings for superuser request (Automatic Response) to Grant, just before hiding the magisk.

@cebtenzzre
Copy link

Got this problem before. My workaround is: change settings for superuser request (Automatic Response) to Grant, just before hiding the magisk.

This worked for me as well.

@yujincheng08
Copy link
Collaborator

Is 27003 normal?

@Unknown78
Copy link
Author

Unknown78 commented Aug 22, 2024

@yujincheng08 I couldn't test it since the busybox is segfault on arm32 with that version: #8168

Edit:
I don't remember since when this was happened, but I've just tested 27001 and it's also like this.
The latest 27007 also doesn't fix this.

@SalvatoreNoschese
Copy link

Got this problem before. My workaround is: change settings for superuser request (Automatic Response) to Grant, just before hiding the magisk.

I'm here also for this (canary and P7P). Thanks to this, I fixed 👍

@hhihhio

This comment was marked as off-topic.

@DarkanParx
Copy link

I've had the same issue, however upon restoring the original app root was somehow lost. I tried reflashing the patched .img via fastboot but although it completes successfully, upon reboot there is no root. Any ideas/suggestions? Thanks

@Umokazan
Copy link

"I've had the same issue, however upon restoring the original app root was somehow lost. I tried reflashing the patched .img via fastboot but although it completes successfully, upon reboot there is no root. Any ideas/suggestions? Thanks" stuck here too : (

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants