[OEM] Go back to LOCKED Bootloader (LG G4 - All variants)

Status
Not open for further replies.

xVANKO

Member
Nov 25, 2016
35
197
0
Poznan
Temporarily Locked - until I prepare complete method​

!!! WARNING !!!
This method is currently in testing
Do this at your own risk! I'm not responsible for bricks.
Read and follow this steps correctly!

Description:
Regarding OllieD thread (available in Credits) he found that bootloader have several references in persistent partition which was correct. I was trying to continue his research and I found that before unlock and after unlock some partitions not included in KDZ files are modificated by unlock.bin key.

This partitions are: cust, drm, misc, modemst1, modemst2, mpt, persistent and sns. I knew that drm, modemst1, modemst2, mpt and sns partitions cannot be important in unlocking / locking process so I was able to check 3 partitions which was CUST, MISC and PERSISTENT.

This first contains informations about whole boot process like boot image, boot procedure and also information about bootloader state which is visible on the top of the screen while bootloader is unlocked.

Second partition is the most important - it contains DEVICE-ID needed to unlock device and real bootloader state which can be check using "fastboot getvar unlocked" and also used unlock.bin when bootloader is unlocked. There are some references between this partitions which check them both so this partitions MUST be flashed together.

Persistent partition contains procedure for unlocking bootloader (parse command to flash unlock.bin) so we dont need to flash it - but if you want, you can ;)

Result of relock:
- "Bootloader Unlocked!" message disappear while booting. (CONFIRMED)
- "fastboot getvar unlocked" returns "no" (CONFIRMED)

Requirements:
- ADB and FASTBOOT
- ADB Driver installed
- LGUP (which can be downloaded from here)
- LG_ROOT (which can be downloaded from here)

After relock, you can use the same Unlock Key which was used to unlock bootloader for the first time (this one from official LG Bootloader Unlock Site)

INSTRUCTION:
IN PREPARATION...

Video (Prove - not instruction):
WARNING! DONT TRY METHOD SHOWED IN THIS VIDEO FOR THIS MOMENT !!!
COMMANDS USED IN THIS VIDEO ARE DEDICATED TO H815 EU VARIANT
IF YOU DONT HAVE THIS VARIANT, THIS COMMANDS CAN HARD-BRICK YOUR PHONE!!!


Credits:
- OllieD (for: Relocking Bootloader May Be Possible...)
- shakeyabooti (for: "LGUP - NEW!!! - INSTALL KDZ - MM or LP - FACTORY RESET/UPGRADE")
- thecubed (for: "[ROOT] TMO/VZW/ATT/SPRINT/INTL Root your LG G4 with Low Effort Root!")
- Unjustified Dev (for: "[GUIDE] New Root Method for LG Devices")
- dominik-p (for: "[How to] Determine dd Parameters For All LG G4 Models")
- leptdre (for: "Unbrick LG G4 H815 9008 Qualcomm")
 
Last edited:

polfrank

Senior Member
Jul 5, 2012
697
313
93
Göteborg
Uhmm.... Does this mean that... if we get the bootloop issue.... we will be able to relock and send back to LG for warranty purposes???!?!? :D

(I mean, if it's really shown as locked in every possible aspect, after relocking...)
 

xVANKO

Member
Nov 25, 2016
35
197
0
Poznan
Uhmm.... Does this mean that... if we get the bootloop issue.... we will be able to relock and send back to LG for warranty purposes???!?!? :D

(I mean, if it's really shown as locked in every possible aspect, after relocking...)
Yes, but you don't need to.
I had bootloader unlocked, and LG repaired it under warranty ;)
Just place LG G4 motherboard to your cooker, 200 celsius degrees for 10 minutes and device is broken forever without any traces - send it to them, tell "i dont know what's happened - just bootlooped and now died" - and voilÃ*. They replaced motherboard and after 2-3 days, i got my LG working without any bootloop (and with locked bootloader). And of course for free :highfive:

So, I've just extracted all partitions "BEFORE" unlocking bootloader, then i unlocked it, again extracted all partitions to make a HEX compare, and that's it - just flash important (2 or 3) partitions from state BEFORE bootloader was unlocked and wow - relocked, unlocked, again relocked, unlocked - no crash, no brick, working as hell.

And as I wrote:
Result of relock:
- "Bootloader Unlocked!" message disappear while booting. (CONFIRMED)
- "fastboot getvar unlocked" returns "no" (CONFIRMED)
- [I need to find is there any other method to check, is bootloader locked or not - IF YOU KNOW ANY OTHER METHOD TO CHECK BOOTLOADER STATE PLEASE WRITE IT IN COMMENT OR SEND ME VIA PM]
There is no information while booting about unlocked bootloader, and also fastboot command "getvar unlocked" returns "no" - so official command to check bootloader state returns that bootloader is locked. I don't know is there any other method of checking bootloader state but it seems to be fully locked.

The biggest problem for me is 1 of this important partitions - becouse, what if this partition contains DEVICE-ID needed to unlock bootloader. If you relock it using my method, probably your phone will get DEVICE-ID of my phone - which can be easly detected by LG Support. I need to check some things before I make this release.
 
Last edited:

ObiDanKenobi

Senior Member
Dec 15, 2011
328
100
0
Cluj
Well, one option would be to create a script for those that did not unlock yet, so they save the 3 partitions and then they can happily unlock, knowing that they can relock. What do you say about this as a partial solution, if some device dependent information is stored in those partitions.?
 
  • Like
Reactions: Peshyy and polfrank

xVANKO

Member
Nov 25, 2016
35
197
0
Poznan
Well, one option would be to create a script for those that did not unlock yet, so they save the 3 partitions and then they can happily unlock, knowing that they can relock. What do you say about this as a partial solution, if some device dependent information is stored in those partitions.?
First partition store data which customize boot screen (like boot logo, information about bootloader lock state, etc). Second partition store bootloader extra configuration like used unlock key, real unlock state. Third partition is unknown for me at this moment. For sure, people with locked bootloader will have the most secure way to relock it after unlock - just using their own partitions dump - not shared and published for all. If second partition does not contain informations about DEVICE_ID, there wiil be only one simply method to relock bootloader again.
 

petro_ionut

Senior Member
Jul 4, 2010
98
9
0
Locked bootloader for 1,5 years, so this will be huge for me, finally unlocking the bootloader and back again in case of something happens! Great....

Sent from my LG-H815 using Tapatalk
 

Minto107

Senior Member
Aug 10, 2013
3,934
1,383
253
20
Oh man! If you'll do that and it'll be working 100% I will try to donate to you for that! I wanted to unlock my bootloader but I was always worried about some problems that I might get

Wysłane z mojego LG-H815 przy użyciu Tapatalka
 

ObiDanKenobi

Senior Member
Dec 15, 2011
328
100
0
Cluj
All the people are worried about warranty in case of a bootloop. How would you revert the 3 partitions content when the phone is bootlooping and you have access only to send_command.exe?
 

undef1ned

Member
Jul 11, 2013
18
4
0
Lviv
Oh, while my G4 is still in the owen now, I'm reading this thread :) H815 506 bootlooped this April. Warranty repair rejected. Worked with big-core disable tool for 6 months, until it finally died today.
Ok, if it is not finally dead after baking in the owen, then I will try to lock again and give it to the repair
 

Minto107

Senior Member
Aug 10, 2013
3,934
1,383
253
20
Now I'm just waiting for proper LG G5 Port until Nougat is released [emoji14]

Wysłane z mojego LG-H815 przy użyciu Tapatalka
 

polfrank

Senior Member
Jul 5, 2012
697
313
93
Göteborg
All the people are worried about warranty in case of a bootloop. How would you revert the 3 partitions content when the phone is bootlooping and you have access only to send_command.exe?
Maybe you can flash the kdz that disables the big cores and then you have a properly working phone, where you can do anything you like, such as relocking the bootloader...
 

xVANKO

Member
Nov 25, 2016
35
197
0
Poznan
All the people are worried about warranty in case of a bootloop. How would you revert the 3 partitions content when the phone is bootlooping and you have access only to send_command.exe?
You can import partition files to sdcard and flash it via send_command - and bootloader will be locked.

Oh, while my G4 is still in the owen now, I'm reading this thread :) H815 506 bootlooped this April. Warranty repair rejected. Worked with big-core disable tool for 6 months, until it finally died today.
Ok, if it is not finally dead after baking in the owen, then I will try to lock again and give it to the repair
As I wrote, I had bootloader UNLOCKED and i LG repaired my phone under warranty - i just destroyed it completly in the cooker and sent it to them just telling "i dont know whats happen, just bootloped and now died" - they wouldnt able to check bootloader state so ... >:D
 

undef1ned

Member
Jul 11, 2013
18
4
0
Lviv
As I wrote, I had bootloader UNLOCKED and i LG repaired my phone under warranty - i just destroyed it completly in the cooker and sent it to them just telling "i dont know whats happen, just bootloped and now died" - they wouldnt able to check bootloader state so ... >:D
I've bought mine in Poland. Unfortunately sent to repair with "Bootloader Unlocked" message on, just read several forums (including forum.android.com.pl) and some ppl shared positive experience of the unlocked phone to be fixed. Not sure if I can apply for the second time, may-be they've marked it as an unlocked somewhere in the database. Anyway I need to cross the UA/PL border twice to do it.

After baking method, my phone is on, but switching 4 small CPUs on - makes it supper laggy & unresponsive, however it does not go into bootloop mode

When are you going to post instructions?
 

xVANKO

Member
Nov 25, 2016
35
197
0
Poznan
Now I'm just waiting for proper LG G5 Port until Nougat is released [emoji14]

Wysłane z mojego LG-H815 przy użyciu Tapatalka
Relock will work also for LG G5 - this is the same security level and the same procedure ;)

I've bought mine in Poland. Unfortunately sent to repair with "Bootloader Unlocked" message on, just read several forums (including forum.android.com.pl) and some ppl shared positive experience of the unlocked phone to be fixed. Not sure if I can apply for the second time, may-be they've marked it as an unlocked somewhere in the database. Anyway I need to cross the UA/PL border twice to do it.

After baking method, my phone is on, but switching 4 small CPUs on - makes it supper laggy & unresponsive, however it does not go into bootloop mode

When are you going to post instructions?
Tomorrow i will post video showing this method, instruction will be on Monday or Tuesday
 
Last edited:

xVANKO

Member
Nov 25, 2016
35
197
0
Poznan
Does that mean that there is a chance for an unofficial unlock in the near future? for those without EUR devices?
Yes, there is a big chance to unlock non-euro devices. Probably if you flash prepared by me dumps I can transorm any LG variant to EURO variant - of course with possibility to go back to stock.

Just uploaded video to main thread.
 
Last edited:
  • Like
Reactions: Ofelipe and onotor
Status
Not open for further replies.