(Un)lock bootloader using Boot Unlocker - YotaPhone

Good news everyone!
I've added the capability to unlock and lock the bootloader of the Yota Phone 2 to @segv11 's Boot Unlocker. There is already a pull request on GitHub for my code.
This means that everyone can now safely use custom recoveries without having to worry about warranty issues or losing data because of the mandatory factory reset.
Technical information
On the Yota Phone 2, the bootloader uses position `0x004FFE10` of the "aboot" partition, stored as `00` / `01` to indicate lock status, whereby `01` stands for "unlocked".
Download
For those eager to try it, until the pull request is merged, you can download the app from my GitHub repository. Please note that it is signed with my own developer key, so you will have to manually uninstall the official Google Play version from your device before installing it.

wow great just what i wanted :good::laugh:

Did you come to try it yet? I'd love to hear whether it works for other users.

For me (running android 6 beta) the app is not compatible with my device. (NOT WORKING ON DEVICE WAS THE VERSION FROM GOOGLE PLAY STORE)
I am using a yotaphone 2.
L.E.
could anyone confirm this app can relock the bootloader if root access is available? I have not yet rooted it yet.
I am asking this because we will need a locked bootloader to install google pay.

Did you try to install my version over the official Play Store version? This doesn't work, as the APK is signed with a different key. You have to uninstall the official version first.
Regarding a relock confirmation: I didn't try tools like SafetyNet, but when you relock the bootloader using Boot Unlocker, the bootloader command fastboot oem unlock again offers to unlock the device.
Unfortunately, I can't investigate much further currently, as I have installed Magisk, which needs a permanently unlocked device.

I testet the github version. The attempt to relock the bootloader on a unlocked Yotaphone2 on Android 6.0 ends in a boot loop

In my experience, the boot loop occurs when the boot partition is modified (e.g. after installing Magisk). If you flash the original boot partition (and potentially also recovery), the phone should be able to start just fine.

Different way?
Great job! Is any solution to unlock bootloader via fastboot mode like flashing modified aboot partition image? On my YD201 MM after turn off Extreme Power Saving Mode my lock pattern had been changed itself and i don't want to wipe data by fastboot oem unlock.

Related

Unable to Unlock OEM

1-I Installed TWRP
2- I installed custom ROM CM 13
3-I need to update my custom ROM so i entered fastboot i found that OEM is disabled so i have to reboot to enable OEM unlocking
4-something happens so that i can't reboot to normal OS as power button doesn't make any response, i can only start fastboot using power and volume up, power and volume down doesn't make any response.
so the question is i need a way to install any thing that make my phone boot to OS regardless any thing (Formating ,.....)
Noting that:-
1-I can't use any (flash,erase,format,...) as OEM is locked.
2-I can't unlock OEM as it is disabled.
3-flashboot continue result device shutdown.
4-I am in a country that doesn't any support to oneplus devices.
Thanks in advance
How can you have a locked bootloader if you've already flashed a custom ROM? I'm not sure I understand what's going on - if you're able to boot into Android, there should be an option in the Developer Options menu to allow OEM unlocking. Again, I'm not sure if I understand what's going on but if you're able to access the bootloader (fastboot) you can flash the stock ROM found here: http://downloads.oneplus.net/2016-02-26/op2/OnePlus_2_OxygenOS_2.2.1/
I hope this helps!
Five cents he upgrade to OOS3 or MM H2OS with newer bootloader and failed to upgrade TWRP to compatible one with the bootloader, just like other thread 99% similar to this one, that I already answered to.
pitrus- said:
Five cents he upgrade to OOS3 or MM H2OS with newer bootloader and failed to upgrade TWRP to compatible one with the bootloader, just like other thread 99% similar to this one, that I already answered to.
Click to expand...
Click to collapse
Could you please provide link for any or post the solution.

Can't unlock bootloader, can't finish OS setup

So I upgraded to Nougat on my P9 Lite, unlocked boot loader, used twrp, flashed roms and everything went smooth. Saw a more up-to-date version with no bugs, so I had to downgrade to MM first.
I followed a guide, but I messed up somewhere and ended up having my bootloader locked, and I can't access the OS to enable developer options and oem unlock from settings. The reason why I can't access the OS is that I am stuck in the setup. I am stuck at the part where I have to sign in to my google account. It doesn't show a keyboard, only a microphone, and I can't use that for my password (it won't let me).
Any ideas?
TL;DR messed up during downgrading from Nougat to MM, now TWLR is gone, bootloader is locked and my main issue is that when I get to the google account sign in part during OS setup, there is no keyboard (I can only use dictation) so I can't sign in... So I'm stuck
Also, can I unlock bootloader without access to OS, without being able to navigate to settings, enable developer options and then oem unlock?
1. Stuck in OS setup? Signing in to Google? Hey, it's not obligatory, can't you just skip it?
2. Flashing ROMS locked your bootloader, it's normal, but I'm sure it didn't change the "oem unlock" setting you had surely enabled before. Go to fastboot mode and check Bootloader and FRP status on the bottom of the screen. If FRP is unlocked, you will be able to unlock bootloader again.
3. If you have your TWRP gone (flashed by stock ROM), flash the recovery partition manually - fastboot flash recovery TWRP.img (download from Meticulus Project site).
Jagiel88 said:
1. Stuck in OS setup? Signing in to Google? Hey, it's not obligatory, can't you just skip it?
2. Flashing ROMS locked your bootloader, it's normal, but I'm sure it didn't change the "oem unlock" setting you had surely enabled before. Go to fastboot mode and check Bootloader and FRP status on the bottom of the screen. If FRP is unlocked, you will be able to unlock bootloader again.
3. If you have your TWRP gone (flashed by stock ROM), flash the recovery partition manually - fastboot flash recovery TWRP.img (download from Meticulus Project site).
Click to expand...
Click to collapse
It is obligatory, I couldn't skip it. I tried to use other methods of signing in, but then it asked me to reset password at the end.
Both Phone and FRP are locked
I think I have missed this, but I can't do it via fastboot because I keep getting "Command not allowed" whenever I try to unlock bootloader or do anything via fast boot.
Also, thank you so much for your time and input. It is much appreciated.
That's weird, I flashed my phone several times with different ROMS (not Nougat) and this setting (oem unlock / FRP unlocked) stayed enabled. Don't know where it sits then and how to change it without getting inside OS. But - what about TWRP? Oh right, you won't be able to flash it without unlocked bootloader... Oh, crap. I would try SRK Tool for Huawei to play with bootloader, it uses fastboot so shouldn't help, but maybe, just maybe? Maybe try flashing whole ROMs through dload folder on SD? Stock 120, 161, Nougat, I would try these. I hope there is some way to unlock FRP, probably it's possible in DC-unlocker (it's a paid software).
Jagiel88 said:
That's weird, I flashed my phone several times with different ROMS (not Nougat) and this setting (oem unlock / FRP unlocked) stayed enabled. Don't know where it sits then and how to change it without getting inside OS. But - what about TWRP? Oh right, you won't be able to flash it without unlocked bootloader... Oh, crap. I would try SRK Tool for Huawei to play with bootloader, it uses fastboot so shouldn't help, but maybe, just maybe? Maybe try flashing whole ROMs through dload folder on SD? Stock 120, 161, Nougat, I would try these. I hope there is some way to unlock FRP, probably it's possible in DC-unlocker (it's a paid software).
Click to expand...
Click to collapse
Yes, it's very weird. I haven't done the process a lot. But I've flashed a couple of phones I had before, went smooth. Nothing major like this happened before.
I will consider the SRK Tool and I did not know about the DC-Unlocker tool, thank you for telling me about it.
Flashing whole roms through dload folder only works with Nougat for some reason, and I keep getting stuck in the signing in problem because of no keyboard, someone told me that's incomplete software, I'm hoping that's the case, any ideas where can I get it from?
Again thank you Jagiel88 for your time and advice xD
No problem, unfortunately I haven't tried Nougat yet, so search for help on down/upgrade Nougat beta <-> Marshmallow threads .
youssefSamir said:
Yes, it's very weird. I haven't done the process a lot. But I've flashed a couple of phones I had before, went smooth. Nothing major like this happened before.
I will consider the SRK Tool and I did not know about the DC-Unlocker tool, thank you for telling me about it.
Flashing whole roms through dload folder only works with Nougat for some reason, and I keep getting stuck in the signing in problem because of no keyboard, someone told me that's incomplete software, I'm hoping that's the case, any ideas where can I get it from?
Again thank you Jagiel88 for your time and advice xD
Click to expand...
Click to collapse
Hi, have you found how to solve this? I can't access recovery because I messed up, cant flash recovery because bootloader locked. Cant unlock bootloader because says command not allowed... I did 3 times so the code is working... Any clue?
islandman75 said:
Hi, have you found how to solve this? I can't access recovery because I messed up, cant flash recovery because bootloader locked. Cant unlock bootloader because says command not allowed... I did 3 times so the code is working... Any clue?
Click to expand...
Click to collapse
There is 1 thing to unlock in settings . U have OEM lock
youssefSamir said:
Yes, it's very weird. I haven't done the process a lot. But I've flashed a couple of phones I had before, went smooth. Nothing major like this happened before.
I will consider the SRK Tool and I did not know about the DC-Unlocker tool, thank you for telling me about it.
Flashing whole roms through dload folder only works with Nougat for some reason, and I keep getting stuck in the signing in problem because of no keyboard, someone told me that's incomplete software, I'm hoping that's the case, any ideas where can I get it from?
Again thank you Jagiel88 for your time and advice xD
Click to expand...
Click to collapse
Hi, have you found how to solve this? I can't access recovery because I messed up, cant flash recovery because bootloader locked. Cant unlock bootloader because says command not allowed... I did 3 times so the code is working... Any clue?
---------- Post added at 04:19 PM ---------- Previous post was at 04:16 PM ----------
ScaleneVirus288 said:
There is 1 thing to unlock in settings . U have OEM lock
Click to expand...
Click to collapse
Can't access to any OS. I definetly know i had OEM unlocked, then after unlocking via fastboot, I wasn't able anymore to access the system.
islandman75 said:
Hi, have you found how to solve this? I can't access recovery because I messed up, cant flash recovery because bootloader locked. Cant unlock bootloader because says command not allowed... I did 3 times so the code is working... Any clue?
---------- Post added at 04:19 PM ---------- Previous post was at 04:16 PM ----------
Can't access to any OS. I definetly know i had OEM unlocked, then after unlocking via fastboot, I wasn't able anymore to access the system.
Click to expand...
Click to collapse
Unlock bootloader, after that you able to flash rom.
You use this command?
fastboot oem unlock YOUR_OEM_CODE
If you tip:
fastboot devices
What's you see?

I unlocked the Verizon bootloader for 8.1 dev preview pixel and pixel xl and pixel 2

Moderators could not provide any evidence
I believe this is why the bootloader is locked is my phone. The cid says it's a Verizon but it's also a project fi and carrier unlocked Google Pixel XL. Is there anyway to modify the boot image so it's RO.BOOT.FLASH.LOCKED=0 I believe that will unlock the bootloader if there was just a way to modify it so you could sideload the modified boot through stock kinda like how you could modify the boot images of Samsung devices and flash them in Odin through the stock bootloader. Any thoughts.
Who would be interested in trying this I modified the boot image in the ramdisk so you can turn oem unlock on and unlock the bootloader.. I didn't want to jump to link posting I wanna see who is interested. You have to sideload the boot image through the bootloader but it installs like it's official.. 32 gb pixel XL only this is the 8.1 dev preview boot image so you need to have 8.1 installed.
Links removed due to suspicious moderator activity and possible tampering with the links while they had them removed.
I really think a modified stock boot image which can be side loaded through the stock bootloader will solve the problem about the Verizon Google Pixel XL having a locked bootloader cause even if the bootloader is locked like it is now once you unlock it via a modified boot image it opens it up for flashing you wouldn't need some fancy tool which you'd have to run on a computer to unlock it or a oem unlock code you could modify the locked boot image to be the key into the bootloader.
What you thinking? You thinking support could be added for the Verizon Pixels once again I know there was development at one time but due to them patching the tool used to unlock the bootloader it stopped after a while well with this you could bring back development for it
We also wanted to make sure there was no central point of failure, where one industry player could restrict or control the innovations of any other. The result is a full, production-quality operating system for consumer products with source code open for customization and porting.
Google stated that on it's Android open source project right now with the locked bootloaders Verizon is basically restricting and controlling the innovations of how the device could be used and Google doesn't go with that that is why the Google store edition pixels are unlocked so I think setting the example that there's a permanent way to keep the Verizon bootloaders unlocked by modifying the boot images will show Verizon that they need to remove some policy's they have in place cause in the end as customers the old saying is the customer is always right.
Actually now that I think about it I can modify the ramdisk by unpacking the boot image and taking a text editer and going in then you can edit it to say 0 then repack it and flash it via side load i believe that's how you do it. I'm pretty sure I can do that. Doesn't seem too hard to do.
I am also seeing in the cid that there's RO.BOOT.OEM_UNLOCK_SUPPORT=0 it needs to be kept at RO.BOOT.OEM_UNLOCK_SUPPORT_0 I believe and the boot hardware is samsungs
This all started out as a question but I answered my own question. Plus it's nice to have a unlocked bootloader. Cheers.
Did anyone tried to unlock it ?
If you wanna see this cid information for yourself get the app called cid getter from the play store it doesn't have the best reviews but it at least gives you the right cid information and shows you how the bootloader was locked
user-67 said:
If you wanna see this cid information for yourself get the app called cid getter from the play store it doesn't have the best reviews but it at least gives you the right cid information and shows you how the bootloader was locked
Click to expand...
Click to collapse
did you start with an unlocked bootloader and were you also able to sideload the modified boot.img and then able to unlock the bootloader? also, is this on a VZW Pixel or XL?
user-67 said:
I really think a modified stock boot image which can be side loaded through the stock bootloader.....
Click to expand...
Click to collapse
You can't do that if the bootloader is locked.
Mod Message: OP could NOT provide photo/video evidence on it. Proceed at your own risk!
Click to expand...
Click to collapse
Who would be interested in trying this I modified the boot image in the ramdisk so you can turn oem unlock on and unlock the bootloader.. I didn't want to jump to link posting I wanna see who is interested. You have to sideload the boot image through the bootloader but it installs like it's official.. 32 gb pixel XL only this is the 8.1 dev preview boot image so you need to have 8.1 installed.
Never mind here's the link for pixel XL 8.1 dev preview https://drive.google.com/file/d/1ehXD2LVOBoRbs1EDh33nLyw7I0aRyOqH/view?usp=drivesdk
Here's the link for pixel 8.1 dev preview
https://drive.google.com/file/d/19xvVkadK79p6OLx5LePZSRA7V201ortd/view?usp=drivesdk
Here is the link for the pixel 2... 8.1 Dev preview
https://drive.google.com/file/d/1M-sgp33NTrrlS12SY0xLQxrec44ZejJl/view?usp=drivesdk
Bump
If you didn't know the part that controls oem unlocking is in the boot image. You can go crazy trying to break into the actual bootloader partition but you don't need all that.
I have a pixel (not xl) and i curious, if the bootloader is locked how can i sideload the boot.img?
Sideload is the install of a custom image what you have here is a modified custom boot image which install like it's stock so in terms sideload is what it is through the bootloader
When it comes to boot images I'm good at tweaking them here's a old project it was just a test build to see if it would actually work.
Custom adb root boot image with chainfires adbd kernel from adbd insecure as the phones adbd.. it has a few other tweaks and a custom permissive kernel and systemless root from chainfires supersu... the rsa fingerprint doesn't pop up when you connect a computer but it can be bypassed with adb in a custom recovery and found out if you use adbd insecure and let it patch chainfires adbd kernel it makes the phone as attached device in for adb devices instead of the plain unauthorized device and vendor keys not set. ... if you use it now you get adb root access and regular root access with the su binary but due to the rsa fingerprint not popping up you have to use adbd insecure until a recovery comes out cause it bypasses rsa fingerprint.. credits to come... to use adb root access you need a custom recovery with adb... adbd insecure app... adb on you're computer.... android sdk/android studio... java... boost mobile j7 running build f3 but you can just run systemless root until a recovery comes through. You can grab systemless root from here http://forum.xda-developers.com/gala...j700p-t3430185
And use it with the boot image.. but i just added systemless root patches to the boot image so all you have to do is flash the boot image.
user-67 said:
Who would be interested in trying this I modified the boot image in the ramdisk so you can turn oem unlock on and unlock the bootloader.. I didn't want to jump to link posting I wanna see who is interested. You have to sideload the boot image through the bootloader but it installs like it's official.. 32 gb pixel XL only this is the 8.1 dev preview boot image so you need to have 8.1 installed.
Nevermind here's the link https://drive.google.com/file/d/1ehXD2LVOBoRbs1EDh33nLyw7I0aRyOqH/view?usp=drivesdk
Click to expand...
Click to collapse
Will you be able to provide the boot image for Verizon pixel on 8.1? I would be interested in trying it. Thank you.
i definitely want to try this, i have the VZW Pixel, not upgraded to 8.1 yet, but will if this is made available for the pixel!
If you all give me a copy of your boot.img in Img format I'll do the ramdisk changes.. you can get a copy by downloading the factory image you want then on your phone go to the play store and get the app zarchiver then go in and open the factory image and copy the boot image into internal storage then hit the Google drive and post a link and I'll get right on it.

[RECOVERY] TWRP for Onn Android Tablets (unofficial) - 2019-11-30

TWRP Custom Recovery for the Onn Android Tablet series​
This is the first fully-featured custom recovery for Walmart's MediaTek-based Onn tablets: ONA19TB002, ONA19TB003 and ONA19TB007. TWRP needs no introduction. If you have come here, you probably have some idea of what it is and what it's used for. This TWRP build does not need the bootloader unlocked or VBMeta verification disabled, although it's recommended that you at least unlock the bootloader.
DISCLAIMER
Everything described in this thread is done at your own risk. No one else will be responsible for any data loss, corruption or damage of your device, including that which results from bugs in this software.
FEATURES
Decrypted data partition
All USB modes functional: MTP, ADB, Mass Storage, OTG, Charging
Fast boot time
Adoptable storage mounting
Firmware image backup and restore
Works under locked bootloader
Android 9 build fits within the 16MB recovery partition -- no compromises or partition resizing necessary
INSTALLATION METHOD 1
Download the recovery to your PC and unzip the image
Unlock the bootloader (skip if you have already done this)
Enable OEM Unlock in Developer Options in Android Settings
Boot into fastboot mode either by holding vol. up+power to power it on and selecting "Fastboot mode", or by running the 'adb reboot bootloader' command from within Android.
Install fastboot and appropriate drivers on your PC if you have not set those up
Unlock the bootloader with the command
Code:
fastboot flashing unlock
...and follow the instructions on the screen. This will wipe your data.
Flash the custom recovery with
Code:
fastboot flash recovery twrp-3.3.1-ONA19TB002.img
(use the right file name path for your device)
Reboot to recovery with
Code:
fastboot oem reboot-recovery
INSTALLATION METHOD 2
This assumes you are familiar with SP Flash Tool or can figure it out on your own
Download the recovery to your PC and unzip the image
Get the appropriate scatter file for your device. The scatter file may be found in the device's firmware under /system/data/misc.
Set up SPFT Download tab as Download Only. Load your scatter file.
Under the recovery line, double-click Location and open your TWRP image.
Click Download and connect your powered-off tablet to your PC. SPFT will automatically flash the recovery to the emmc and disconnect when finished.
INSTALLATION METHOD 3
Head over to Amazing Temp Root for MediaTek ARMv8, read the requirements and directions, and grab the latest mtk-su.
Open a root shell with mtk-su
Flash the (unzipped) recovery with the command:
Code:
dd bs=1048576 if=twrp-3.3.1-0-ONA19TB002.img of=/dev/block/by-name/recovery
(replace the if= file name with your appropriate recovery image path)
Exit root shell
START RECOVERY
Three methods:
On a powered off tablet, hold Vol. up+power for about 3 seconds. In the menu that appears, select "Recovery mode"
With Android ADB, use the command 'adb reboot recovery'
From Android root shell, use the command 'reboot recovery' or just use any root app with OS reboot features
NOTES
Kind of important: Make a backup of your Crypto Footer as soon as you can. This is the encryption key to your data partition. When accessed from TWRP, this key can get "upgraded" so that you will get locked out of Android. TWRP uses a hacky workaround that saves and restores the original footer on every /data decrypt. But that method is not what I would call 100% reliable.
Make sure you have a backup of the untouched stock system and vendor images. There are no official firmware packages available to download.
Only mount system/vendor partitions in read/write mode if you have unlocked the bootloader. It is recommended to choose to leave system read-only at the startup prompt unless you have a specific reason to modify it. If the bootloader is locked, then dm-verity is enforced.* So merely mounting it once in r/w will cause a boot loop.
It's currently not possible to install incremental OTA updates using this TWRP. Use the stock recovery to update the FW. That will only work if you have never mounted system/vendor in write mode.
DOWNLOAD (Nov. 30, 2019)
Current version: 3.3.1-1
ONA19TB002 - Onn 8" model
ONA19TB003 - Onn 10.1" model
ONA19TB007 - Onn 10.1" w/keyboard model
Source code
ONA19TB002 | ONA19TB003 | ONA19TB007
ACKNOWLEDGEMENTS
The team behind TWRP & OmniROM
@tek3195 for testing and feedback on the 8" model
Please post feedback since these are still pretty new and not exhaustively tested. Let me know if I should port it to other models in the series.
Reserved also
grabbing this one too cuz why not
Very nice! I'll download and test the 003 one soon.
I also have a 007 model to experiment with.
I tried about a dozen times to build TWRP and failed miserably LOL. Closest I got was one that would boot but the rotation was all messed up, USB wouldn't work, didn't mount some partitions... Yeah, it was a hot mess.
Do you happen to have sources available?
Hi @NFSP G35,
I'll have the source code soon. Most of the tricks involved patching bootable/recovery. So I need to commit those changes and include the proper patch set from my tree....
Amazing!! Gonna install and test 8" right now.
Has anyone tried a GSI on these tablets yet?
MishaalRahman said:
Has anyone tried a GSI on these tablets yet?
Click to expand...
Click to collapse
I do know @tek3195 , the Onn 8 thread starter, has tried many of them as well as others here, somewhere on that thread he listed his tests and opinion of several of them.
I'm pretty sure others on that thread have also tried GSI's.
MishaalRahman said:
Has anyone tried a GSI on these tablets yet?
Click to expand...
Click to collapse
I did try both Phhuson vanilla and also Liquid Remix (I'm keeping this one for now). I didn't flash them through twrp, but using fastboot via bootloader.
WoW! AwEsOmE! I cannot wait to try this! THANK YOU!!!!!!
Hey,
This is a neat thing to see for the Onn tablets. I have a question though. I own a device based on the mt8163, and am trying to help people with another device I don't own (the powkiddy x18 which also uses the mt8163). One of the things I wanted to do was to make a custom rom for the x18, since it's stock firmware is horrible. And of course, one of the first steps to custom roms is twrp. So I have a question for you that I hope you can answer for me. How did you make this build of twrp? I have seen no device trees for this device so I was kinda curious. If you can help me in any way, I'd be so grateful, and I'm sure the other people with the x18 would be grateful for help.
@diplomatic
Is there a different procedure for installing TWRP on a locked bootloader?
I can confirm that using SP Flash to load your TWRP.img will produce a bootloop when installing to a device with the BL locked. Reflashing the original recovery.img makes the problem go away. You mentioned in the OP that this TWRP will work on a locked BL so I thought I would share my case study with you in following the procedure you defined.
MY SINCERE GRATITUDE FOR YOUR EFFORTS IN PORTING THIS TO THE ONN!
You're welcome, @Spatry.... Can you describe how you ended up with a locked BL? Was it unlocked before? Have you ever tweaked vbmeta? Also, when you say bootloop, do you mean for Android or just for recovery? I'm not going to insist that it works under locked BL. I tested it once and it did boot up...
diplomatic said:
You're welcome, @Spatry.... Can you describe how you ended up with a locked BL? Was it unlocked before? Have you ever tweaked vbmeta? Also, when you say bootloop, do you mean for Android or just for recovery? I'm not going to insist that it works under locked BL. I tested it once and it did boot up...
Click to expand...
Click to collapse
Presently, I am running stock with Magisk patched BOOT on locked bootloader, stock vbmeta. The boot loop was at the ONN Android screen, I could not get it to even boot into recovery.
At one time I did run with the bootloader unlocked (with --disable-verification on stock vbmeta) and I ran Phusson's AOSP, Liquid Remix and Bliss. I found there was no benefit to me in running the other mods so I reverted back to stock courtesy of @CaffeinePizza and the bootloader re-locked to get rid of that annoying 5 second orange state.
In each instance, I always used SP Flash tools to load all .img files. I only used fastboot to install magisk_patched.img onto the stock installation. Unlocking the bootloader erases all data and I did not feel like reinstalling everything again, so I figured I would try to install TWRP per your instruction to see if it would work while the BL was still locked... Restoring the original recovery got rid of the bootloop. I do want to try your TWRP so I will try it with BL unlocked when I get some free time to do so.
Spatry said:
Presently, I am running stock with Magisk patched BOOT on locked bootloader, stock vbmeta. The boot loop was at the ONN Android screen, I could not get it to even boot into recovery.
Click to expand...
Click to collapse
This sounds like you might have flashed a wrong/corrupt image to recovery. It may have to do with AVB checks rather than bootloader lock. But those conditions might be interdependent somehow so I can't tell you for sure. The fact that you are able to boot a patched image on a locked BL says it doesn't care too much about verification. I can tell you for sure that any recovery image must have avb metadata, not necessarily the required hash, for both Android and recovery to boot. Can you try to unzip the image file and flash it over again?
Hmm, the situation with the bootloader lock sounds eerily similar to the Nabi SE. The latter also had a similar implementation where there's not much in the way of locking things down, other than an (easily circumvented) SP Flash Tool signature check and different preloader keys. And here's the real kicker: the nearly-identical Fisher Price Nabi also ran on the MT8163, so it makes me wonder if it's possible to boot Pie on it, or perhaps a GSI assuming that Treble can be tacked onto it.
Also, do you have the source repo to this TWRP port of yours?
If anyone here gave me an XDA ad-free subscription, thanks a lot! I didn't get a notification of who it was. Using this site is a lot more bearable now.
diplomatic said:
If anyone here gave me an XDA ad-free subscription, thanks a lot! I didn't get a notification of who it was. Using this site is a lot more bearable now.
Click to expand...
Click to collapse
Where do I find crypto footer to backup
diplomatic said:
If anyone here gave me an XDA ad-free subscription, thanks a lot! I didn't get a notification of who it was. Using this site is a lot more bearable now.
Click to expand...
Click to collapse
Kinda cool without the ads isn't it. I know I sent one about a week ago or so. I think everybody ought to send you one, you deserve it. THANKS and AWESOME work.

[Guide] Guides for x2 Pro[Locking/unlocking bootloader, tweaks and more]

At start i want to say that I'm not responsible for your bricked devices, houses set on fire, bla bla bla and so on.
Hello​
Since I see that many users are having problems with unlocking bootloader, flashing twrp and getting properly working Magisk. So here i come.
Downloads:
Everything you need you find here, on my OneDrive.
Unlocking Bootloader
BEWARE! After unlocking bootloader your DRM widevine will change to L3.​
Steps:
- download and install Realme_x2_Pro_DeepTesting.apk,
- open app and apply for deep test,
- enable Developer Options by tapping 7 times Version in Settings > About Phone
- go to developer options and enable OEM unlock and USB debugging,
- open app once again after some time tap "Query verification status",
- If you got approved application tap "Start the in-depth test" and phone will reboot to bootloader,
- on PC, download fastboot tools from somewhere else(unless you already have it, its not on my OneDrive)
- open folder where you have your fastboot installed, hold shift and click right mouse buton and choose "open command prompt here"(or Power Shell in newer version of windows),
- connect your phone to PC, and write
Code:
fastboot flashing unlock
- now on phone select "yes"
- now your phone will reboot and erase all your data,
- now you have unlocked bootloader.
Flashing Custom Recovery
I will guide you how to flash Custom Recovery.​
Steps:
- connect phone to PC,
- on your PC in command prompt type adb reboot bootloader,
- download TWRP image from mauronofrio or OrangeFox image from thread put in your fastboot tools folder on PC,
- download vbmeta.img from my OneDrive and put in your fastboot tools folder on PC,
- type
Code:
fastboot flash recovery *******.img
- type
Code:
fastboot flash vbmeta vbmeta.img
- when flashing is done, on your phone select "Recovery Mode" with volume +/- buttons and accept with power key,
- now it will boot into TWRP
Getting properly working Magisk
For now I recommend always using Magisk Canary Debug version cause it supports realme phones(stable needs magiskfix to get out of Core only mode).​
Steps:
-download Magisk Canary zip to your phones internal storage,
- boot to Custom Recovery,
- flash magisk,
- reboot to OS.
Updating ColorOS on rooted phone via TWRP
Use Magisk Canary cause it supports realme phones(stable needs magiskfix to get out of Core only mode).
This is the only way to update ColorOS via TWRP without losing magisk or running into damaged boot/recovery image message on boot for now. ​
Steps:
- download latest Magisk Canary, vbmeta.img and latest update package(ozip) for your device(cn rom for cn device, global rom for eu/in device), if you download update via official OTA app the package is located in
Code:
/data/oppo/coloros/OTA/.otaPackage
- reboot to Custom Recovery,
- flash latest ozip through twrp recovery(don't reboot yet),
- flash vbmeta.img through Custom Recovery
- flash magisk(if flashing fail, than reboot recovery),
- reboot to system.
Locking Bootloader
Think twice after evey step you did if it's done correctly before doing next step to prevent HARD BRICKS.​
Steps:
- download right latest ozip for your device from realme site(don't cross flash device, flash global ozip on eu/in devices and cn ozip for cn devices),
- boot to Custom Recovery,
- Flash ozip and after don't do anything else, just reboot to system,
- let it boot to OS and replace Custom Recovery with stock recovery.
- (optional) boot to recovery to check if it is stock, if its stock recovery than you can lock bootloader(don't ever try to lock with Custom Recovery),
- reboot device to bootloader and through adb go with:
Code:
fastboot flashing lock
- accept locking bootloader query on phone,
- device now will reboot and perform factory reset.
F.A.Q.​
Q: Can't flash xxxxxxxx.zip(or xxxxxxx.ozip/xxxxxxx.img) in Custom Recovery cause it throws an error, what to do?
A: Reboot recovery and try again.
...
...
hello bro, so when we do this is imposible to relock bootloader?
Arn0ldx said:
hello bro, so when we do this is imposible to relock bootloader?
Click to expand...
Click to collapse
It is possible, but you need to use for it some other guide as I will not guide how to. It's because I don't want users to cry over their mistakes in my thread.
Jerry08 said:
It is possible, but you need to use for it some other guide as I will not guide how to. It's because I don't want users to cry over their mistakes in my thread.
Click to expand...
Click to collapse
OK bro I'll wait then
this method is compatible with CN version? Can we install a stock Rom or EU rom after unlocking the bootloader? It's really pity for the fingerprint I think as the majority will wait a fix for this issue before doing that
Thank you for your work anyway
Nice Work
Great Guide. But at this time i'm not willing to trade fingerprint unlock for root and magisk .
Already losing the loading animation for using my good old lawnchair was disappointing can go back to coloros launcher easy though.
Maybe someone will/can find a trick for this boot unlock problem.
Thanks for your efforts!
As I don't own a X2 Pro (yet) I'd like to know how presumably it is to get a solution for the "losing fingerprint problem"?
From other phones I know, that Widevine Lv1 gets lost but I never had the problem of losing my fingerprint scanner.
I'm planning to purchase X2 Pro and it seems a flaw for me if unlocking bootloader will disable fingerprint.
Does anyone ever try not to set up fingerprint, pattern or PIN lock from the first phone setup and then directly unlocking bootloader, flash TWRP, magisk and still have locking features working?
rooveg said:
I'm planning to purchase X2 Pro and it seems a flaw for me if unlocking bootloader will disable fingerprint.
Does anyone ever try not to set up fingerprint, pattern or PIN lock from the first phone setup and then directly unlocking bootloader, flash TWRP, magisk and still have locking features working?
Click to expand...
Click to collapse
Doesn't work. I tried it like that when I got the phone. Not logging in or setting anything on the phone, went straight to installing the unlock APK and unlocking the bootloader, still the FP issue.
rooveg said:
I'm planning to purchase X2 Pro and it seems a flaw for me if unlocking bootloader will disable fingerprint.
Does anyone ever try not to set up fingerprint, pattern or PIN lock from the first phone setup and then directly unlocking bootloader, flash TWRP, magisk and still have locking features working?
Click to expand...
Click to collapse
Will not work cause when you unlock bootloader it formats data, so fp lock will be removed...
henrym1203 said:
this method is compatible with CN version? Can we install a stock Rom or EU rom after unlocking the bootloader? It's really pity for the fingerprint I think as the majority will wait a fix for this issue before doing that
Thank you for your work anyway
Click to expand...
Click to collapse
This method should be compatible with CN version. And for the 2nd question answer is: no, at least not yet.
Is the FP issue permenant .i mean i locked the bootloader again and all seems good now....but does that mean the realme x2 pro cannot be rooted without loosing FP???
This sucks big time ...its a shame on oppo/realme
Wow, if there is no method of getting root on this phone and not losing the FPS it would be massive setback ?
Jerry08 said:
Will not work cause when you unlock bootloader it formats data, so fp lock will be removed...
Click to expand...
Click to collapse
I think we're lost in translation.
Is bootloader unlocking and data wipe causing a permanent fp lock removal? Or just the ones that we have already set? If it's the 2nd case, then we can go back and set it up once again, right?
loumaros said:
I think we're lost in translation.
Is bootloader unlocking and data wipe causing a permanent fp lock removal? Or just the ones that we have already set? If it's the 2nd case, then we can go back and set it up once again, right?
Click to expand...
Click to collapse
No, fingerprint sensor is disabled. Can't do anything with it on unlocked bootloader. And once you lock bootloader you get back fingerprint sensor.
Ist there any way/chance of the fingerprint issue getting fixed by xda developers (magisk module, flashable zip, whatever) or can this only by fixed by Realme itself via updating firmware respectively bootloader?
bmwbasti said:
Ist there any way/chance of the fingerprint issue getting fixed by xda developers (magisk module, flashable zip, whatever) or can this only by fixed by Realme itself via updating firmware respectively bootloader?
Click to expand...
Click to collapse
There's always a chance, be patient. I don't see a big issue with fingerprint. I got used to faceunlock. Using for a week already and I like it even more than unlocking with fingerprint.
@Jerry08
Thanks for your answer ?
It's not about not beeing patient, but rather don't have a good feeling if such a mandatory part of the phone won't work. It's just like buying a new car and not beeing able to use the remote control to lock the doors and telling people "I don't mind cause I got used to use the key instead" ?
Don't get me wrong, I'm using faceunlock very often on my device but I have a bunch of apps where I use the fingerprint scanner to log in oder authorize and I would really really miss that feature.
It's less about not beeing able to use the fingerprint scanner for a few weeks but way more about beeing able to use the fingerprint scanner in some days/weeks in connection with an unlocked bootloader (again).
As I need a new phone theese day (and Black Friday is ahead) I can't wait a few month to see, if this issue gets fixed. Otherwise I would just watch the Realme x2 pro forum and buy (or not) in a few weeks or months ?
bmwbasti said:
@Jerry08
Don't get me wrong, I'm using faceunlock very often on my device but I have a bunch of apps where I use the fingerprint scanner to log in oder authorize and I would really really miss that feature.
It's less about not beeing able to use the fingerprint scanner for a few weeks but way more about beeing able to use the fingerprint scanner in some days/weeks in connection with an unlocked bootloader (again).
Click to expand...
Click to collapse
I couldn't agree more. Most banking apps use fingerprint to bypass the password section. Also face unlock is not as secure as fingerprint.
It's a same as I would compromise on the not-so-good-photo quality over the speed and battery life of that device
@Jerry08 I did what you said, replaced the build.prop, then went to twrp, flash it, then flash your magisk canary you provided but build.prop did not get replaced. Here is the file https://drive.google.com/open?id=1CBvMuFwr84PDRZror4H9I8Std_kNNhQg My device name is RMX1991CN

Categories

Resources