Unlock bootloader - Xperia Z1 Compact Q&A, Help & Troubleshooting

I want to install a aosp rom on my Z1 compact.
My Z1 compact is running and i am trying to unlock the bootloader. I have entered *#*#7378423#*# which says i cant unlock the bootloader.
Is there any other method to unlock the bootloader?

No, bad luck.

Do you think it will be possible in the future?

325i. said:
Do you think it will be possible in the future?
Click to expand...
Click to collapse
Who knows, it's a tiring subject, so either return your Phone and buy a SimFree Phone or keep it in the hope that maybe you'll be able to, but don't hold your breath.

2ndBoot method possible?
For some Android phones with a locked bootloader, for example Motorola Defy, a "2nd boot" method has been used to use custom roms.
The way I understand it, this leaves the stock kernel in place, so that the locked bootloader can boot the stock kernel that it insists on.
Using root permissions, the system is modified so that at some stage in the stock boot process, the boot process restarts with a possibly different, modified kernel and the definitely different, custom userspace system, for example AOSP.
Has this been done with Xperia devices, especially the Z1C?

Defyner said:
For some Android phones with a locked bootloader, for example Motorola Defy, a "2nd boot" method has been used to use custom roms.
The way I understand it, this leaves the stock kernel in place, so that the locked bootloader can boot the stock kernel that it insists on.
Using root permissions, the system is modified so that at some stage in the stock boot process, the boot process restarts with a possibly different, modified kernel and the definitely different, custom userspace system, for example AOSP.
Has this been done with Xperia devices, especially the Z1C?
Click to expand...
Click to collapse
This is extremely difficult to accomplish unless the kernel supports loading kernel modules on the fly, and the Z1C stock kernel doesn't. In fact, most devices don't these days since it enables things like this once the security of the ROM is compromised.
@325i. You will most likely (like 99.99%) never be able to unlock your current Z1C, return it and get an unlockable one, or change your mind about wanting to unlock it.

Related

[Q] [Q/Thought] ROMs for locked bootloader

A long time ago I've had an xperia X8, and was thinking about its software.
So, on it, I could install recovery, and then flash any ROM that is built for stock kernel, since I didn't unlock the bootloader.
My question is, couldn't the same concept be used on xperia M? With rachit's recovery for locked bootloader we could flash ROMs that are/will be made for stock kernel, right? If not, can anyone explain this to me?
No since Xperia M doesn't have a default recovery , you should unlock the bootloader in order to install any custom ROMs
XDAOwner!! said:
No since Xperia M doesn't have a default recovery , you should unlock the bootloader in order to install any custom ROMs
Click to expand...
Click to collapse
Actually, yes it would be possible with the concept the OP is describing. Once we have a fully working recovery for locked bootloaders it will be possible to build ROMs and then distribute them for other members to use.
OP just wait until there is a properly built/working recovery built for locked bootloaders (we have people working on it now) and then you will see ROMs built for locked bootloaders popping up.
gamer649 said:
Actually, yes it would be possible with the concept the OP is describing. Once we have a fully working recovery for locked bootloaders it will be possible to build ROMs and then distribute them for other members to use.
OP just wait until there is a properly built/working recovery built for locked bootloaders (we have people working on it now) and then you will see ROMs built for locked bootloaders popping up.
Click to expand...
Click to collapse
Hehe, I knew this would be the case. I've been experimenting with adb lately, and well, I'll try to make a script that (kind of) modifies some basic features until we make some progress with the recovery. Hope it doesn't take too long.
Just remember that only stock kernel works with locked bootloader. In other words, no OC and other things like that and only custom ROMs compatible with stock kernel would work...

[Q] Any reason to (re)lock the bootloader on an S-off device?

Other than warranty issues, and possibly redeeming your Google Drive space, are there any practical ramifications to simply leaving the bootloader unlocked (or, conversely, locked?) on an S-off device? I'm inclined to leave it bootloader unlocked unless I have a warranty issue, as it seems the safest way to make sure I'm never locked out, but I'm curious to know if there are any reasons to lock it from a security perspective.
I say that because right now when I lose root due to an OTA, I just boot (but not install) philz touch recovery to re-root, which I am assuming is allowed because I am s-off. (because otherwise root would be trivial). It seems that as long as I can do that, the bootloader lock/unlock state is somewhat pointless.
You are allowed to flash custom ROMs because you have installed a custom recovery, which was allowed because you unlocked your bootloader. I would leave the bootloader unlocked until a relock is required (if it even comes to that). As far as I know, that poses no threat as long as you know what you're flashing on your device. Anyone with more experience with this may correct me, as I am quite new to the HTC world.
MrKhozam said:
You are allowed to flash custom ROMs because you have installed a custom recovery, which was allowed because you unlocked your bootloader. I would leave the bootloader unlocked until a relock is required (if it even comes to that). As far as I know, that poses no threat as long as you know what you're flashing on your device. Anyone with more experience with this may correct me, as I am quite new to the HTC world.
Click to expand...
Click to collapse
I actually only had TWRP installed briefly to "restore" the Dev Edition nandroid (and by briefly, I mean I booted it once). As soon as the Dev Edition ROM was up, I reverted to the stock DE recovery. Since then, I just "boot" Philz CWM to re-root (since TWRP fails when booted on 4.4.3 for some reason.)

Fix lag with kernel Q

My girlfriend's 5x is perfect for her in every way except performance, is just too laggy. I've been thinking about installing a custom kernel to help address it. She uses Android Pay here in NYC regularly so I can't kill that for her and I'm reading that any bootloader unlocking/root breaks Android Pay.
My question is, can I just unlock the bootloader, install a custom kernel, and then re-lock the bootloader just to leave everything else stock? Is it that easy? If I understand correctly, she'd only need root to modify settings on the kernel so we'd have to pick one which accomplishes what she wants out of the gate.
If this is possible, what happens when an OTA comes out? Will I just likely need to keep the kernel updated as well myself by flashing it?
Thanks all!
Unlocking bootloader does not break Android Pay. Rooting will, but there is currently a workaround for that; however, it will likely be patched in a future Android Pay update.
To get an OTA to work, I believe you would need to flash back to stock over the custom kernel (should involve flashing the boot.img of the current build you're on). But, if you're going to need to flash stuff anyways, might as well just learn how to flash the update yourself. Search around the threads, there's plenty of information on how to do this.
Sent from my Nexus 5X using Tapatalk

Is there a way to root my Mi 6 without unlocking the bootloader?

Good day guys,
Today I received my Mi 6. Friends told me Xiaomis usually come with an option to enable root, but I can't find it here. Can anyone help me?
I think you need to install the Developers Rom and there you have an option to enable root.
Ammmm no, you can't, at least you discover a zero-day exploit with execution code and bla bla bla.
For Root, you need mod boot/system image in the best case, or flash a tool like supersu to make the changes in fly... so you need a unlocked bootloader or custom recovery and flashing custom recovery need a unlocked bootloader.
Theliels said:
Ammmm no, you can't, at least you discover a zero-day exploit with execution code and bla bla bla.
For Root, you need mod boot/system image in the best case, or flash a tool like supersu to make the changes in fly... so you need a unlocked bootloader or custom recovery and flashing custom recovery need a unlocked bootloader.
Click to expand...
Click to collapse
Thanks for the reply, I guess i'm requesting the bootloader unlock to Xiaomi then.
Theliels said:
Ammmm no, you can't, at least you discover a zero-day exploit with execution code and bla bla bla.
For Root, you need mod boot/system image in the best case, or flash a tool like supersu to make the changes in fly... so you need a unlocked bootloader or custom recovery and flashing custom recovery need a unlocked bootloader.
Click to expand...
Click to collapse
what about install TWPR (still locked) then root it? is it possible?
mennas said:
what about install TWPR (still locked) then root it? is it possible?
Click to expand...
Click to collapse
Are you kidding?
No.
When boot loader is locked only code signed by xiaomi will run.
So twrp will just not bootup.
Also fastboot is only enabled on the phone when boot loader is unlocked so you'd have a hell of a time flashing it
And then youd likely softbrick the phone with no recovery to flash a ROM so maybe even hardbricked...
Don't try.
Just unlock.
Dobsgw said:
Are you kidding?
No.
When boot loader is locked only code signed by xiaomi will run.
So twrp will just not bootup.
Also fastboot is only enabled on the phone when boot loader is unlocked so you'd have a hell of a time flashing it
And then youd likely softbrick the phone with no recovery to flash a ROM so maybe even hardbricked...
Don't try.
Just unlock.
Click to expand...
Click to collapse
I don't know if this applies to Xiaomi and if it works on more recent versions of Android but on Xperia Z3, installing TWRP with locked bootloader was actually possible I did it myself, and hundreds of others has done it to (you couldn't change to a non-stock ROM, without unlocking the bootloader of course, but that's a different story)
Obviosly that would need a newer exploit in order to push TWRP.
But of course Google or Xiaomi may had added additional protections to the bootloader since then.
(with this being said, you probably need to be quite experienced to start looking into that kind of stuff)
-Zteam- said:
I don't know if this applies to Xiaomi and if it works on more recent versions of Android but on Xperia Z3, installing TWRP with locked bootloader was actually possible I did it myself, and hundreds of others has done it to (you couldn't change to a non-stock ROM, without unlocking the bootloader of course, but that's a different story)
Obviosly that would need a newer exploit in order to push TWRP.
But of course Google or Xiaomi may had added additional protections to the bootloader since then.
(with this being said, you probably need to be quite experienced to start looking into that kind of stuff)
Click to expand...
Click to collapse
You'll notice on newer xperia phones that's jot possible
You have to unlock.
They wised up and patched the KitKat exploit (although one was found in the 575 kernel)
So yeah potentially it would be possible to find an exploit and modify /system.
But the Z3 (I own one too) required having the mods to be in system if the BL was locked. Wolfbreak obviosuly managed to get twrp installed to system and then used scripts to open it.
But a custom kernel would still brick the phone.
So you were confined to root and recovery and custom ROMs based on stock.
You have to unlock to modify the kernel (which most root now does to avoid safetynet)
So there's not much point in this system level exploit.
Phone wouldn't boot as soon as a non stock or modified kernel was installed (lots of people would try and do this and brick their phones I guarantee)
Much better to just unlock.
Dobsgw said:
You'll notice on newer xperia phones that's jot possible
You have to unlock.
They wised up and patched the KitKat exploit (although one was found in the 575 kernel)
So yeah potentially it would be possible to find an exploit and modify /system.
But the Z3 (I own one too) required having the mods to be in system if the BL was locked. Wolfbreak obviosuly managed to get twrp installed to system and then used scripts to open it.
But a custom kernel would still brick the phone.
So you were confined to root and recovery and custom ROMs based on stock.
You have to unlock to modify the kernel (which most root now does to avoid safetynet)
So there's not much point in this system level exploit.
Phone wouldn't boot as soon as a non stock or modified kernel was installed (lots of people would try and do this and brick their phones I guarantee)
Much better to just unlock.
Click to expand...
Click to collapse
Of course you will be much more limited without unlocked bootloader but on the other hand you don't have to void your warranty, unrooting your phone, without any traces of root is very useful, if you happens to need your warranty.
And you can still use stuff like setcpu, xposed framework, enable EIS and camera api2. just to name a few things.
Safetynet didn't bother me that much.
That's why people are looking for ways to root without unlocking the bootloader.
-Zteam- said:
Of course you will be much more limited without unlocked bootloader but on the other hand you don't have to void your warranty, unrooting your phone, without any traces of root is very useful, if you happens to need your warranty.
And you can still use stuff like setcpu, xposed framework, enable EIS and camera api2. just to name a few things.
Safetynet didn't bother me that much.
That's why people are looking for ways to root without unlocking the bootloader.
Click to expand...
Click to collapse
OK well when the exploit is found you'll have it
Dobsgw said:
Are you kidding?
No.
When boot loader is locked only code signed by xiaomi will run.
So twrp will just not bootup.
Also fastboot is only enabled on the phone when boot loader is unlocked so you'd have a hell of a time flashing it
And then youd likely softbrick the phone with no recovery to flash a ROM so maybe even hardbricked...
Don't try.
Just unlock.
Click to expand...
Click to collapse
10 hours left lol. i hope after 10 hours there will be no more additional trouble coming up.
So, my plan after im able to unlock it is to root>install twrp>flash it back to global stabel(my current is global beta).
im still confused about stay with beta or flash it back to stabel. Any sugesstion?
mennas said:
10 hours left lol. i hope after 10 hours there will be no more additional trouble coming up.
So, my plan after im able to unlock it is to root>install twrp>flash it back to global stabel(my current is global beta).
im still confused about stay with beta or flash it back to stabel. Any sugesstion?
Click to expand...
Click to collapse
Stay with beta its usually better.
Or switch to aosp if you don't like MIUI
Stable Oreo should come soon as the Chinese ROM just got Oreo stable
Dobsgw said:
Stay with beta its usually better.
Or switch to aosp if you don't like MIUI
Stable Oreo should come soon as the Chinese ROM just got Oreo stable
Click to expand...
Click to collapse
ok. ill stay with this beta oreo then thanks
Dobsgw said:
Stay with beta its usually better.
Or switch to aosp if you don't like MIUI
Stable Oreo should come soon as the Chinese ROM just got Oreo stable
Click to expand...
Click to collapse
Wait, is Chinese stable on oreo already?
NickTheSickDick said:
Wait, is Chinese stable on oreo already?
Click to expand...
Click to collapse
Yeah.
Also expecting Oreo kernel sources to release soon too
Dobsgw said:
Yeah.
Also expecting Oreo kernel sources to release soon too
Click to expand...
Click to collapse
Damn, that didn't take long. I remember just how buggy it was when oreo first entered alpha.
NickTheSickDick said:
Damn, that didn't take long. I remember just how buggy it was when oreo first entered alpha.
Click to expand...
Click to collapse
They need to be even quicker 8.1 has been out for a fair while as well....
At least it got to Oreo.
I'm sure there will be more updates for the "stable" branch soon.
In my use I found beta to be better

Relock the bootloader or not?

I've successfully flashed my first ROM. My purpose in doing so was to get the monthly Android security updates, and more broadly have my phone as secure as practical. In that vein, can I safely relock the bootloader? Should I? I am aware that many (most?) people here choose to keep the bootloader unlocked, and I respect that choice, but I'm seeking maximum security.
Searching here at XDA I see conflicting guidance. Some folks say that re-locking the bootloader with a custom ROM installed is begging to be bricked, while others say they have re-locked with no trouble. So what is your advice, why is that your opinion, and do you speak from experience?
I have not rooted the phone, nor do I plan to. I'm running AICP 8.1 on Nextbit Robin and don't plan to make any changes other than receive OTA updates. Should I make future changes beyond that I would not be bothered by the very minor inconvenience of having to unlock then relock it.
I too want to simply flash the stock recovery and lock my bootloader, but from what I've read to update the ROMs we need an unlocked bootloader. So that needs to be unlocked again does that mean everytime I lock-unlock I will be wiping my data all over? Thats would be a pain.
So this is an experiment I want to run from quite long and might do it sometime next month maybe. I will be wiping-unlocking-flashing-locking and see again if I can unlock without wiping my data and lock again, this way I can know for sure if this is doable because most online answers are weirdly confusing.
javelinanddart found that locking the bootloader on the Robin results in similar behavior as on the Nexus devices. The phone will check and make sure that the key used to sign the recovery partition remains the same as it was when your device got relocked, so as a result, TWRP should still work, and updating to a new version of TWRP would work too since it's (presumably) signed with the same key. System partition checking is handled by the kernel itself (dm-verity), but all the custom roms for the Robin have that disabled, so that wouldn't be a problem.
I've also been running custom roms with my bootloader locked and haven't run into any issues with flashing roms with TWRP.
I will be honest though, since TWRP lets you do so much to your phone, relocking your bootloader wouldn't really help security wise. You can pull up a damn root shell right in TWRP, for crying out loud.
@jabashque
Wait so are you saying despite locking the bootloader I can still go in custom recovery? Whats the point then?
I mean for me why I a considering locking the bootloader is so that if I lose my phone no one can access my data. As of now with custom ROM anyone has free access to my data via TWRP/custom recovery.
/root said:
@jabashque
Wait so are you saying despite locking the bootloader I can still go in custom recovery? Whats the point then?
I mean for me why I a considering locking the bootloader is so that if I lose my phone no one can access my data. As of now with custom ROM anyone has free access to my data via TWRP/custom recovery.
Click to expand...
Click to collapse
I suppose you could flash Lineage recovery instead, which was designed to be an OEM-grade recovery and doesn't include the ability to pull up a root shell or use adb.
Grab that here: http://downloads.codefi.re/jdcteam/javelinanddart/ether/ether-lineage-recovery-20180310_170949.img
Personally, I locked my bootloader so that I could actually see my custom splash screen without having to press the power button to dismiss the warning message.
EDIT: the build of Lineage recovery I linked still has adb shell access enabled it seems; I was wrong on that. Also, I haven't tried flashing another rom's system partition that's been signed with different keys.
jabashque said:
I suppose you could flash Lineage recovery instead, which was designed to be an OEM-grade recovery and doesn't include the ability to pull up a root shell or use adb.
Grab that here: http://downloads.codefi.re/jdcteam/javelinanddart/ether/ether-lineage-recovery-20180310_170949.img
Personally, I locked my bootloader so that I could actually see my custom splash screen without having to press the power button to dismiss the warning message.
Click to expand...
Click to collapse
So for an OTA update do I have to wipe all data to unlock again? I am on Omni btw.
I only unlock my bootloader to flash a cool splash screen then relock it. Even if the bootloader is locked I can still flash custom ROMs using ADB sideload. Works like a charm every time. I'm running the AEX custom ROM with Android 8.1.0
akeemk said:
I only unlock my bootloader to flash a cool splash screen then relock it. Even if the bootloader is locked I can still flash custom ROMs using ADB sideload. Works like a charm every time. I'm running the AEX custom ROM with Android 8.1.0
Click to expand...
Click to collapse
But you still locking it while on TWRP isn't it? Which means anyone has access to shell via TWRP defeats the purpose of security provided by a locked bootloader, isn't it?
/root said:
But you still locking it while on TWRP isn't it? Which means anyone has access to shell via TWRP defeats the purpose of security provided by a locked bootloader, isn't it?
Click to expand...
Click to collapse
I guess that's why Nextbit never had a problem with us unlocking the phone's bootloader.

Categories

Resources