[Nexus 6P General] HaXoReD:
Confirmed issue with nandroids made while under lockscreen protection

First off, thanks for the awesome guide Heisenberg!

I read the above advice in the first post, so I decided to test this. I set up password protection in my 6p, rebooted and verified that it asked me for the password in order to boot back into my phone, entered it, and after booting back into phone, I booted into twrp, entered my same password into twrp (it asks for this in order to decrypt data partition). Once in twrp, I made a nandroid backup, I then wiped everything except internal data.

The first nandroid I tried to restore was the one I made when I first got the phone (before I rooted it with supersu 2.62 systemless method). This original nandroid was one I made with no lockscreen secrurity present. It consisted of: boot, system, vendor image, data, recovery & efs. Upon restoring this nandroid, I tried rebooting into the system and first noticed, in addition to the orange bootloader message i'm used to seeing warning the bootloader is unlocked, I also get the red warning message saying bootloader is corrupted. At that point it just hangs at the google emblem with little unlocked padlock icon at bottom and doesn't go any further.

At this point, I booted back into twrp, entered the decryption password and wiped everything but internal data and, from the same nandroid as described above, restored vendor image, recovery & efs. I then restored boot, system & data from my most recent nandroid made at the beginning of this test (made while under lockscreen security). I rebooted into system and booted just fine. I'm back to the normal orange bootloader warning, still rooted and after entering my decryption password, booted just fine into my 6p.

Edit: I just tried to duplicate this and for some bizarre reason it didn't work for me this time. After entering the correct password numerous times at the lockscreen password prompt after booting into the system (after already entering the password successfully at the decryption prompt during boot), I am unable to get past this lockscreen password prompt. At this point it is safe to say what was said in original post regarding turning lockscreen protection off while making nandroids is good advice.

I can also confirm that Heisenberg's recommendation of deleting /data/sytem/locksettings.db does solve this problem. I did this in TWRP's file manager and was then able to boot straight into the 6p (after entering the decrypt password during bootup of course).

I now wanted to know if I could get that original nandroid to restore (the one I made when I first got my phone, before rooting with 2.62 supersu systemless root) if I went in and removed lockscreen protection. After removing lockscreen protection, i rebooted to verify no password was asked to get back into my 6p. I then booted to twrp, wiped everything except internal storage and restored boot,system & data and tried booting into my 6p. Again, just as before I got a red 'bootloader corrupt' message and it sat at the google screen with unlocked padlock icon at bottom without booting into the system.

At this point, i'm thinking that the reason I can't restore my original nandroid (the one I made when I first got my phone, before rooting with 2.62 supersu systemless root) is because the supersu 2.62 systemless root method patched something in the bootloader image that is not being un-done when restoring my original nandroid.

Thankfully, I have one other nandroid I happened to have made yesterday which is virtually identical to the one I just made today- with one difference- it was made with no lockscreen protection present. With all lockscreen protection removed, I booted into twrp, wiped everything except internal data and restored this nandroid. I was able to successfully reboot into system.

TLDR

Three things found out here:

1) If you would like to successfully restore any nandroid you create with TWRP while lockscreen protection is active on your 6p (also probably 5x for that matter), you will also at that time of restore need to have lockscreen protection active. (i'm assuming with the same password or pin that you originally made the nandroid under, but I could be wrong here) Edit: You will have to use TWRP's file manager to delete /data/sytem/locksettings.db in order to get past the lockscreen in your restored nandroid.

2) Likewise, to successfully restore any nandroid made with TWRP while not having lockscreen protection active, you would need to deactivate any form of lockscreen protection while restoring the nandroid. Edit: I've found this isn't the case, you can restore this without lockscreen issues. If for any reason you have an issue, just delete /data/sytem/locksettings.db and you will be fine.

3) To successfully restore a nandroid that was made before rooting with the supersu 2.60+ systemless method, you most likely will need to reflash the factory bootloader.

Hope this helps someone out there and also let me know if I got anything wrong with these deductions. :fingers-crossed: