yashsingh1/xdaforums huggingface dataset:
[Magisk] Oki:
I have a quick test backup so I can perform quick tests. So it doesn't require so much time and energy ;)

Regarding my device, it is a ZTE Axon 7 submodel A2017U. By the way the Axon 7 rocks!!! amazing screen, sound, processor, battery, looks, and only the camera (20Mpx) is not on par to the rest of the system. I love it, the best was the price.

The ROM used in this test is stock B29, the latest OTA available. Magisk Manager 2.5 and phh Superuser 1.03.3 apps were previously installed. I followed these steps to create the dump files:

1. I dumped before.boot.img from TWRP and the corresponding before.logcat.txt after rebooting into the system.

2. I went to TWRP and flashed Magisk v9 and phh Superuser for Magisk r266-2 in the same session. Recovery.log is also attached.

3. I rebooted directly to TWRP again and made a dump of the boot image, called after.boot.img. Then I rebooted the system and dumped after.logcat.txt.

4. After testing that Magisk is not working and the system was not rooted, I rebooted into recovery to dump magisk.log, but there was no Magisk log file inside /cache.

The dumped files can be downloaded from this MEGA shared folder. I hope these files could provide some insight on the problem in this device. Same issue when using Magisk v7 and V10-161227. And when using phh Superuser for Magisk r266. I have tested all combinations.

By the way, thanks for all!!! I hope this could work also in this device.
[Magisk] Homer-S:
Hello

why do I get error message while trying to download zip files from post #1?
[Magisk] Captain_Throwback:
https://twitter.com/xdadevelopers/status/814858638812659712
[Magisk] Vuska:
Hi.. I'm new with Magisk phh superuser.

My device is N910G with Note7 rom port Aurora v5 and Ram kernel v5.

Magisk already installed.. phh superuser r266-2 and superuser app too.

All program that need root already gain root permission.

My problem is : when i use terminal... i cannot use su command..

It say "no su command....."

Can someone help about this ?

Thank you
[Magisk] Nomelas:
make sure you have busybox installed. (You can enable it from the magisk manager settings btw)
[Magisk] Vuska:
In setting already enabled... but yes.. I'm not yet install busybox.

Update...

Just installed busybox and test...

But when i called su command..

Really confused.. [emoji20]
[Magisk] akk29:
So I'm discovering more apps that don't work correctly with this but work with SuperSU. Macronos and 3c Toolbox. However with these 2 apps they do request superuser permissions but just don't work correctly. With Macronos it fails to install as a system app and with 3c Toolbox moving apps to the system partition fails - change to SuperSU and they work. There must be fundamental differences between the 2 apps / methods but my technical abilities regarding this is limited. Any ideas from those more knowledgeable?
[Magisk] LucentBirch:
Suppose no reason found yet as to why root is lost Randomly and only returns upon reboot?
[Magisk] jsaxon2:
It seems to be fixed with latest commits to GitHub. New version should coming out soon. If you want, you can check out the unofficial version 10 that is compiled from source. It's working great for me.

https://xdaforums.com/apps/magisk/unofficial-magisk-v10-beta-built-t3521901/page9
[Magisk] koko115:
Hello guys. For one Happy New Year. For second... after instal magisk, then phh supersu 2.66-2 in TWRP after this xppsed from magisk and reboot. After reboot i go to magisk manager for magisk hide... after second reboot this is my log.. how fix this ? GALAXY S7 DECEMBER ROM Stock DEODEX. Enforxing.
[Magisk] rignfool:
Not that I really know the answer...

But SuperSU has a well know SELinux policy patcher... That I'm sure both those apps rely on to work... supolicy I think...

And I'm sure they've never heard of the one magisk is using... sepolicy I think

From what I understand... Syntax is the same... But that swapping a U for an E in a binary... is unforgivable...
[Magisk] akk29:
Thanks for the info. I thought the issue might be with the magisk version but I'll report the issues to the app developers to see if they are able to fix it. Unfortunately I doubt I'll see a fix for STweaks as my ROM comes with integrated SuperSU. If anyone with the skills can take a look at the Github for STweaks in my previous post and offer a solution it would be appreciated.
[Magisk] Deic:
Is a problem with Termux that have custom ".mkshrc" & other own PATHs, etc... Try running "su" as

/sbin/su

or simply install Terminal Emulator for Android.
[Magisk] Vuska:
Hii.... new update 2017.. asking for update binary..

How to do that ?

Thank you
[Magisk] Captain_Throwback:
Download the module from the modules tab in Magisk Manager or download the latest zip from this thread and install it.
[Magisk] yung40oz84:
I am so confused, to my understanding the latest version worked with f2fs, I flashed magisk in recovery and it says no root..........Also tried through manager, also tried flashing magisk and superuser, still says no root
[Magisk] Captain_Throwback:
What makes you think f2fs is the problem? Plenty of devices use f2fs and have no issues with Magisk.
[Magisk] yung40oz84:
well.....for starters I just went to ext4 and followed the exact, identical steps as I did on f2fs and I pass safety net, superuser installs, magisk works and installs. I have tried f2fs and ext4, f2fs is not working at all, when I follow same procedure, I have no root
[Magisk] westeight:
Latest. r2 version still not working. Reports 'The su binary is out of date'

Anyone know how to fix it ?
[Magisk] habylab:
Try flashing the zip again.

If not, revert to stock boot.img and cleanly install.
[Magisk] svemprala:
Installing phh through magisk wasn't working, so I tried to install the r2 zip from recovery. It says "updater process failed with ERROR: 2". I am on an LG G3, any suggestions?
[Magisk] Nomelas:
completely remove Magisk using the uninstaller. I also suggest running unSU and/or cleanupSU as it cleans up any leftover SU files you might have lying around. I do this every time I need to re-root.

Next, flash the lastest Magisk (10.2 as of this writing) and it will auto flash r2 of phh superuser, no need to manually flash. Then install all other modules as normal.
[Magisk] ugvpkn:
Updated to the latest Magisk 10.2 with the latest phh r2 root from the updated magisk manager app. Safetynet is now failing with a 'CTS profile mismatch'. This is on RR 7.1.1 latest XMAS release with Electron kernel v6 which has the verifiedbootstate fixed. Magisk Hide is enabled in settings and I rebooted multiple times. Thanks !!

I had working Safetynet with magisk v9 and r266-2. I will try a re-install of magisk.

The magisk logs are here - http://pastebin.com/Ce4n8PKm
[Magisk] Captain_Throwback:
Enable the advanced logging options and grab another log, please.
[Magisk] ugvpkn:
I had both the logging options enabled and rebooted my phone. Thanks !!
[Magisk] ugvpkn:
I uninstalled magisk using the uninstaller script in TWRP and installed it again. Safetynet is passing now !!

I captured the logs this time also - http://pastebin.com/WbSredu9

Thanks for all the help.
[Magisk] adenayank:
cts profile mismatch

please help got error on magisk 10.2 cts profile mismatch on htc one m8 ice 8.2.2 fresh install:crying:
[Magisk] qbus00:
Hello,

Anyone noticed that on newest Magisk 10.2 with Superuser app (doesn't matter what version) when entering adb shell it's ALWAYS possible to gain root by invoking su (no message/toast anything) no matter what option is set i SuperUser app (No access to root, Access by apps, by TWRP and apps together with TWRP). Actualy even when no root is selected in Superuser monit when app wants a root steel appears.

I'm not sure if this problem was present on previous versions, just noticed this today.

Details:

HTC 10 with SOFF, and US stock firmware/system 2.38.617.6
[Magisk] Alpine-:
I just updated to latest magisk. Had root with superu before. Updated and it couldn't detect root, rebooted and it installed phh modified superuser root (I guess) instead. That's fine I guess, I don't see a downside.

But I'm now failing safteynet with the cts profile mismatch error as well. Prior v9 with su was working fine. What now?
[Magisk] Has_anDroid:
safetynet problem ?
[Magisk] ChenG34-:
After updated to v10.2, SafetyNet failed for me too, CTS profile mismatch. I tried to reinstall, flashed Uninstaller then v10.2, enabled Magisk Hide, same result.

I'm going to stick with v9 at the moment.
[Magisk] kiefferbp:
I am on Magisk v10.2 with no issues.
[Magisk] Alpine-:
But you don't have a Samsung device right?

Magisk for stock Samsung kernel needs some tweaking. Namespace Processes are hidden on Samsung thus causing the issue with Magisk Hide (safteynet doesn't pass). It could take a while or never get fixed, I don't know. I'm hopeful. But if it doesn't, I guess people with affected devices could revert to v9 if it never gets fixed.
[Magisk] Flying Scotsman:
Nexus 6 Stock 7.1.1; Magisk 10.2; Stock Kernel etc and safetynet fails.

Tried finding a kernel which bypasses the unlocked bootloader issue, but haven't found one which maybe the issue.
[Magisk] kiefferbp:
There's your problem. You need a custom kernel that hides the bootloader unlock status from the OS. ElementalX and Franco both do this for the Nexus 6.
[Magisk] Link_of_Hyrule:
Wipe your system manually, wipe cache and dalvic, install rom, install gapps, install magisk, install modules, enable Magisk hide and reboot. You shouldn't need to wipe your data.
[Magisk] Captain_Throwback:
No, you don't need that. Magisk patches that automatically when Magisk Hide is enabled.
[Magisk] Oki:
It is still not working in the ZTE Axon 7. I can provide the boot images before and after patching it along with logcat and dmesg. If you are willing to solve this issue just let me know what you need, I can share those files with you and do further testing.

I am eager to see it working in this excellent device.

Thanks!
[Magisk] Captain_Throwback:
Does the "regular" phh Superuser successfully work on your device?
[Magisk] piats:
Anyone able to use this root method with cm / aosp based roms with f2fs?
[Magisk] Captain_Throwback:
[MENTION=4470081]topjohnwu[/MENTION] tests on his Nexus 9 running f2fs and it works fine.
[Magisk] piats:
Hmm is he using custom ROM or stock ROM?

For me stock (Oxygen OS) ROM works fine.

Custom ROMs don't get rooted properly. Su app says outdated binary.

Without magisk phh's root works fine with every ROM.
[Magisk] Andreasworks:
on HTC m8 and Roma RR 58 and it has left so ... solutions? thank you
[Magisk] Oki:
Tested with phh's r266, r266-2 and r2 and Magisk v7, v9, v10 and v10.2. Same issue with all of them. I already provided the logcats and boots, both before and after. Recovery log doesn't return any error while flashing.

Regular phh Superuser properly roots the device but it can't be hidden and Magisk is useless with the regular phh's Superuser.

Please help.
[Magisk] kiefferbp:
I am using Magisk v10.2 on CM14.1 I don't get the "outdated binary" message like I did on v10 and I pass SafetyNet.
[Magisk] yung40oz84:
Myself and some others cannot get it running on CM based Roms or AOSP based. Only root option worked for me.on RR and DU was regular version, r259 of superuser. SuperSU, nor magisk compatible superuser r2 and magisk would work. I tried numerous methods, just data f2fs, day and cache f2fs, different ways of flashing, etc. It flashed correctly, but soon as boot it says no root present. I did provide logs and boot.img some pages back, hopefully they get looked at then. Just thought I'd help! Cause I had a headache, ended up going back to ext4.
[Magisk] piats:
Are you using f2fs filesystem format?
[Magisk] SphunaR:
Hello!

It's working on MIUI EU?

For example I use Mi5 and I have "cts profile mismatch" ;/
[Magisk] Filip013:
I have a Xiaomi Redmi 1S and Redmi Note 3 Pro and both of them get CTS profile mismatch on un-rooted stock ROMs. I think this is a problem with MIUI and not Magisk.
[Magisk] txvs:
Mi5 with MIUI EU Dev working root and safetynet with Magisk v9, but only root but no safetynet works with Magisk v10.2.

Tried reinstall wiping cache and not wiping, uninstall before update. Enable hide and reboot... No luck...
[Magisk] SphunaR:
I did it also.

Only root works.

So on Magisk v9 can I use Android pay or not?

It's all I want :)
[Magisk] Setialpha:
Are you all sure selinux is enforcing? If not, that's what triggers SafetyNet.
[Magisk] Prattham:
I'm on oos 3.2.8 with 1+3

I installed 10.2 and both managers then I check safely net it says cts profiles mismatch and fail safety net pass

Kindly help , I am new to this been using SuperSU by this time

Also I cleaned flashed rom and even flashes unsu

I enabled magisk hide option and systemless options and reboot

Still that cts error

So i tried V9 with phh super su 266-2 and i get same cts errors

Help is really appreciated:)
[Magisk] Didgeridoohan:
Magisk log?
[Magisk] Prattham:
Not sure how to get one

As I have said I am really new to this stuff

Can you help how to get one?
[Magisk] mobileman88:
Both v9 and v10 works with ap for me. You just need to have a clean Magisk install without xposed
[Magisk] Didgeridoohan:
Ok... Maybe you should start off by doing some reading then. Official announcement thread is a great read. After that I'd start searching through this tread if I were you. Magisk Hide and Safety Net has been discussed about every second post.

About logs, have you even opened the Magisk Manager? It's right there, under "Log". And if you haven't already, check the "Enable advanced debug logging" in settings.
[Magisk] Prattham:
Here it is
[Magisk] Didgeridoohan:
Like I said, you seriously need to do some reading. Magisk Hide cannot hide Xposed. Disable or uninstall...
[Magisk] SphunaR:
gemini:/ $ sestatus

/system/bin/sh: sestatus: not found

127|gemini:/ $ getenforce

Enforcing

I attached error log.

Maybe now?
[Magisk] Prattham:
That's before xposed

I was trying to experiment and install xposed

But the issue is still there without xposed
[Magisk] Didgeridoohan:
Have you rebooted since uninstalling Xposed? If you had it shouldn't have shown up in the Magisk log... How about a reboot and a fresh log?
[Magisk] biolex:
I had the same issue of SafetyNet failing after updating to v10.2 on my Galaxy S6 Edge. What I ended up doing was installing an Xposed module called No Device Check and now my SafetyNet passes.

Hope this helps some of you with this issue.
[Magisk] Prattham:
I confirm this
[Magisk] beauh82:
Magisk post-fs mode running...

** Magisk post-fs-data mode running...

* Preparing modules

* Stage 1: Mount system and vendor mirrors

* Stage 2: Mount dummy skeletons

* Stage 3: Mount module items

* Stage 4: Execute module scripts

* Stage 5: Mount mirrored items back to dummy

* Enabling systemless hosts file support

Mount: /magisk/.core/hosts

** Magisk late_start service mode running...

service: /magisk/phh/service.sh

phh: Live patching sepolicy

phh: Moving and linking /sbin binaries

phh: Mounting supath

phh: Starting su daemon

* Removing tampered read-only system props

* Starting Magisk Hide

MagiskHide: Update process/package list:

MagiskHide: [com.google.android.gms.unstable]

MagiskHide: [com.nianticlabs.pokemongo]

MagiskHide: [com.topjohnwu.magisk]

MagiskHide: [me.phh.superuser]

Zygote(0) ns=mnt:[4026536629] Zygote(1) ns=mnt:[4026536630]

What is causing me to fail safetynet?
[Magisk] jsaxon2:
Why are you hiding magisk and superuser??? If you only need to pass SafetyNet, do not select anything in the app list. Magisk by default hides from SafetyNet. That is the com.google.android.gms.unstable. The other 3 should not be selected. Uncheck those and reboot and try again.
[Magisk] 5m4r7ph0n36uru:
Unlocked bootloader and custom kernel can cause SafetyNet to fail. Without precise information about what has been modified on your phone it is impossible to tell.

Maybe, only maybe, it helps to read and to provide a full status of your phone... Remember that some are online via apps, so it won't help if they are given in your signature. State the full status of your phone always to enable other to help.

He can hide Magisk from the others as well if he wants to. This should not change anything regarding his SafetyNet issue.
[Magisk] FurySh0ck:
Let's say I have CF's supersu right now, and want to switch to phh's (magisk compatible ofc).

I gotta flash factory firmwares for my phone, in order to remove current root. It's the boot.img, system.img and vendor.img as far as I can tell. The problem is, I don't really want to (I got some issues with the PDA and CSC validation, I would rather not to share too much about it right now).

If I'll do a factory reset/wipe (through TWRP), will it serve the same purpose? If it will, what should I mark in the advanced settings (dalvik cache, system, data, cache, USB-OTG etc...)?
[Magisk] beauh82:
Magisk post-fs mode running...

** Magisk post-fs-data mode running...

* Preparing modules

* Stage 1: Mount system and vendor mirrors

* Stage 2: Mount dummy skeletons

* Stage 3: Mount module items

* Stage 4: Execute module scripts

* Stage 5: Mount mirrored items back to dummy

* Enabling systemless hosts file support

Mount: /magisk/.core/hosts

** Magisk late_start service mode running...

service: /magisk/phh/service.sh

phh: Live patching sepolicy

phh: Moving and linking /sbin binaries

phh: Mounting supath

phh: Starting su daemon

* Removing tampered read-only system props

* Starting Magisk Hide

MagiskHide: Update process/package list:

MagiskHide: [com.google.android.gms.unstable]

Zygote(0) ns=mnt:[4026536629] Zygote(1) ns=mnt:[4026536630]

OK I unchecked everything. Now why am I failing?

Running pure nexus and ex kernel. Substratum. Swiftdark. I do have hacked YouTube app and am running a kernel profile drunksauce lite. Also have adaway. Everything passed before updating to magisk 10.2
[Magisk] 5m4r7ph0n36uru:
Then you've been lucky maybe. I'd guess it is the custom kernel causing the fail. The check hasn't been fully implemented on prior versions, at least as far as I know. Thus the information in the prior Magisk version might have been wrong and SafetyNet already failed back then.
[Magisk] beauh82:
I was able to play pokemon go before v10.2. Also ex kernel by flar2 has always passed safetynet
[Magisk] 5m4r7ph0n36uru:
In that case it has to be any other modification. Can't tell you which one exactly.
[Magisk] jsaxon2:
Are you SELinux Permissive or Enforcing?
[Magisk] beauh82:
How can I tell if I'm selinux permissive or enforcing? And how do I change it
[Magisk] Didgeridoohan:
Pokemon doesn't need Safety Net to fully pass. Has the game stopped working since v10.2?

Type getenforce in a terminal emulator. If it's permissive you'll need to change it. Plenty of guides around... Google.
[Magisk] beauh82:
When I type get enforce it says enforcing
[Magisk] popper668:
Stickmount

Hi, does anybody have any StickMount alternative? I just started using Magisk, Phh's Superuser, and I discovered that StickMount doesn't work with this configuration. Any suggestion?
[Magisk] FurySh0ck:
Can I switch to phh's supersu if I use the switch Superuser service cf's Superuser has to offer? (I am currently using cf's).

If I can't, what other methods can I use beside flashing factory images?
[Magisk] Didgeridoohan:
Use the full unroot option in the SuperSU app. After that I'd also flash the stock boot image prior to installing phh's.
[Magisk] FurySh0ck:
I'm trying to avoid flashing any factory images. Can I use any wipe through TWRP instead?
[Magisk] Didgeridoohan:
You can flash the boot image in TWRP. Just extract it from the factory image...

I always keep a copy of my boot image on my device. Since Magisk only modifies the boot image I can easily get out of any problems if I mess anything up.
[Magisk] FurySh0ck:
Does the boot image has anything to do with the PDA or Csc? Because I would rather not use it if it does.

If it has nothing to do with the PDA nor Csc, where can I get the boot image? (I use Samsung Galaxy S4 GT-I9515 device, but there are a lot of options for this specific device at sammobile)
[Magisk] X46X:
is there some manual how to switch from Chainfire SuperSu to Phh?
[Magisk] chrisc93:
Hm, that's odd. What root apps do you use?
[Magisk] joeyddr:
its either kernel auiditer or better battery stats
[Magisk] chrisc93:
I use Kernel Adiutor too, but not better battery stats. It may be that one. You could always try a

killall -g

on line 395 in the magic_mask.sh
[Magisk] joeyddr:
ok so after a reboot the -l edit on the unmount reverted.....
[Magisk] chrisc93:
Okay, so that file must be loaded somewhere during a boot. Was a reboot the cause of the issue you experienced earlier?
[Magisk] joeyddr:
yeah after i rebooted i tried the disable and it didn't work which is why i thought it was a root app but it seems the shell script reverted I noticed when i went to do the other edit.
[Magisk] Droidphilev:
Same on the nexus 6 stock rom. -l is gone after a (normal) boot.
[Magisk] joeyddr:
currently searching the phone for other copies... unless the app itself generates it on boot every time.

searched whole phone and only found the one copy under sbin
[Magisk] MattyCLFC:
I can confirm that both edits unmounted root for me. I can add a card however won't be able to test it for good until tomorrow. Timer doesn't seem to re-mount root (it does however work if I kill Magisk Manager). Great job guys. Definitely a step in the right direction :D

Edit: This is on a Nexus 6P running PN w/ Magisk v2 and phh's superuser v2.

Edit 2: The timer does actually work; just kill the magisk manager app
[Magisk] joeyddr:
odd it remounts it for me on the latest clean install of purenexus.
[Magisk] chrisc93:
I think it's the app that doesn't update the RootMounted TextView until onCreate is called again. So if you leave the app and come back, it should be correctly adjusted.
[Magisk] joeyddr:
yeah i have to close and reopen and it shows mounted again.
[Magisk] chrisc93:
EDIT: So I looked at the script used for flashing, and the bootimage gets loaded w/that magic_mask.sh file, so this is something that will reset at boot. We'll just have to wait for [MENTION=4470081]topjohnwu[/MENTION] to release the next version.

But this is a nice fix until v3 is released :)
[Magisk] MattyCLFC:
Mmmm strange. I am also on the latest version of purenexus..

killall -g su

and

unmount -l /system/xbin

let me pass Safety Net when I made the changes to the file required.
[Magisk] allen099:
Unfortunately neither this nor the "-l" had worked on my stock Nexus 6P with all the v2, minus exposed. Thanks for continuing to explore guys!
[Magisk] chrisc93:
Got it to stick on a reboot!

Just flash the modified v2 I've attached. Then flash phh-superuser v2 after and you should be good to go!
[Magisk] xc-racer99:
Well, you could reset your boot.img to stock, edit the install zip (magic_mask.sh is in the common folder) and the flash it again...

In any event, lazily unmounting now allows me to disable root here on Omni, can't test AP though as I don't have NFC, so thanks.

Edit: Whoops, hadn't re-loaded the thread and you got there ahead of me...
[Magisk] allen099:
No luck for me. Did you revert to stock boot or remove all traces of root beforehand?

I flashed over everything, and then reflashed phh superuser. Rebooted, modified time to 1 minute, disabled root, and got the error message when making a purchase.