yashsingh1/xdaforums huggingface dataset:
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
As of a few hours ago, I'm failing checks now. Anyone else confirm? Looks like it may be time to get back to work.

Wondering if it's Magisk that is causing it. If so, might need to try the solution where Magisk isn't involved.
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Same here. Others have reported being able to pass when they uninstall Magisk.
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
I'm able to get around using Magisk by copying xsetprop from the Magisk module into /su/xbin and putting a file into /su/su.d that uses xsetprop to set the locked prop to 1. Will try to be more detailed in a bit, if somebody requires more specifics. Can pass Safetynet again.

Thanks again to [MENTION=1162986]Captain_Throwback[/MENTION] for developing xsetprop.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
Very unclear what you are doing here. There was an update to play services and now I'm getting fail even inside helper app with red screen. Not sure what new think Google did besides the ro lock flag. Something else but dunno what.
[Nexus 6 Q&A, Help & Troubleshooting] antonyyip:
Oh no! Yesterday night I can still pay using AP, but this morning I check SafetyNet and the CTS Profile Match Failed.... something has been done by Google at the back!
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
Yes... Google play services got updated. Not sure if there is fix for this yet. Magisk modules working and ro.boot.flash.locked is 1. I'm going to try removing magisk and just use Franco kernel with rootswitch and systemless SuperSU
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
The problem is that you need xsetprop to set ro.boot.flash.locked to 1, and currently the easy way to do that is with Magisk. If you extract the xsetprop binary from the Magisk xsetprop module, and put the binary in /su/xbin (with the correct permissions), you can still use it to set ro.boot.flash.locked without Magisk.

The Franco kernel for the N6 doesn't do this for you. I checked.

I just made a purchase on Android pay, so I can confirm this works.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
One problem.... There isn't binary except if you mean in the zip of xprop.0.2.1. And there is no su/xbin on my device... Maybe because I use phh not chain fire superuser
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Yes, I'm using Chainfire's SuperSU. And, yes, the binary is in the zip of xsetprop.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
So where do I put that binary.... And do I need to add parameters? I'm confused. Pretty sure that phh is systemless too and I prefer that it is open source
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
I think phh probably has a similar xbin folder. You sure there's no /su/xbin (in the root of the filesystem)? Then you have to type "xsetprop ro.boot.flash.locked 1" in an su shell.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
There is an xbin folder... That's where su is located. Do I just place the binary there? How do I get it run upon boot since there isn't init.d
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
There probably is an equivalent of an init.d. Anyway you should try typing the command manually to see if you can get it to work. Then worry about getting it to execute automatically on boot.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
Yes it works. Just need to automate it.
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Well if everything else fails, you can do it with Tasker using the profile "On monitor start."
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
OK so I have that... But this isn't allowing me to get safety net working... Still red screen because maybe it sees superuser. Root switch??
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Yeah, Root Switch. And you're definitely using phh without Magisk, right? (I can only vouch for Chainfire's, btw.)
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
Yes. However it's not turning off root sadly. I couldn't get SuperSU to work. Not sure because I've screwd with so many flashes that I'm lost

---------- Post added at 03:34 AM ---------- Previous post was at 03:21 AM ----------

I do not think it is compatible with phh superuser... Because even though it is systemless.... Different mounts and directory structure.... So for now I'm just giving up.
[Nexus 6 Q&A, Help & Troubleshooting] antonyyip:
How about me? My setting is similar to this post: using SuperSU 2.78SR1, Suhide, Magisk Manager with Xsetprop and RootSwitch

I'm using HTC 10 with Viper 10 ROM

What should I do to get CTS pass again?
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
I have gotten it to work again using the setup in the OP. If you had it working before, here is what you should do:

Fully unroot (follow steps in OP), and additionally flash the Magisk uninstaller

Flash SuperSU, and suhide again

Reboot

Using a file manager of your choice, open the xsetprop zip file and extract /system/xbin/xsetprop to /system/xbin. Make sure permissions are 755 and the owner is root

Additionally, in the zip file, extract common/post-fs-data.sh to /su/su.d/ . Rename the file to 06post-fs-data.sh. Make sure permissions are 700 and the owner is root.

Using adb or a terminal program, run /su/su.d/06post-fs-data.sh

Disable root using Root Switch

SafetyNet should pass

I'll try to make the writeup more clear tomorrow morning once I sleep.
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
I don't think you should put xsetprop in /system/xbin, because this modifies the system partition (i.e., it's no long system-less). For Chainfire's SuperSU, you can put it in /su/xbin, and I think there's a similar folder for phh's superuser.
[Nexus 6 Q&A, Help & Troubleshooting] antonyyip:
I tried, but still failed... no hope.
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
There is no similar folder for phh's Superuser. It doesn't use a mounted image like SuperSU does, and will be detected by SafetyNet if using the standalone zip. Only SuperSU can pass at this point, along with suhide and probably RootSwitch.
[Nexus 6 Q&A, Help & Troubleshooting] Drefsab:
could someone who is doing this try the Sky Q/Sky Go apps out and see if they work. I am using a factory image using magisk v6 because of its root toggle, its doesnt pass safetynet but the sky apps work. If this works for those apps then I can upgrade my rom :P
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
You are right. It was working for me in /system/xbin but this is definitely not correct for a systemless install. I have updated the instructions in the OP with more clear instructions.

Ideally, we could make an flashable zip for the xsetprop so that it flashed stuff to the correct places. Maybe I'll look into that today.
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Messing around with this stuff, you can actually do a lot of Magisk-type stuff systemlessly just by putting it in Chainfire's /su/su.d (as [MENTION=631273]Chainfire[/MENTION] pointed out a few days ago). For instance, in order to enable the LED on my N6,

I extracted the modified lights.shamu.so from the Magisk module Nexus LED Enabler

I put it in a folder ("newfolder", in this example) in /su

I mounted it on top of the native LED driver in /system/lib/hw and changed its profile by inserting this code into a script in /su/su.d

mount -o bind /su/newfolder/lights.shamu.so /system/lib/hw/lights.shamu.so
chcon u:object_r:system_file:s0 /system/lib/hw/lights.shamu.so

After reboot, I have a working LED without modifying the system partition, thanks to the Linux behavior whereby mounting files or folders on top of existing files or folders makes the mounted files/folders appear to be there without modifying the files/folders they were mounted on top of. (I believe this is the guiding principle behind Magisk.) I did something similar to produce a substitute hosts file that Adaway will modify systemlessly without affecting the system partition.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
Yes the folder is sbin
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
/sbin is part of the boot.img ramdisk. It's not a mounted image like the su.img that SuperSU puts in /data and then mounts at /su. Thus, there's no location that will persist after a reboot. And phh's Superuser doesn't support su.d, but does allow for su --init to run scripts as root.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
So I shouldn't use phh??
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
The difference is that bind mounting requires the target file to already exist - Magisk can actually add new content to /system without actually writing to it ;).
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
You can use whatever root method you want - I was just providing information.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
I think using super SU... Is only tested. I believe the scripts for root switch fail if phh. I'm going to go on that assumption
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
Yes, Root Switch doesn't support Magisk or phh's Superuser.
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
I've been thinking about this (mainly because I want to get the Pixel Launcher into my /system/priv-app folder), and it seems to me I could bind mount all the files and folders in /system into a mirror folder, then add additional files or folders into the mirror folder, and then bind mount the mirror folder back to /system. I think this would work. Maybe this is how Magisk works. (Sorry to be off-topic.)
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
http://xdaforums.com/apps/magisk/magisk-details-dummies-to-developers-t3473486/post68967705

You should probably read that ;)
[Nexus 6 Q&A, Help & Troubleshooting] topjohnwu:
Yes, this is what Magisk is doing. More detailed, Magisk can automate this process, to create dummy folders, create a system mirror, bind mount from correct locations.....

You can also create multiple modules and run scripts. An upcoming release will also introduce multirom support for all Magisk supported devices (a lot)

Does that sound good enough for you to get interested in my project :D
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
I'm totally interested in it and was using it (without understanding it at all) until the latest apparent Safetynet update, which seems to make it impossible to use Magisk and pass Safetynet. I think it's a great solution to do some complex things very, very easily.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
I'm getting failure from installing superSU..... Help.... It's saying something about ramdisk then aborts... I'm very frustrated but do not think installing phh will work. I've tried several kernels but I cannot root with chainfire at all even beta SR2.... Please help.... I've googled and find no info on this error. It's trying to patch ramdisk but i haven't a clue what that means... How do I clear it????
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
Did you forget to do a full unroot from SuperSu before flashing again?

If so, I think there is some stuff you need to do:

1) Flash your stock boot.img

2)In TWRP, go to file manager and remove:

/data/su.img, /data/stock_boot_<lots of hex characters>.img.gz, /data/custom_*.sh (can't remember the exact file name here)

3) Try flashing SuperSU again
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
I didn't remove everything from phh I guess. I thought I only needed to flash boot image.
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
So I created a flashable zip that will hopefully flash xsetprop to /su/xbin and the required shell file to /su/su.d

Would anyone be willing to test this install out for me? I tested it on my own phone and it seems to work fine.

It does check to make sure it can mount /su properly, and checks to make sure /su/bin/su exists, as well as the folders /su/xbin and /su/su.d before trying to do anything. If you're not using SuperUser, then it will not work of course.
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Also (and I'm not entirely sure about this), you may benefit from flashing the stock boot image and allowing the phone to boot before rebooting to Recovery and installing SuperSU. And make sure you use SuperSU v2.78-SR1 (not SR2). SR2 has a different installation process, I believe, and I'm not sure if it'll work for the instructions here.

I think that when the stock boot image boots up, it may do some housecleaning. It will also probably revert you to stock Recovery, and you'll have to re-flash TWRP.

Can't promise this will help, but I've been in your shoes, and this is some of what I did, in addition to what [MENTION=2133630]skaforey[/MENTION] suggested.

---------- Post added at 03:38 PM ---------- Previous post was at 03:08 PM ----------

Whoa, pretty fancy. Haven't tried this yet (mostly because I'm afraid to mess with my cobbled-together version of this).

I wonder if you've also considered trying the Tasker way to automatically enable and disable Root Switch when certain apps are open. Running

/su/bin/su -c "/data/data/com.corner23.android.rootswitch/files/disable.sh"

in a Tasker "Run Shell" task with "Use Root" checked will disable root.

Running

/oem/bin/su -c "/data/data/com.corner23.android.rootswitch/files/enable.sh"

(do NOT check "Use Root") will re-enable it.

You can use the disable-root task in a Profile that detects certain apps (Safetynet checking apps, PoGo, Android Pay). I personally don't have Tasker automatically re-enable root when the app is exited, because it seems that some apps (I'm looking at you, Android Pay) seem to start other undetected activities when doing their thing; in this event, Tasker could re-enable root while Android Pay is doing a Safetynet check. My solution is that I put up a permanent Tasker notification when Tasker disables root, and then I have Tasker re-enable root when the notification is clicked.

I can't claim credit for these; I got the idea from [MENTION=7734865]lucbondar[/MENTION].
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
OP updated with instructions to use the flashable zip. I had a friend test the process and all seems well. It makes the install much easier. [MENTION=3770040]NYZack[/MENTION] I have not tried the Tasker script. I don't need root that much so it's not a big deal doing stuff manually, but that does seem useful. I'll add the info from above to the OP as an optional setup.
[Nexus 6 Q&A, Help & Troubleshooting] edyny1:
This won't work on the Galaxy s6 edge running MM 6.0.1 right?? I tried it and got the SafetyNet blue screen
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
I have no idea. This is a Nexus 6 forum and the thread is about Android N. I don't want to sound rude, but you should probably check the Galaxy S6 subforum. Best of luck.
[Nexus 6 Q&A, Help & Troubleshooting] sgloki77:
guys I'm having trouble flashing the Rootswitch zip, Im on stock 7.0 with elemental kernel, any ideas how to fix?
[Nexus 6 Q&A, Help & Troubleshooting] waylo:
Rootswitch is an app. Unzip it and install the apk.
[Nexus 6 Q&A, Help & Troubleshooting] odontastic:
I had the same problem until i extracted and installed the apk within the zip file.
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
Everything working great. I had to erase phh superuser files then followed instructions and got green safety net. Thanks for all the assistance.

---------- Post added at 06:56 AM ---------- Previous post was at 06:52 AM ----------

Speaking as former galaxy owner of note 5... Samsung has additional layers in their boot loader that aren't even addressed. And as is mentioned, this is discussion for Nexus 6 only. You need to ask in the sub forum for your device to get help. Also we are running Android 7 which is a totally different operating system than your device.
[Nexus 6 Q&A, Help & Troubleshooting] Seanbest:
Followed updated steps in OP, but have no root after rebooting to verify root. Suggestions?

Nexus 5X - Stock+ ROM with Franco v24 kernel
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
Keep an eye out for errors when you flash SuperSu. It's possible it's not getting installed correctly.
[Nexus 6 Q&A, Help & Troubleshooting] Gustave17:
Just FYI, It's working on a 6P (Android 7.0 + SuperSU 2.78 SR2)!

Thx
[Nexus 6 Q&A, Help & Troubleshooting] Constrabus:
Are we certain that rootswitch is necessary?

Has anyone tested safetynet helper without installing rootswitch?

The purpose of SUhide is to not have to disable root.

Technically you shouldn't need SUhide with rootswitch and vise vera. They are different methods of achieving the same thing.
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
Suhide alone no longer passes SafetyNet. So yes, RootSwitch is necessary.
[Nexus 6 Q&A, Help & Troubleshooting] Constrabus:
Ahh gotcha. I see.

But then so why do we need suhide then?

Might as well just not install it, since we're just temp unrooting with rootswitch anyway.
[Nexus 6 Q&A, Help & Troubleshooting] Captain_Throwback:
Because I believe RootSwitch requires it (or at least won't function properly for hiding root without it).
[Nexus 6 Q&A, Help & Troubleshooting] humulos:
Well, following the guide exactly I pass SafetyNet according to the helper app, but I can't make payments with Android Pay. What other things does Android Pay check that would prevent it? Cleared Data for the app, no luck there. Nexus 6P, Stock+Rooted as per the guide.
[Nexus 6 Q&A, Help & Troubleshooting] himagxol:
Will this procedure work on 6.0.1 and is this compatible with systemless xposed and btw what does xsetpropsu.zip do ,is it necessary ??
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
From the research I've done, xposed is detected now, and so is Magisk, so no, for our device, I don't believe it works.

xsetpropsu.zip installs the xsetprop binary to /su/xbin and installs a script to /su/su.d. Upon startup the script runs which sets some"normally" read only build.prop entries to values that safetynet checks for (checking for unlocked bootloader, etc).
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
I've had oddly inconsistent results with Android Pay. When I toggle Root Switch to deactivate root, I may have trouble making a payment, but it ultimately works after a few tries. I think it may have to do with forcing AP to check Safetynet again, but I'm not sure.
[Nexus 6 Q&A, Help & Troubleshooting] MrBrady:
There was a Tasker script on the Magisk AP forum a while back. Apparently there is some residual data that AP leaves running. Once the Tasker script runs, it clears out all that data and forces it to re-check Safetynet, which ultimately passes.
[Nexus 6 Q&A, Help & Troubleshooting] sgloki77:
safetynet checks out, but still I'm not able to make payments with AP, after several attempts
[Nexus 6 Q&A, Help & Troubleshooting] Seanbest:
I followed the instructions, but have no root after rebooting to verify root. No idea why. Following the steps exactly. Nexus 5X running Stock+ ROM based on latest image.

---------- Post added at 05:12 AM ---------- Previous post was at 05:11 AM ----------

No errors when flashing.
[Nexus 6 Q&A, Help & Troubleshooting] mobileman88:
Try adding a card first after turning off root . Then use AP to pay.
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
Would you mind posting a log of twrp when flashing supersu
[Nexus 6 Q&A, Help & Troubleshooting] humulos:
You wouldn't happen to have a link to that would you? I'm going to try searching myself, but in case I can't find it, that sounds incredibly helpful.
[Nexus 6 Q&A, Help & Troubleshooting] MrBrady:
This is the solution I've used in the past. It worked then. Not sure if it still works or may have been updated since.

http://xdaforums.com/apps/magisk/ma...ndroid-pay-t3435921/post68584855#post68584855
[Nexus 6 Q&A, Help & Troubleshooting] Seanbest:
Never done that. Got some instructions?
[Nexus 6 Q&A, Help & Troubleshooting] ScottIsMyName:
Install supersu in TWRP, then go to advanced and choose to copy log. The log will be saved to your sd card under the filename recovery.log
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Looking at the description of what this does, I don't think this is relevant to the problems with Android Pay people (like me) are currently reporting here. This Tasker profile seems mainly to hide Magisk root. However, Android Pay won't work at all with Magisk installed these days. In order to fix transient problems with Android Pay, it seems like you have to force Android Pay to check Safetynet again after using Root Switch to hide root (some have suggested that trying to add a card will do the trick). I don't think this profile does that.
[Nexus 6 Q&A, Help & Troubleshooting] MrBrady:
I believe the Tasker script was created so you don't have to go through the "add a card" work around. I'll have to dig through that other thread and do some reading.
[Nexus 6 Q&A, Help & Troubleshooting] sgloki77:
this worked, another thing is rootswitch won't stick after a reboot, if you have root off it will turn on on its own on reboot
[Nexus 6 Q&A, Help & Troubleshooting] mobileman88:
No sense having root if it is always off. It'd block apps like Greenify, EXKM, Titanium Backup etc.
[Nexus 6 Q&A, Help & Troubleshooting] humulos:
I can confirm that this worked for me asl well, I didn't even have to successfully add it, just had to attempt to.
[Nexus 6 Q&A, Help & Troubleshooting] kidhudi:
does this work with 7.1 roms? i tried it on nitrogen but no luck
[Nexus 6 Q&A, Help & Troubleshooting] photolarry:
This is now failing with dreaded unable verify message. I'm just getting really annoyed with Google. I pass safety net but when I tap to pay I get that horrible message and have to look at the cashier like I'm not a criminal.

---------- Post added at 01:26 AM ---------- Previous post was at 01:23 AM ----------

No it doesn't. This was confirmed few days ago
[Nexus 6 Q&A, Help & Troubleshooting] JonesL:
Made a payment, so it's still working.
[Nexus 6 Q&A, Help & Troubleshooting] ssojyeti2:
thank you so much for this post, I'm able to use snapchat again :D
[Nexus 6 Q&A, Help & Troubleshooting] Desinternauta:
Thank you very much for this post sir.

I just tested on my Moto X Play running CM13 and it worked.
[Nexus 6 Q&A, Help & Troubleshooting] MrBrady:
Oh interesting. It actually works on CM? I have never seen CM pass SafetyNet previously.
[Nexus 6 Q&A, Help & Troubleshooting] Desinternauta:
Yeah, it`s working! :D

I had to add a small step though, I deleted su from "/system/bin" and "/system/xbin" before starting flashing supersu and suhide. Otherwise suhide would fail to install. Everything else was exactly the same.
[Nexus 6 Q&A, Help & Troubleshooting] MrBrady:
Thanks. I'm currently running AICP which is CM based. But it's Android 7.1 so I think that will automatically fail SafetyNet.

Good to know it's working on CM though.
[Nexus 6 Q&A, Help & Troubleshooting] akenis:
Nexus 6 P working again:

Removed Magisk and PPH.

Flash:

SR3 systemless

Suhide 55

Latest rootswitch

This is on a 7.0 Pure Nexus ROM with Elemental kernel which hides bootloader status.
[Nexus 6 Q&A, Help & Troubleshooting] avruma:
I'm running stock Rom Android 7.0 and get the same error of unable to verify device is compatible with Android Pay...is that due to an unlocked bootloader? The option is greyed out so I don't even know if I'm locked or not. TIA
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
You can tell if your bootloader is unlocked by booting to the bootloader (turn off phone, then press power button while pressing and holding volume-down). It will tell you whether it's locked or not.
[Nexus 6 Q&A, Help & Troubleshooting] Ahowe125:
Hello guys, Verzion HTC 10 on Viper/ElementalX here. Followed instructions and got Success on the first two in SafetyNet Helper, but CTS Profile Match: False. Is this where people are having issues because of the whole bootloader thing? Or is there something else I missed or need to do?
[Nexus 6 Q&A, Help & Troubleshooting] avruma:
Thanx...I did that and I see that I'm unlocked. Is there a way to lock it?
[Nexus 6 Q&A, Help & Troubleshooting] NYZack:
Not without wiping your phone. The OP of this thread tells you how to hide the locked status. That's what this is all about.