yashsingh1/xdaforums huggingface dataset:
[Magisk] pndwal:
First, why have you changed my first sentence?... I didn't say "Strong personal view is that it's the other way around..." 🤔

And banks may be able to require strongIntegrity selectively, but without proper hardware backed attestation to device/model they can only (and do) enforce HKA using props afaik... These can easily be spoofed (as USNF is doing for deviceIntegrity), and if strongIntegrity was to be 'enforced' that way it really wouldn't be proper (strong) enforcement since it's easy to spoof another device...

Point is proper strongIntegrity as it exists currently must be applied to all devices or none ATM, and this is why we still enjoy using our bank apps w/ root / custom ROMs... PW
[Magisk] FreSchDude:
Magisk app works fine and my banking apps claim the phone is rooted. Magisk is in hide mode so normal mode I get the prompt to install magisk due to root being lost.
[Magisk] zgfg:
I started to type but phone slipped in my hands and "Strong Integrity" was 'lost' (typed in the quoted post instead of below)

Instead of searching for (in your long quoted text as usual) to fix (or to cancel and start replying again) I continued - usually when reading posts it is not needed to re-read quoted post, or it can be clicked to go to the original (although original post can be edited in the meantime), hence I sometimes ignore that kind of typing mistake and continue to answer
[Magisk] J.Michael:
Are we struggling to find a way for you to boot without Magisk? Or are we struggling to find a more convenient way for you to boot without Magisk?

What do you mean "Magisk is in hide mode so normal mode I get the prompt to install magisk due to root being lost"?

What is "normal mode"?

How did you boot in "normal mode"?

How are you deciding that "root" has been "lost"?

Which "hide mode" are you talking about?

If you still have the patched AP.tar you used the last time you used Odin, and you still have the unpatched AP.tar, then you can compare the two to figure out whether Magisk is installed in boot or recovery. (My suspicion is that when presented with an AP.tar, Magisk manager app always installs Magisk in recovery, and just makes some minor changes to boot and vbmeta images.)

I have a hard time believing that it is hard for you to get to recovery. I have read about people needing a USB cable plugged in to get to download mode. I think I have read of people needing a USB cable plugged in to trigger Magisk in recovery. I do not believe I have ever heard of anyone having trouble getting to Recovery Mode.

Do you have a case on your tablet? Could it be interfering with your ability to hold the Power and Volume-Up keys for 40 seconds? Do you release the buttons every time the "bootloader is unlocked" nag screen comes up? Do you respond to their exhortation to "Press Power to get past this nag screen"?

When Android is booted, and you hold the Power button, do you get a menu? Have you ever tried the "Reboot" option on that menu? Is Magisk active when it finishes rebooting?

Have you visited a Note thread to see if anyone talks about installing Magisk, or booting to recovery?
[Magisk] FreSchDude:
Unrooted boot. The kind where magisk says you just boot your phone normally, since magisk is in recovery partition.

Magisk claims I just boot normally, but for my phone, for some reason, I have to put my phone into download mode, then cancel out of it to boot into unrooted mode. If I just boot my phone normally (no key combination) it somehow ends up in recovery mode, rooted.

I determine the difference between root and unrooted modes by 2 ways:

1. Magisk (which is in hidden mode) gives me an error that root has been lost, and I must restore the original application to do anything.

2. Banking apps and government apps don't block me and say my phone is rooted.

If I boot into recovery, magisk works fine and the previously mentioned apps block me from using them.

When you open the magisk app, there is an option in the settings to hide the app. I'm using that functionality. It's the one where the original application is hidden from the app drawer, and you must use a shortcut to open magisk.

A quick rundown off the situation as this seems to be a bit complicated. Originally I posted a thread asking what is wrong with magisk. I tried booting from power off, but it kept going into recovery mode. ADB reboot commands and the reboot button (not reboot recovery) inside magisk all reboot to recovery, where some apps are blocked due to detecting root. The guy helping me try to walk me through installing shamiko and other modules to try and hide my root, so I could use the applications that were blocked. (They claim that there is no point switching between root and normal mode) and eventually, we found out that some apps are still blocked. They then recommended I come to this thread and ask for help. So my original intention is to find out why every boot goes into recovery mode, and the only way for me to boot normally (without root access) is to go into download mode and cancel out.
[Magisk] gsmdb:
Rename the apk to zip then you get a list of files. Under assets folder you can see the magisk placeholder so called stub.apk in build 26.1 where in build 25.2 is not existed.

If you delete the magisk from Sytems > Apps then under any circumstance when the root is needed there will automatically install a magisk placeholder app (w/o the reel magisk icon) in both builds.

So I don't really understand what the stub.apk is good for? According the boot_patch.sh the stub.apk will be patched to the ramdisk.

Annoying with build 26.1 is when you delete the magisk app then you miss the root and the stub.apk is automatically installed and then can not bypass Applist Dectector for rooting. In build 25.2 all good regardless deleting of the magisk app.

Can anyone shed a light on this issue? Thanks for help.
[Magisk] knojap:
after I wanted to hide magisk 26.1, the G9700 performed a soft reboot. Since then, the Magisk app tells me that magisk is not installed. but root and lsposed still work. But I can no longer set anything in Magisk. Does anybody have a solution. Here is my Magisk log. I reinstalled Magisk and the firmware. Without success
[Magisk] badabing2003:
It sounds like you have two Magisk Apps not playing nice with each other.

The stub (the hidden Magisk) and the main one (un-hidden one)

After you click on the button to hide Magisk, it creates the stub and it is supposed to delete the main one, it sounds like it failed to delete the main one.

Check if you have both, uninstall one and you should be fine.
[Magisk] knojap:
That was easy. Thank you very much :-)
[Magisk] pndwal:
Thanks for clarifying this stuff...

Interestingly, this thread indicates that Galaxy note 10+ (at least some Snapdragon models) can support Magisk in boot!:

https://xdaforums.com/t/28nov20-gui...r-note-10-flash-twrp-snapdragon-only.4195891/

Is yours Snapdragon (Qualcomm) soc? Have you ever tried traditional patching boot.img (ie. patching AP w/ recovery mode deselected)?...

Generally this traditional setup is preferred over Magisk in recovery, and most Magisk users don't have the option to boot to unrooted system afforded by Magisk in recovery in any case... They just concentrate efforts on hiding root for bank apps...

It does seem unusual that you say most of your bank apps work when booting unrooted... This would indicate that these are checking for root/Magisk but are not checking PI API's deviceIntegrity verdict as this will necessarily be failing w/ a stock ROM and B/L unlocked... This is not unheard of, but I believe most bank apps do both, so if failing with root most should be failing w/o it also...

Unless you have a custom ROM that properly spoofs locked bootloader / PI deviceIntegrity, root is very useful for hiding as it can support device integrity spoofing (per USNF) root hiding (per Shamiko), applist hiding (per HMA) etc...

Re. normal power-up booting recovery mode Magisk, I see @J.Michael reported similar results to you on a Sammy tablet... I found his comment here too:

https://xdaforums.com/t/magisk-root-for-the-galaxy-s10-series.3918699/post-88037355

... so perhaps some mechanism has been found and added to use standard power-up for booting system with Magisk on some devices despite instructions saying you'll always need to boot using recovery key combo (which includes plugged USB PC connection or headphones w/ A11+ Sammy devices) w/ correct release timing to boot with Magisk root... I might look for this code when I have time, but it wouldn't be the first time undocumented changes in Magisk have caused confusion. 🙃 ...

Maybe @J.Michael may be able to recall/revisit his 'easy' method of bypassing recovery mode Magisk to boot system w/o root? 🙏 😋 ... PW
[Magisk] FreSchDude:
I have no idea how to check this...

Nope, I never tried it nor saw it as necessary because I preferred the dual-boot system.

Thing is, I can't get it to work. If I can, I'd consider it, but I only have one device, and if I can't access my bank or government apps, I'm in some deep crap. It's a little too risky to me to have only a rooted mode at this point in time.

I'm extremely confused by this. TB Checker passes almost all the checks when root is hidden, but the apps still somehow detect root.

Thing is, if I'm already in normal mode, and reboot the device, it doesn't go into recovery, but does a normal boot. Only if the previous cycle was in recovery, do I encounter this issue.

Example: I'm in recovery. I shut down my phone. I boot it up normally with nothing plugged in and no combination. It goes into recovery.

I'm in normal mode. I shut down. I boot normally. I'm in normal mode.

It's extremely weird to me.

(Oh, and BTW, whenever I say "recpvery" I mean android rooted mode, not actual recovery mode of the phone. I never boot into my phone's recovery mode, only into rooted android "recovery" mode)
[Magisk] pndwal:
I think it's been that way for a while... @vvb2060 added stub calling to ensure app always is restored on reboot where absent... It may have been broken/removed in 25.2 build (and perhaps some earlier builds?) but I don't knew why... possibly a regression/oversight...

Stub is only good when it's data is populated with Magisk APK data/binaries... It is generally used to obfuscate Magisk when user takes Hide the Magisk app option, but I think it can be used in place of full App also...

And you're not the first to complain about Magisk daemon restoring App... Seems Devs may be trying too hard to protect us from ourselves sometimes with these types of 'protection' mechanisms... 🙃 😬

... I can fully bypass Applist Detector however... Are you using LSPosed Hide My Applist by same dev? 🙂 PW
[Magisk] pndwal:
Actually, looks like it's Exynos...

Versions: SM-N975F (Europe); SM-N975F/DS (Global)

https://m.gsmarena.com/samsung_galaxy_note10+-ampp-9732.php

EMEA = Europe, Middle East, Africa. LATAM = Latin America.

Could confirm with app like CPU-Z...

😆

🤷

But you haven't/won't try most common methods!... Many banks checking applist (circumvent Google's intended usage really), some check for Zygisk hooking etc... Don't be confused! TB checker misses much too...

Very interesting... Thanks for the insight...

I gathered that... You really mean 'system with Magisk in recovery ramdisk' or 'system with Magisk root via recovery'... Bit of a mouthful... PW
[Magisk] pndwal:
Thank you for the insight into your rationale! 😋...

Actually you made my comment "Strong personal view..." Not "Strong Integrity...", and the misquote remains... One word fix, quicker than explaining...

Hope my point re. "Google... not allowing exclusive use (it's all devices or none) of such strong attestation verdicts for device integrity" is clear now anyhow. PW
[Magisk] FreSchDude:
It's this one. Thought the DS didn't matter because the firmware browser online didn't have a F/DS version, just an F version.

yup lol

Guess there is no real way to properly hide root for now, guess the reboot method is the only way. Thank god that magisk has a "reboot to download" option so I don't have to waste time holding down the key combination. I also keep a headphone dongle in my bag at all times in case I wanna boot to recovery. (or as you call it "system with Magisk in recovery ramdisk" 😆)

Thanks for the help so far, here's hoping updates come out eventually that allow me to permanently stay in root - I rely on root for some automate scripts that I run, and the only alternative is to run ADB on my phone, which requires a PC to change the TCPIP port every reboot.
[Magisk] a9381:
thanks.

Now, I got a new error... I googled a bit for information and didn't find a good explanation.

Does anyone have any information?
[Magisk] J.Michael:
Which error do you want help with? deprecation, unchecked, unsafe, only if predicate?

Did you try the suggestions to get more information?

Maybe you bungled the upgrade. (I remember some mention of changing from Java 11 to Java 17.) Maybe you should uninstall Java (or the IDE, or the SDK; I don't know how many pieces you had to install) and try a fresh install.

Or maybe you just need to find a "clean" option in the build process, to make sure everything gets recompiled.
[Magisk] ben_deez:
Hello.. I wanted to report that the latest update for Magisk breaks my System UI. Immediately after update my screen goes black and I have to reboot and when it boots the nav bar and home buttons are missing and I also cannot get into system settings... The only way I managed to fix it was restore a backup of my boot partition. I have a Oneplus 7 pro
[Magisk] a9381:
In everything, I tried to run with -Xlint:deprecation and I didn't understand what was happening exactly. But it didn't help. I also ran

python ./build.py -r -c config.prop.sample clean and didn't help.

I am using JDK 17.
[Magisk] J.Michael:
You need to look at the build process to see if "clean" is an option. And to see how to specify options. My first guess is you tried to compile a file named "clean" -- did you get any error messages?

None of the suggestions, like "-Xlint:deprecation", is expected to *fix* your problem. Each is a way to get more details about the error message.

It is not clear what problem you really need to fix. Probably the "only if predicate" -- the others could be warnings that have always been there.

If you have no experience programming, this is probably not a good choice for a learning project.

Why are you trying to build Magisk?
[Magisk] a9381:
I'm interested in a Magisk that will grant root permissions automatically and without warning (I know it's not recommended, but I want it for myself and my friends [of course the security hole in this will be highlighted to anyone I give it to]) so I edited config.kt

In the future I will also want to limit this Magisk that will give root only to certain applications, but that is the next step in my research.
[Magisk] gsmdb:
Maybe I didn't write clearly.

In build 25.2 there is NO stub.apk in Magisk Apk then system-as-root does still exist when the root apps request root access if you DELETE the reel magisk app.

In build 26.1 there is stub.apk in Magisk Apk then it does still install automatically a magisk placeholder app (hidden magisk app) when the root apps request root access if you DELETE the reel magisk app.

I did change the boot_patch.sh then remove the lines where patching the stub.apk in ramdisk (samsung s20 android 13). It does still install automatically a magisk placeholder app (hidden magisk app) when the root apps request root access if you DELETE the reel magisk app. So both builds do patch the boot image identically.

I wonder why there is included stub.apk in build 26.2?
[Magisk] zgfg:
When posting a long code (or kog, etc) please use (click to Spoiler to open and close):

Spoiler content hidden.
[Magisk] ipdev:
Sorry I missed your message earlier. :oops:

I will have to look at the error tomarrow.

Quick look. :unsure:

You gradle install is the wrong version?

You are running a release build, did you create a signing key?

Generate an upload key and keystore - [developer.android] - [website] - Link

Skip the -r -c options and try just running all.

python ./build.py all

If it builds, it will be the debug versions.

Make sure to run the ndk build before you run an apk build.

---

You can ignore the Xlint errors for now. 😉

I use a bash script to automate my build(s).

Example - [GitHub] - mk_snapshot.sh

I replaced my key and alias with xxxx in the script for sharing.

I am not going to give away my signing key. 😉​

From when I ran a build tonight.

[ip@lost Magisk-build]$ ./mk_snapshot.sh

Current Magisk version : 468f3efb1
- Backup /home/ip/github/Magisk-build/snapshot/20230413
- Building Magisk version : 83d837d86

* Cleaning native

* Cleaning java

* Downloading and extracting ondk-r25.2-linux.tar.gz

* Patching static libs

* Building binaries: magisk magiskinit magiskboot magiskpolicy busybox

* Building the Magisk app

Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: /home/ip/github/Magisk-build/Magisk/stub/src/main/java/com/topjohnwu/magisk/DelegateComponentFactory.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.

Output: out/app-debug.apk

* Building binaries: magisk magiskinit magiskboot magiskpolicy busybox

* Building the Magisk app

Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: /home/ip/github/Magisk-build/Magisk/stub/src/main/java/com/topjohnwu/magisk/DelegateComponentFactory.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.

Output: out/app-release.apk

[snapshot d19b529] Snapshot: Upstream to 83d837d86
5 files changed, 2 insertions(+), 2 deletions(-)
Enumerating objects: 13, done.
Counting objects: 100% (13/13), done.
Delta compression using up to 12 threads
Compressing objects: 100% (7/7), done.
Writing objects: 100% (7/7), 2.65 MiB | 1.07 MiB/s, done.
Total 7 (delta 2), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (2/2), completed with 2 local objects.
To github.com:ipdev99/magisk-files.git
b5c17b3..d19b529 snapshot -> snapshot
[master 6787629] Snapshot: Upstream to 83d837d86
2 files changed, 8 insertions(+), 8 deletions(-)
Enumerating objects: 7, done.
Counting objects: 100% (7/7), done.
Delta compression using up to 12 threads
Compressing objects: 100% (4/4), done.
Writing objects: 100% (4/4), 468 bytes | 468.00 KiB/s, done.
Total 4 (delta 3), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (3/3), completed with 2 local objects.
To github.com:ipdev99/magisk-files.git
f0d1640..6787629 master -> master

Done.

Cheers. :cowboy:
[Magisk] pndwal:
Could be to do with your earlier comment:

if member used OpenJDK? PW
[Magisk] ipdev:
Naw. 😏

Java was an easy one to figure out. 😉

With OpenJDK, it is due to missing file(s).

Build looks like this.

[ip@lost Magisk]$ java --version
openjdk 17.0.6 2023-01-17
OpenJDK Runtime Environment (Red_Hat-17.0.6.0.10-1.fc36) (build 17.0.6+10)
OpenJDK 64-Bit Server VM (Red_Hat-17.0.6.0.10-1.fc36) (build 17.0.6+10, mixed mode, sharing)

* Building the Magisk app

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:shared:compileDebugJavaWithJavac'.
> Could not resolve all files for configuration ':app:shared:androidJdkImage'.
> Failed to transform core-for-system-modules.jar to match attributes {artifactType=_internal_android_jdk_image, org.gradle.libraryelements=jar, org.gradle.usage=java-runtime}.
> Execution failed for JdkImageTransform: /home/ip/Android/Sdk/platforms/android-33/core-for-system-modules.jar.
> jlink executable /usr/lib/jvm/java-17-openjdk-17.0.6.0.10-1.fc36.x86_64/bin/jlink does not exist.

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 2s

Build app failed!

Cheers. :cowboy:
[Magisk] pndwal:
Wording here is confusing...

Also, stub should have been there in 25.2; I know these changes were made in 25207:

- Stop embedding stub.apk in magiskinit · topjohnwu/Magisk@ad0e651

- Remove unexpected files · topjohnwu/Magisk@2c53356

(removes stub.apk from /data/adb/magisk)

- Remove redundant stub.apk · topjohnwu/Magisk@b9213b7

to clean up code, but, among others, broke addon.d for custom rom users...

The changes above were reverted in time for 26.1 however with:

Fix scripts …

manager.sh + boot_patch.sh:

- all listed files from boot_patch.sh header are required for boot patching, but stub.apk was being removed so install_magisk via addon.d.sh would fail without it; leave it in place

addon.d.sh:

- remove old redundant recovery_actions call (it's also performed by setup_flashable in initialize)

- print ABI to match flash_script.sh output

boot_patch.sh:

- catch and abort on any errors from ramdisk.cpio patching in the future

util_functions.sh:

- fix hiding of mount_partitions /system_root umount stderr

- quote mount_apex .pb DEST name parsing charset for safety even though both work

Fixes #6828

... What I mentioned was that this behaviour goes way back... I think I said on reboot, but you are likely correct about installation on request for superuser permission...

Hope the changes/reversions mentioned above shed some light... 🙂 PW
[Magisk] gsmdb:
I've tested several times on both builds.

My evaluation is

- Build 25.2 despite of deletion magisk app the system-as-root is permanently. The stub app (hidden magisk app) appears only when NEW root access requested

- Build 26.1 with deletion magisk app system-as-root (SAR) is lost. The stub app does install by itself to handle SAR without any NEW root app involved

Don't know that is the main reason in build 26.1 or a bug.
[Magisk] J.Michael:
Please try to use words you have seen in other people's posts.

I do not understand "system-as-root is permanently" or "system-as-root (SAR) is lost".

System-as-root is not a Magisk concept, or a Magisk function. It is a change in organization. I think it was just a choice to use a partition named "system" as the "root" of the filesystem -- the partition named "system" is mounted at directory "/", the "root" of the filesystem. (Nothing to do with the root user, or root privilege, or rooting a device.)
[Magisk] gsmdb:
My example with root explorer app with deletion of magisk app

- In build 25.2 when open root explorer it doesn't request new root access as it is already gained the superuser permission so I mean the root access is permanently

- In build 26.1 when open root explorer it DOES request new root access and the stub app installs automatically in background to handle the root access
[Magisk] a9381:
I didn't understand what you meant, I have Gradle installed that came with Android Studio. I didn't install anything special. Need to install something special? In normal applications (I wrote or just compiled source code) it was enough.

Of course I have my own keystore.

Of course I run the ndk build before I run an apk build.

I used your script (because I'm on Windows I used Git Bash), and it wrote

Current Magisk version : 83d837d86
- No Change.

Done.

But I haven't found a built APK yet. What I did not understand?