yashsingh1/xdaforums huggingface dataset:
[Android Q&A, Help & Troubleshooting] GabrialDestruir:
This is a good point, it would prevent remote wiping without wifi, but there are options where you could set the device up so it'd wipe for example if the SDCard went missing or changed. Tasker can detect SIM ID's then if the SIM ID doesn't return or isn't the same as the initial one it would then trash the system and throw the device into a bootloop that'd require reflashing.

It's not hard to find ways to combat what a thief might do, but without the ability to lock our bootloader the way we please any OS implementations of security can easily be circumvented. On some devices it's easy to just relock the existing bootloader but this doesn't prevent the user from unlocking it the same way you did which will then wipe the device (in cases of nexus 4,7,10) which then leaves a user with a device that they can use without any additional effort.

The solution I suppose could be a rom that's designed to flash in place of the factory.zip and then could have a built in piece of code that tags the designated marker within the system that will force the device to send it's location to a designated target. If this were all hardcoded in then it'd mean short of a new rom the phone could still be recovered by the owner. However this wouldn't be easy to implement and to make it work on a larger scale for everyone would mean putting out information that would allow thieves to find and disable such protection.
[Android Q&A, Help & Troubleshooting] imbakes:
Please correct me if I am wrong, but it seems that this is not true.

If the feature was installed as a system app it would survive a factory reset, as this part of the system memory is not affected by a restore.

And I'm also pretty sure this already exists:

The anti-theft app Cerberus has a "disguised" version that enables...

The app also has features for the SIM change detection etc. that have been mentioned.

But more importantly, I am interested in protecting the boot loader such that the only way to restore or gain access to the device is through JTAG (since it seems this is likely to not be easily patched, and a pain in the butt). The solution should be designed such that it is difficult to flash a new ROM, therefore they would hopefully "settle" with a factory reset, which would allow your security app to continue functioning without notice.
[Android Q&A, Help & Troubleshooting] GabrialDestruir:
On some devices it's possible for recovery to completely wipe system using a factory image file. I'm not sure to what extent this exists on all android devices but I've had a few that were designed so if the system got hosed it'd completely wipe the system. This would mean that any security apps could get wiped out unless they were in the factory image. On these particular devices you could mimic the system being trashed by turning the power off mid-boot. Which would then do a full system wipe.

However I didn't know about Cerberus at the time of my post, and it does seem to do these things. It would just be a matter of making sure it was in whatever factory image exists for devices that might have the ability to wipe system.

I agree with your last statement, that would be the best way to go about it.
[Android Q&A, Help & Troubleshooting] dvn2008:
+1

I lost a phone once, unfortunately the tracking software did not work.. the thief probably wiped out the OS.

Perhaps Google or Android developers can build a protected bootloader/recovery mode/download mode with something similar to SIM card's PIN/PUK1/PUK2?

When a user buy a phone he will get a PIN for entering recovery/download mode. If he forgot his PIN then he can contact the manufacturer customer care to get the PUK.
[Android Q&A, Help & Troubleshooting] gigsaw:
I think that is a really serious problem and no OEM cares enough to provide a solution, but I have a suggestion and a partial solution..without setting passwords (they are dangerous because if you forget them, you are f*cked), I agree that the bootloader should work only over internet connection, and probably an authentication in two steps (like google uses for Gmail) would be thief-proof, in that way a pc and a mobile phone works like a key and its lock, if they have the same google account logged in.

Till now i found a sort of work-around that could increase the possibility to find the phone (with non-removable battery):

-set a lock screen protected with patterns, PIN or Password

-download this from play store https://play.google.com/store/apps/details?id=com.nezdroid.lockscreenprotector this app doesn't allow the power-button menu to pop out while the screen is locked, so the thief can't turn off the phone or put it in airplane mode.

now you have all the battery-time to find your phone. Even if the thief pulls out the sim card, the gps works and there are some google securety services present in android to find it, and in cyanogenmod there are even more security options. It's not sure that you will find your mobile, but at least your data are quite safe if you leave the bootloader locked (if the thief unlocks it, your data will be automatically wiped). Of course ADB and fastboot are still a problem without any bootloader protection..damn :s
[Android Q&A, Help & Troubleshooting] dcacklam:
Actually, it is NOT pointless...

Once you get past the short-sighted, consumer-centric focus on theft prevention...

There is a *managability* angle to a password protected recovery, on devices being used as a kiosk or company-issued phone: Keeping the 'dumb luck idiot' who manages to get *into* recovery by fat-fingering buttons while powering up, from screwing up his phone while trying to get OUT of recovery & generating a support call...

For example, let's say I put CWM on a bunch of phones WITHOUT rooting them, and hand them out to users... I do this, so that I can restore backups when the phones come back to me - ala 'Norton Ghost' on PCs...

Joe IdiotUser manages to get into recovery, then thrashes around tapping buttons to try and get out... In the process he manages to mash 'wipe', ignores the disclaimers/warnings, and nukes his phone's OS from orbit...

Yes, this is easily fixable, but if there was a password on recovery, it wouldn't be *possible*.... And yes, end-users (as a community) are that stupid... Ask anyone who works in IT - if there's a button they'll push it, if there's something they can break, they'll break it...

No, it wouldn't prevent Jimmy XDAMember from turning his locked down phone into a wide-open one, but that's not the problem I'm worried about... I just want to keep the 'Help me, I'm lost, hmm I wonder what this button does' crowd from screwing up their phones, while also issuing non-rooted phones that can be re-imaged on return...

A password protected recovery is just the ticket....
[Android Q&A, Help & Troubleshooting] Visabusiness:
We need this passwords more than anything else in the world. Hope some genius can find the solution.
[Android Q&A, Help & Troubleshooting] nasvi:
+1 on Password Protected Recovery/Bootloader.
[Android Q&A, Help & Troubleshooting] devinger:
I was thinking the exact same thing. Add a password to the recovery menu to prevent a full whipe or flash so anti theft apps will keep on running. I already lost a phone with a security app because the thief did a full whipe or flashed it less than an hour after he or she stole it. Please somebody develop it! :)
[Android Q&A, Help & Troubleshooting] kInOzAwA:
+1 for Password protected on the recovery & bootloader.

I was thinking the same way like you guys. This is indeed the downwards side of the android OS. There will be a privacy phone like Blackphone from the silent circle/geeksphone/pgp project to be release soon. I don't know either it will implement the same idea like this or not. But i wish that there will be someone step forward to bring this to customization on android OS. Yes, without the password on the bootloader/recovery there will useless for the average joe to do anything they want. Everything got a downside, but this is better than not having a password protected thing. :good::good:
[Android Q&A, Help & Troubleshooting] md1008:
I have a few ideas that Google could implement. Make it an option to have a password in the bootloader to where you can't enter recovery,fastboot unlock, or enter recovery without the password. Obviously if your bootloader is unlocked than it's an open house for thrives

Another option would be to have your emei/ESN attached to Google play services so if a their were to factory reset they could not use Google services with out the password. So if a their were to factory reset or flash a ROM they would have a Google less phone. And as we all know not many people would want a galaxy phone with out ability to use apps. Basically covert a $800 Note 3 into a glorified dumb/feature phone.

Of course neither is full proof with JTAG or changing imeis but why not make it as difficult as possible for some either invade privacy of phone or whipe it to resell...

People who say don't loose your phone... Yeah because when a person loses there phone they do it on purpose or purposely let someone steal there property because YOLO...that's like saying people should just not get into a car accident....humans are prone to errors we are not robots. We aren't perfect nor computers. We have personalities
[Android Q&A, Help & Troubleshooting] zelendel:
With as much personal info that people are deciding it is a good idea to store in their phones :rolleyes:*should* make them be more careful. I have had cell phones for over 15 years and have never lost one. I have had one stolen but never would I loose something I paid $600 for. Who does that?

Now here is your double edge sword. Say they do add a password to it and you forget the pass word or the password gets corrupted on the system side. Guess what you have then, A nice brick that you cant do anything with short of a JTAG.
[Android Q&A, Help & Troubleshooting] RusherDude:
3 is very wrong. non-removable battery phones have hardware routines to simulate a baterry pull-off (example, pressing power-off button for 15s on Nexus 5 resarts the phone simulating a battery pull-off).
[Android Q&A, Help & Troubleshooting] fei0316:
So the thread had opened for three years and there are still no solution... I'm not a developer but I just wanna know what are the difficulties on doing that? Are there any reply from TWRP?

Sent from my Nexus 5
[Android Q&A, Help & Troubleshooting] eatsleep:
+1!!!!!!!!!!!!!!
[Android Q&A, Help & Troubleshooting] muzhik:
+1 -- any solution to this problem?
[Android Q&A, Help & Troubleshooting] spearoid:
What about IT Deployment?

I apologize for not having read all 8 pages of this thread, but I've looked at other hits online regarding this topic too and it doesn't seem like anyone is addressing this need for the same reason I have this need.

I don't care about thieves and data and the getting into download mode workaround for a recovery password.

I am deploying 30 Android tablets to a K-12 school. I have created an image with a restricted user profile that I replicated to each tablet. I have used xposed framework mods to disable the menu button, long-press of the power button and other things. I'm actually pretty pleased with how locked down I was able to make these tablets. The restricted user can't get into settings, change anything in the launcher, or even turn off WiFi.

But for all the tests I've done, the only way some student could screw up my tablet is if they knew how to boot to recovery. There they could wipe it or do whatever they want. I am not the least bit concerned about a student bringing in a laptop, connecting it to the tablet, getting into download mode, and flashing a new recovery. If they do that, then the teacher proctoring the tests should be fired. :) I simply want to eliminate this one simple loophole, where the student could manually boot into recovery. Fortunately, with the xposed mod, they can't even power off the tablet easily.

But THIS is why I want a password protected recovery, and I would think anyone deploying tablets into a school or business where they're trying to lock things down would want this very thing too. I think of it like password protecting the BIOS of a computer. Sure, you can take the computer apart and switch a jumper to clear the password, but I'm trying to prevent the EASY ways of destroying a computer or tablet, not the harder ways.
[Android Q&A, Help & Troubleshooting] demkantor:
[MENTION=1588027]spearoid[/MENTION]

If your tab has fastboot or a download mode that you could use yourself in the future, why not just erase the recovery from tablet all together?

Then when you need to add the recovery back in just flash it yourself first? Just an idea
[Android Q&A, Help & Troubleshooting] spearoid:
Yeah, I hadn't thought deeply about what to do if a passworded recovery doesn't exist. I really like having a recovery so that I can restore an image easily if something gets screwed up, or if I make a new/updated image, I could install it via SD card pretty easily.

If I have to destroy the recovery to close this loophole I will, but I'm not totally sure someone can get into recovery right now anyway because of the way I have locked down the power button when the tablet is on. There doesn't seem to be a way to power off the tablet at all with this mod installed....unless the battery runs out.
[Android Q&A, Help & Troubleshooting] demkantor:
Well not sure what make and model tablet you are using but I haven't seen an android device that doesn't allow for a reboot with hardware keys.

Even if it is a sealed battery device with only power and volume keys usually the combo is hold all three keys for 10seconds and it will reboot

Not to say what you're doing isn't helpful, just that it is near impossible to fully protect any android device (or any tech really) but depending on situation there are many things to make unwarranted use very difficult

Best of luck with your project!
[Android Q&A, Help & Troubleshooting] spearoid:
We're using galaxy tabs. And the only way to do anything with this tablet, with the mods I have running, is to hold the power button for ten seconds. That forces a reboot. You then have to try to press the right buttons as soon as the reboot starts to get into recovery. There is no way to power off the tablet without just letting the battery run down.

So one can get into recovery, but it isn't as easy as normal given the way the power button is being hacked with an Xposed module.

This is why I'd love to password protect the recovery. That's the only way someone could do any damage to the software I have installed. Even though it is harder to get into recovery than normal, it can still be accessed. And I'd rather keep the recovery around so I can do backups and restores without having to use a computer at all.
[Android Q&A, Help & Troubleshooting] THE_KINGDOM:
+1 for dev's to develop a kernel/recovery that gives the OPTION to password protect the bootloader. This would prevent a thief from wiping the device, and phone would eventually be trackable when turned back on.
[Android Q&A, Help & Troubleshooting] baldbunny619:
fastboot oem lock

So much ignorance in this thread. Why would anyone forget the password hmm? IT DOESN'T EVEN HAVE TO BE DIFFICULT, just difficult enough for a FENCE(not the thief) to recognize that its not the OEM lock and its not wide open and OMG how do I sell this? CONTACT THE OWNER and pray they offer a fiver for the stolen goods you have no right to demand a reward for!

Using fastboot its possible to re-enable the OEM lock. It shouldn't be too far a stretch to setup a custom password fastboot lock, and from there set up CWM or whatever recovery environment to recognize the OEM lock is in place and refuse to install zip files or wipe data without the fastboot password. One of these is on the dev/mod/hacker community. There is simply no reason not to have something resembling a password in CWM. I wouldn't be surprised if the same community could also mod fastboot, but I can't say its their responsibility either.

Dear lord though people. Every other post in this thread opposes password locks at all. Suddenly, honor among thieves is not locking your own doors? I mean, what other environment asks everyone entering to please remove all weapons and lockables besides a thieves den? ... and one run by idiots who hate pracice at that?
[Android Q&A, Help & Troubleshooting] lulli1:
+1 for a password protected Bootloader.

No need for a password protected custom recovery, because if you switch of usb-debugging and don´t allow to enter the status bar as well as don't allow to power off your device from lockscreen, this would be a great security method. No access to any recovery would be possible.

In combination with SMSTasks you could toggle gps on, to find your device and the thief can´t do anything (in case of Nexus 5 without battery pulling possibility).

That would be THE thing!
[Android Q&A, Help & Troubleshooting] zacsaturday:
Just the original or all?

+1 would be good if it was all.
[Android Q&A, Help & Troubleshooting] devinger:
So I went on searching and have some good news. :D

1. Samsung will be releasing a feature that will detect if your phone is flashed to an other rom without your authorisation. The test starts in the Netherlands with the note 4. I would really like to know how that works, and if we can implement such a feature ourselves with a few custom features.

2. PhilZ Touch costum recovery now has a Recovery Pass-Key Lock! I can't link yet so google it :)
[Android Q&A, Help & Troubleshooting] x111:
+1 for a password protected Bootloader, recovery
[Android Q&A, Help & Troubleshooting] nasvi:
Don't let dumb people play with your stuff....

Problem solved....
[Android Q&A, Help & Troubleshooting] AAA118:
Yup this is true and thats why password protection is needed. The advantage of non removal battery phones is they cant be shut down.
[Android Q&A, Help & Troubleshooting] frnt:
i just think about this feature, googled. and after visiting this old thread, i began to think there will be no password protected CWM / Bootloader :(
[Android Q&A, Help & Troubleshooting] doton:
how is it possible?
[Android Q&A, Help & Troubleshooting] ayush321:
+10

I relly like this concept of password protected bootloader for anti theft.

The thieves will obviously know how to get into recovery or odin but if it gets a paasword protection, no one can steal our phone.

Plus with some apps you could easily trace your phone. The would be really handy.
[Android Q&A, Help & Troubleshooting] seansc144:
This is sorely needed for android enthusiasts.
[Android Q&A, Help & Troubleshooting] zelendel:
This is a double edge sword that people are not thinking all the way through. If it is made to happen the OEM and carriers could completely lock the device down.
[Android Q&A, Help & Troubleshooting] starslab:
I'm going to weigh in here with something that doesn't seem to have been considered.

I don't give a **** about the phone. Seriously. Some **** steals it (which hasn't happened to me before) I'll just buy a new one.

I care greatly about the security of the data on the device. I keep backups, so I don't care about _losing_ it, but I don't want it disclosed to the thief or whoever ends up with the phone. The FDE in Android is most of the solution to this problem. My Nexus device can have the bootloader locked, so an attacker can only install factory software images (which won't compromise my data, and will immediately alert me that - hey - this isn't my ROM). To unlock the bootloader the attacker has to nuke my data. So I'm perfectly fine with the current state of affairs as far as the bootloader on the Nexus devices goes.

However, even if I lock the bootloader, an attacker can boot into Cyanogen Recovery and install a trojan-horse ROM that'll bone me when I "find" my phone. This is the hole that I want to close with an optional password-protected Recovery.

And yes, I do realize that I am paranoid. However, this approach has already saved my ass with Truecrypt on my laptop. The thief would have taken the laptop with him out the window if he hadn't turned it on and realized it was a brick.
[Android Q&A, Help & Troubleshooting] optimumpro:
I am with you, but it simply won't be possible until your manufacturer implements it or open source their bootloaders. The latter will never happen, because if they do, you might find multiple backdoors for "freedom loving" governments, which nowdays include all western governments+.

Also, even if you have a bootloader password, nothing prevents a thief from flashing stock rom wiping everything without ever accessing bootloader. So, you also need a mechanism to prevent access to flashing mode. Again, no one but your manufacturer can do it...

I see only one solution: if your phone has a separate charging outlet, epoxy usb connection, get rid of external sd card and epoxy that socket too. Then encrypt your phone, and before losing, turn it off. That way it might be quite difficult even for a state adversary to get to your data. Yet, they still have other means of "talking" you into turning the phone on for them: fingers jammed in the door? :)
[Android Q&A, Help & Troubleshooting] starslab:
Erm.... Did you even read the post? I explicitly said I'm fine with the bootloader on my Nexus device, it's an optional password-protected Recovery that I want....
[Android Q&A, Help & Troubleshooting] optimumpro:
I read the post, so, there is no reason for jumping to conclusions...

Password for recovery? You can have 20 passwords: all I have to do is put the phone in fastboot and execute the following: fastboot erase recovery. And your recovery (together with passwords) will be gone. Then the next step is: fastboot flash boot boot.img (my image) and I have access to your phone.

I don't think you are paranoid at all, but what you are asking is impossible to implement unless done by manufacturer or bootloader source code is made available for everybody...

Edit: even if your bootloader is locked, no sophisticated attacker would ever need to install a rigged rom to spy on you. If they need your data, they will simply and easily target your phone through modem/baseband and will get everything without you or Android noticing anything (and note, they don't even have to have physical access to your phone).. Baseband is a mini OS with its own kernel, which is hooked directly into your ram and hardware. And pretty conveniently, baseband (hardware and software), as well as gps, are hidden inside the cpu chip (so, you can't touch anything there). So, in this case, your protected recovery, as well as data encryption will be useless.

The only way to protect against the above attack (provided they had not targeted you before) is what I have described (epoxing usb and sd card slots). This way you will create a big headache for snoops. Again, It will only work if they come to you and you have time to turn your phone off. To be sure, you should turn the phone off, then on and off again before the interface is up. This way, you will prevent a cold boot attack, which otherwise may recover your encryption key from ram. But if they had targeted your phone already (through baseband), even this won't help. In that case, you'll have to throw away your phone and run...
[Android Q&A, Help & Troubleshooting] adiman73:
This recovery may stall password?

You can not access the recovery than the password?
[Android Q&A, Help & Troubleshooting] xploited:
Holy sh** bro. You put a lot of thought in this and gave more than enough ideas for protecting our phones.

Thanks!
[Android Q&A, Help & Troubleshooting] lulli1:
[MENTION=5817557]aarongillion63[/MENTION]: wow... not bad! But what about the bootmenu on every nexus5? you can enter it by pressing and holding a combination of hardware buttons. from there you can access the phone via adb. and the other point is: even a nexus5 can be pulled out the battery. you can lift the back cover and do it as well as on every other phone. what we need is a password protected bootmenu. so there is no way to the custom recovery as well.
[Android Q&A, Help & Troubleshooting] zelendel:
There will always be a way around any locks. To be honest it is a waste of time