Questions regarding bootloader relock - Xperia Z2 Q&A, Help & Troubleshooting

So, I had my bootloader unlocked back when I was in kitkat (unsure whether I had version 4.4.2 or 4.4.4), but I had backed up my ta partition in case I wanted to relock the bootloader.
Fast forward to today, I am on lollipop (version 5.1.1) and I want to relock my bootloader. Note that I am on stock kernel.
Obviously enough, I have to restore my ta backup.
But I have some questions.
1)Do I have to downgrade to the android version the phone had when I took the ta backup, or I can simply flash the ta backup on my current android version?
2)During this procedure, does anything (such as data) get wiped?
3) Will I lose recovery during this procedure?

Mokiwipeout said:
So, I had my bootloader unlocked back when I was in kitkat (unsure whether I had version 4.4.2 or 4.4.4), but I had backed up my ta partition in case I wanted to relock the bootloader.
Fast forward to today, I am on lollipop (version 5.1.1) and I want to relock my bootloader. Note that I am on stock kernel.
Obviously enough, I have to restore my ta backup.
But I have some questions.
1)Do I have to downgrade to the android version the phone had when I took the ta backup, or I can simply flash the ta backup on my current android version?
2)During this procedure, does anything (such as data) get wiped?
3) Will I lose recovery during this procedure?
Click to expand...
Click to collapse
1. no
2. shouldent be
3. if you are using recovery for locked bootloader then no

Related

[Q] Relock bootloader and go stock

I already unlock boatloader. Can I go back to stock rom and relock my bootloader, flash back my TA backup and recieve OTA updates in future? Any guides on that pleaese? Thanks in advance...
dralex88 said:
I already unlock boatloader. Can I go back to stock rom and relock my bootloader, flash back my TA backup and recieve OTA updates in future? Any guides on that pleaese? Thanks in advance...
Click to expand...
Click to collapse
Yes. Flash stock ftf first then relock bootloader. If you try to relock bootloader on custom rom it won't boot.
Sent from my C6833 using XDA Premium 4 mobile app
Yup, be sure to be on a stock ROM before you do it, and remember that you have to have root to restore TA. The standalone TA tool (from the cross dev section) restores and locks the bootloader, so no need to do it again in Flashtool after you've restored TA.
Worst case scenario: You restore TA and lock the bootloader and the device won't turn on, and all you get is a simple vibration and a blinking red light. Open Flashtool and unlock the bootloader again. This will happen if you're not on stock kernel (i.e you have recovery), so be sure to be on stock ROM w/ stock kernel.

[Q] Bootloader unlock required for TWRP flash?

Hi guys,
So I have an Xperia Z2 running the rooted stock 4.4.4 firmware. I just did a Nandroid backup and am feeling adventurous. My bootloader is locked, as it's possible to root the Z2 without unlocking it. I found out about the CM12 nightly 5.0 ROM and was wondering, if I flash that through TWRP (which I currently have installed), do I have to unlock my bootloader? Or do I not since I'm already this far in without unlocking it? And I'm correct to assume if I restore my Nandroid backup that restores my old ROM right?

some flashing questions

I have some questions regarding flashing new firmwares on the phone.
Currently I have firmware version 23.0.1.A.0.167, if I downgrade to 17.1.A.2.69 firmware using Flashtool, do I exclude the TA partition from being flashed? If I don't exclude the TA partition while downgrading will it wipe my DRM keys?
If I install custom recovery, will I still be able to receive OTA updates or updates via PC Companion? If I do receive them will they install successfully?
If I downgrade, root, install custom recovery and flash back to the 4.4.4 firmware, when 5.0x firmware is released, will I be able to install that without losing my data and root? Or will I be able to keep both?
The general steps to gaining root on the Z2 now with .167 firmware is to downgrade to .69 (exclude TA partition), run towelroot/easy root, install custom recovery, flash pre-rooted .167 (exclude TA again). Will I have to repeat them for 5.0 update? Does root persist between firmware updates?
If anyone can confirm my thoughts it would be great. Thank you guys!
chaose said:
I have some questions regarding flashing new firmwares on the phone.
Currently I have firmware version 23.0.1.A.0.167, if I downgrade to 17.1.A.2.69 firmware using Flashtool, do I exclude the TA partition from being flashed? If I don't exclude the TA partition while downgrading will it wipe my DRM keys?
If I install custom recovery, will I still be able to receive OTA updates or updates via PC Companion? If I do receive them will they install successfully?
If I downgrade, root, install custom recovery and flash back to the 4.4.4 firmware, when 5.0x firmware is released, will I be able to install that without losing my data and root? Or will I be able to keep both?
The general steps to gaining root on the Z2 now with .167 firmware is to downgrade to .69 (exclude TA partition), run towelroot/easy root, install custom recovery, flash pre-rooted .167 (exclude TA again). Will I have to repeat them for 5.0 update? Does root persist between firmware updates?
If anyone can confirm my thoughts it would be great. Thank you guys!
Click to expand...
Click to collapse
flashing TA with a FTF doesnt wipe your DRM keys
recovery i dont know if OTA verifies the fotakernel partition
it will fail anyways if you have a custom kernel or modified system
you cant update if your bootloader is unlocked but relocked you can for some reason regardless of if you restored your TA backup
you wont be able to upgrade without losing root because after upgrading you will have to reroot
downgrade to 314 or before, root, backup your DRM keys, do what you want
you dont have to keep updating your drm keys because they never change
got it. thanks !!
For downgrading to 4.4.2, is it possible to do it without an wipe of the apps and data?
Which partitions should I exclude when downgrading to 4.4.2?
Envious_Data said:
you wont be able to upgrade without losing root because after upgrading you will have to reroot
Click to expand...
Click to collapse
That really depends on how you want to upgrade, right?
The magical thing about the z2 is we'll always have root. once lollipop comes out we would just need to create a rooted flashable zip and flash in recovery.
o0 Matt 0o said:
That really depends on how you want to upgrade, right?
The magical thing about the z2 is we'll always have root. once lollipop comes out we would just need to create a rooted flashable zip and flash in recovery.
Click to expand...
Click to collapse
Yup
Im going to have my phone rooted nearly imediately after lolipop comes anyway

Relocking bootloader and restoring DRM keys

hey all,
I'm on 23.1.A.0.690 fw with UB at the moment, and I'm planning to restore my DRM key (which I have a backup of) and re-lock the bootloader.
But I was wondering about :
What comes first, the re-locking or restoring the DRM keys
Will the re-locking process wipe the internal SD
Can the the process be done while being on Lollipop fw or should I downgrade to Kitkat?
Any information or insight is highly appreciated.
Thanks.
Before restoring your DRM keys you should make sure that your Kernel and FOTAKernel are both stock (do this by flashing just them with flashtool).
To answer your first question, when you restore the DRM keys it relocks the bootloader (which is why you must make sure your kernel and FOTAkernel are both stock).
The relocking process doesn't wipe the internal SD card.
DRM keys appear to be the same for your device across all firmwares. I have restored DRM keys taken from KitKat and restored them on LP with no problems.

A way to have root on MM with locked bootloader (TA partition intact) (Test Please?)

A few days ago this was released: Universal TA partition backup
This means that we can retrieve the TA partition with a LOCKED bootloader!
In theory, then we can save the TA partition, root the M4 after UNLOCKING the bootloader, and then relock it by flashing the TA partition back.
If you were wondering about DM-verity, the M4 doesn't enforce that.
Someone confirm this?
Is no one seriously going to try this out? Fine I'll try it in my own time...
I tried it last week and it doesn't work, the backup file was 0bytes. Anyway you can make a TA backup using TA backup master with downgrading to Lollipop, root using the known exploit and then unlock the bootloader.
To root on MM you have to flash boot image, which requires unlocked BL and re-locking after that will result a boot-loop.
Check out the new version. It works now. TA Dumped ^^
The main problem is still there, flashing SuperSU from twrp doesn't work, so no way for re-locking the BL with root after that.

Categories

Resources