Possible to Relock Bootloader w/o Wipe?

kendoori

Senior Member
Mar 23, 2010
140
10
0
I have Lineage OS 14.1 on my phone and need to use Duo Mobile for 2 factor authentication. In spite of the fact that I have "unrooted" the system is still detecting that I a have tampered with my device. I will assume it's because the bootloader is unlocked.

I really, really don't want to wipe the phone and reconfigure all my apps (yes, it's easier than it used to be). Getting into fastboot and doing the fast relock commands is pretty clear to me, but how to get my device back to exactly where it is, but just with the bootloader locked?
 

Choose an username...

Senior Member
Oct 16, 2016
2,677
923
163
I have Lineage OS 14.1 on my phone and need to use Duo Mobile for 2 factor authentication. In spite of the fact that I have "unrooted" the system is still detecting that I a have tampered with my device. I will assume it's because the bootloader is unlocked.

I really, really don't want to wipe the phone and reconfigure all my apps (yes, it's easier than it used to be). Getting into fastboot and doing the fast relock commands is pretty clear to me, but how to get my device back to exactly where it is, but just with the bootloader locked?
You can't relock unless you are fully stock (actually you can, but you'll have a brick for life)
 

runninghamster

Senior Member
Dec 30, 2017
406
334
73
Melbourne
I have the a2017 model. Can I flash G or U stock firmware keeping the Chinese firmware modem and relock the bootloader. Do you know whether this is possible or would work without bricking.
To relock the bootloader you will need fastboot. None of the newer stock firmwares have fastboot asides from Chinese B19. You will need to EDL Flash B19 and use the Axon 7 Tool to relock the bootloader. After that, you can flash any Axon 7 firmware you'd like. Any A7 firmware works on any A7 model.

Make sure to replace the NONHLOS.bin in the files of the EDL package with the NONHLOS.bin from the Chinese firmware. This file is the modem, and so if you live in China, you will need to replace the US/EU modem file inside the package with the Chinese one.

It won't brick your phone, but it's not possible to relock the bootloader without wiping. I'd suggest a backup app such as Titanium Backup or something else (not too sure about non-root backup apps).
 

FuzzyDunlop9

Senior Member
Dec 4, 2016
51
4
0
To relock the bootloader you will need fastboot. None of the newer stock firmwares have fastboot asides from Chinese B19. You will need to EDL Flash B19 and use the Axon 7 Tool to relock the bootloader. After that, you can flash any Axon 7 firmware you'd like. Any A7 firmware works on any A7 model.

Make sure to replace the NONHLOS.bin in the files of the EDL package with the NONHLOS.bin from the Chinese firmware. This file is the modem, and so if you live in China, you will need to replace the US/EU modem file inside the package with the Chinese one.

It won't brick your phone, but it's not possible to relock the bootloader without wiping. I'd suggest a backup app such as Titanium Backup or something else (not too sure about non-root backup apps).
Thanks for replying. So I flashed the A2017_B15_FULL_EDL Android: 6.0.1 onto my a2017 axon 7. I replaced the NONHLOS.bin (modem) in the edl file with the Chinese modem which I took from A2017_B15_FULL_EDL Android: 6.0.1. I'm able to get network signal and works as expected.
I can't seem to lock the bootloader. Fastboot works on this firmware but the fastboot oem lock command does nothing, I keep getting failed.

Are you suggesting I flash stock firmware, one that has fastboot commands working, designed for a2017, lock the bootloader and then using a tool like djkuz Axon 7 EDL Tool flash a2017g firmware.
The reason why I need a2017g firmware is I'm tryna sell my axon at CEX and they won't accept it cos it has Chinese software. If it has European firmware with locked bootloader it'll pass their software check.
 

runninghamster

Senior Member
Dec 30, 2017
406
334
73
Melbourne
Thanks for replying. So I flashed the A2017_B15_FULL_EDL Android: 6.0.1 onto my a2017 axon 7. I replaced the NONHLOS.bin (modem) in the edl file with the Chinese modem which I took from A2017_B15_FULL_EDL Android: 6.0.1. I'm able to get network signal and works as expected.
I can't seem to lock the bootloader. Fastboot works on this firmware but the fastboot oem lock command does nothing, I keep getting failed.

Are you suggesting I flash stock firmware, one that has fastboot commands working, designed for a2017, lock the bootloader and then using a tool like djkuz Axon 7 EDL Tool flash a2017g firmware.
The reason why I need a2017g firmware is I'm tryna sell my axon at CEX and they won't accept it cos it has Chinese software. If it has European firmware with locked bootloader it'll pass their software check.
Yeah, that's basically it.