One of the biggest enemies for people who frequently switch ROMs is the encryption system, many times we end up wiping the entire device.
OnePlus 5 and 5T had a method to decrypt the device and not having to worry about accidental wipes ( NO-Verify.zip)
Has anyone tried the same method on our 6T?
Well i tried it on my 6T and it worked, but with one problem.
After decrypting permanently when i locked device with any password or pattern, it didn't accepted the password i set it up with.
So moved back to encryption
You should not have to do that. I recommend you read this thread all the way through; I think your answer is here, under the How to create a Nandroid Backup.
https://forum.xda-developers.com/oneplus-6t/how-to/guide-oneplus-6t-unlock-bootloader-t3851789
"Boot into TWRP
Use the TWRP File Manager and Navigate to /data/sytem/ and delete the following files:
locksettings.db
locksettings.db-shm
locksettings.db-wal.
gatekeeper.password.key
gatekeeper.pattern.key
You may or may not have all the above files so delete the ones you have.
Reboot the phone and (if you've set a PIN) enter it to decrypt the storage one more time. After that you can simply unlock your phone with a swipe."
hithekillswitch said:
You should not have to do that. I recommend you read this thread all the way through; I think your answer is here, under the How to create a Nandroid Backup.
https://forum.xda-developers.com/oneplus-6t/how-to/guide-oneplus-6t-unlock-bootloader-t3851789
"Boot into TWRP
Use the TWRP File Manager and Navigate to /data/sytem/ and delete the following files:
locksettings.db
locksettings.db-shm
locksettings.db-wal.
gatekeeper.password.key
gatekeeper.pattern.key
You may or may not have all the above files so delete the ones you have.
Reboot the phone and (if you've set a PIN) enter it to decrypt the storage one more time. After that you can simply unlock your phone with a swipe."
Click to expand...
Click to collapse
In case I delete these files do I need to set a pin or if I reboot to TWRP next time it will not ask me for it ? I am asking because I have lost my internal storage thrice before trying to only install OOS.
My understanding is this will only remove your password. I would read the whole thread above, and always make a backup with TWRP and titanium or the like, and save those backups to a PC as well as the phone storage. Encryption is tricky, but you know that already. Good luck!
hithekillswitch said:
You should not have to do that. I recommend you read this thread all the way through; I think your answer is here, under the How to create a Nandroid Backup.
https://forum.xda-developers.com/oneplus-6t/how-to/guide-oneplus-6t-unlock-bootloader-t3851789
"Boot into TWRP
Use the TWRP File Manager and Navigate to /data/sytem/ and delete the following files:
locksettings.db
locksettings.db-shm
locksettings.db-wal.
gatekeeper.password.key
gatekeeper.pattern.key
You may or may not have all the above files so delete the ones you have.
Reboot the phone and (if you've set a PIN) enter it to decrypt the storage one more time. After that you can simply unlock your phone with a swipe."
Click to expand...
Click to collapse
This doesn't work any longer starting with pie. At least both times I tried it. Last i got it to go was with Oreo on my shamu and essential. Also, no verity and anything disabling encryption, disables any phone security until u restore with msm.
Related
I'm a complete beginner when it comes to rooting, flashing and so on. I've been using my Nexus 4 since the day it came out, and have always had it completely stock, never even rooted it or anything. I'm normally not too bad at stuff like this, but I've been googling how to do all of this and been reading some guides on here, and I'm just getting more and more confused.
My goal is to go from Stock Android 5.1.1 to the newest Cyanogenmod nightly, and to keep all my data. Now, how do i go about this?
I'm already stuck at the first step (or at least I think, that's the first step): Creating a backup of my current Stock phone. Apparently I need to create a NANDROID backup first, but I can't do it with a locked bootloader? And if i unlock the bootloader, my data will be wiped? This alone seems completely illogical to me, because how am I going to backup my device then? Is there no simple step by step guide for Nexus devices, that includes EVERYTHING, from backup to the final flashing of the ROM?
This is a good guide http://forum.xda-developers.com/showthread.php?t=2018179
I've seen it and it doesn't answer my question. How do I unlock the bootloader to create a backup, without wiping my device?
jb91 said:
I've seen it and it doesn't answer my question. How do I unlock the bootloader to create a backup, without wiping my device?
Click to expand...
Click to collapse
You can't unlock the bootloader without wiping the device. The only backup you will be able to make without an unlocked bootloader is copying your sdcard to your pc and use an app like helium to backup your apps and data. Just remember to copy that backup to your pc as well, otherwise it will be wiped.
theminikiller said:
You can't unlock the bootloader without wiping the device. The only backup you will be able to make without an unlocked bootloader is copying your sdcard to your pc and use an app like helium to backup your apps and data. Just remember to copy that backup to your pc as well, otherwise it will be wiped.
Click to expand...
Click to collapse
Thanks. Do you know this "Nexus Root Toolkit" program? I was able to create a backup file containing all apps with it, as well as extract a file with my contacts data from my Nexus 4. I'm guessing this should also include my SMS / WhatsApp messages and so on?
jb91 said:
Thanks. Do you know this "Nexus Root Toolkit" program? I was able to create a backup file containing all apps with it, as well as extract a file with my contacts data from my Nexus 4. I'm guessing this should also include my SMS / WhatsApp messages and so on?
Click to expand...
Click to collapse
Unfortunately I don't know much about that. You could skim through some of the thread or search to find out if someone else has asked that question and if not ask it there. That would probably be the easiest way to find out.
This is extremely confusing, I have no idea how people can say it is simple to put a custom ROM on a Nexus device. I am absolutely lost trying to back up everything. Is a NANDROID backup just a full backup of the phone? Am I not completely screwed if I can't create this? I have some random app files, extracted from a Root Toolkit, and a contacts file. I don't think that's enough to save my device in case anything goes wrong during flashing?
One of the sticky threads here mentions this right at the beginning:
Before you do anything EVER, you'll always have to backup your stuff, even if you don't feel like it, or your dog died (in which case I'm truly sorry), but, no matter what you're about to do, always have a recent backup sitting around.
There are many ways and things you can and will probably have to backup.
1. Backup your entire phone, by creating a Nandroid Backup.
As you saw in the 'Custom Recovery" picture above, you have a "Backup and Restore" option.
Click to expand...
Click to collapse
But it doesn't make any sense. "Before I do anything", I can't even create the NANDROID backup to begin with, because the bootloader is not unlocked by default, and unlocking it will wipe everything on the device. So I don't get how the first step to put a ROM on a phone is to create a NANDROID backup, because from my understanding, it is not possible to do. Also, my Nexus 4 did not come with a "custom recovery" installed and I have no idea how to put this on there (do i do this before or after the NANDROID backup?). I'm really starting to wonder how anyone actually understands these guides.
jb91 said:
This is extremely confusing, I have no idea how people can say it is simple to put a custom ROM on a Nexus device. I am absolutely lost trying to back up everything. Is a NANDROID backup just a full backup of the phone? Am I not completely screwed if I can't create this? I have some random app files, extracted from a Root Toolkit, and a contacts file. I don't think that's enough to save my device in case anything goes wrong during flashing?
One of the sticky threads here mentions this right at the beginning:
But it doesn't make any sense. "Before I do anything", I can't even create the NANDROID backup to begin with, because the bootloader is not unlocked by default, and unlocking it will wipe everything on the device. So I don't get how the first step to put a ROM on a phone is to create a NANDROID backup, because from my understanding, it is not possible to do. Also, my Nexus 4 did not come with a "custom recovery" installed and I have no idea how to put this on there (do i do this before or after the NANDROID backup?). I'm really starting to wonder how anyone actually understands these guides.
Click to expand...
Click to collapse
Following the link to the guide, I see this:
*****
Unlocking the Bootloader:
***NOTE***
This will perform a factory reset on your device. You will lose all applications. Even the data on your SD Card! I'd recommend making a Backup to your computer BEFORE performing this. There is a method for backing your data up, detailed HERE.
For the time being, there is a method available that will allow you to unlock your device (and root it) without losing your data.
For instructions, click HERE. Please note: this is a hack and isn't the "conventional" and "accepted" way of unlocking your bootloader on a nexus device. The wipe requirement is there for your safety, really, and I'm certain this will be patched in the upcoming releases.
*****
But you can always use adb directly from your pc to backup your entire device. How? adb --help
adb backup [-f <file>] [-apk|-noapk] [-obb|-noobb] [-shared|-noshared] [-all] [-system|-nosystem] [<packages...>]
- write an archive of the device's data to <file>.
If no -f option is supplied then the data is written
to "backup.ab" in the current directory.
(-apk|-noapk enable/disable backup of the .apks themselves
in the archive; the default is noapk.)
(-obb|-noobb enable/disable backup of any installed apk expansion
(aka .obb) files associated with each application; the default
is noobb.)
(-shared|-noshared enable/disable backup of the device's
shared storage / SD card contents; the default is noshared.)
(-all means to back up all installed applications)
(-system|-nosystem toggles whether -all automatically includes
system applications; the default is to include system apps)
(<packages...> is the list of applications to be backed up. If
the -all or -shared flags are passed, then the package
list is optional. Applications explicitly given on the
command line will be included even if -nosystem would
ordinarily cause them to be omitted.)
greg17477 said:
But you can always use adb directly from your pc to backup your entire device. How? adb --help
adb backup [-f <file>] [-apk|-noapk] [-obb|-noobb] [-shared|-noshared] [-all] [-system|-nosystem] [<packages...>]
- write an archive of the device's data to <file>.
If no -f option is supplied then the data is written
to "backup.ab" in the current directory.
(-apk|-noapk enable/disable backup of the .apks themselves
in the archive; the default is noapk.)
(-obb|-noobb enable/disable backup of any installed apk expansion
(aka .obb) files associated with each application; the default
is noobb.)
(-shared|-noshared enable/disable backup of the device's
shared storage / SD card contents; the default is noshared.)
(-all means to back up all installed applications)
(-system|-nosystem toggles whether -all automatically includes
system applications; the default is to include system apps)
(<packages...> is the list of applications to be backed up. If
the -all or -shared flags are passed, then the package
list is optional. Applications explicitly given on the
command line will be included even if -nosystem would
ordinarily cause them to be omitted.)
Click to expand...
Click to collapse
Is ADB this "Android Studio" that I had to install in the first step of this guide (Android SDK)? If so, I opened it but I have no clue how to get anywhere where i could enter code like this. This is what it looks like: http://i.imgur.com/zhujSKR.png
jb91 said:
Is ADB this "Android Studio" that I had to install in the first step of this guide (Android SDK)? If so, I opened it but I have no clue how to get anywhere where i could enter code like this. This is what it looks like: http://i.imgur.com/zhujSKR.png
Click to expand...
Click to collapse
Sorry, i can not help you , if you do not know the basic of basics Lots to read up for you.
cheers
Well ok, lets try it another way: i don't understand how to create a full backup, but i did backup some single apps to my PC using Nexus Root Toolkit (they're .ab files), for which i want to keep my data. I also manually backed up my mp3s and pictures / videos. Would i be fine just starting with the actual process (unlocking bootloader, install custom recovery and so on)?
After all, i should have the possibility to revert anything back for these apps at least, and the official Nexus 4 Stock Android files are available at Google. So, there's no real risk, even without a FULL backup of everything, correct?
Recently when i restored my data using TWRP i faced a problem at lock screen.
I was not able to unlock my phone with the pin i set Earlier..So after so many attempts i was able to find a solution for that problem.(works with pattern,pin etc)
Requirements
-----------------
1. A phone That cant be unlocked witha your Pin/Pattern
2.Any custom recovery installed(TWRP i will say)..Get TWRP from https://twrp.me/Devices/
Steps
-------
1.Once You installed twrp boot into recovery mode.
2.Go to advanced>filemanager to acces the files in your phone.
3.Ggo to the /data/system folder. Scroll down and find the two files with the .key extension. Delete both of them (by tapping on the file and then tapping the �Delete� button). Then, delete all the files containing the word locksettings.
password.key
pattern.key
locksettings.db
locksettings.db-shm
locksettings.db-wal
Once you�ve deleted all the key and locksettings files, reboot your system. If it asks you to install SuperSU, choose �Do Not Install�.
Once Android starts, your lock screen should appear, with no PIN or password prompt. Unlock your phone (yay!) and head to Android�s Settings. Scroll down and go to Security > Screen Lock. From there, you can choose a new PIN or password to lock your phone.
Hope this helped you..Hot Thanks if this was helpful
I have created recovery flashable zip for this issue.
SG3 said:
I have created recovery flashable zip for this issue.
Click to expand...
Click to collapse
Well done bro ?
Thanks dude, you save my data with very simple trick....
no TRW installed
I am not sure whether TRW is installed in my phone. It's in locked state now. What else can be done ? I do not want to lose the data (photos). Some important photos are there. I have Redmi Y2 phone and it's pattern locked. I forgot the pattern. please help.
Well in my case, the file i deleted named "locksetting.db" in /data/system
thank you so so much its so helpful
I am also facing same issue. Did you get any solution ?
Thanks
LABM said:
I am not sure whether TRW is installed in my phone. It's in locked state now. What else can be done ? I do not want to lose the data (photos). Some important photos are there. I have Redmi Y2 phone and it's pattern locked. I forgot the pattern. please help.
Click to expand...
Click to collapse
Hi!
This is post is after the release of TWRP 3.3.0-0.
All of the rooting guides that I have found that are related to the Magisk method call for using a "no-verity..." zip file before doing much else. I have read that this is due to a decryption action that is needed, but that TWRP is now able to handle whatever that zip file was working around (data from posts by @googJuju, @Wolfcity and @jhs39), but it wasn't definitive, to me.
Question 1: Is the "no-verity..." action now just an option taken based on personal preference?
Question 2: In other words, is it required for root or successfully restoring backups?
A lot of the posts describing the steps are a couple of years old and reference using earlier versions of TWRP and running Nougat, and they include warnings about encryption or decryption and other conditions. Some posts make no mention of these.
BTW, I used "fastboot boot twrp.img" to do a temporary TWRP load. I selected the "Keep Read-Only" option when asked about "Allow System modifications"); I did this action with TWRP in order to create backups.
The backups that I made are these: 1) "System/Data/Boot", 2) "EFS/Persist", 3) "System Image" and 4) "Boot/Recovery"). Based on what I've read, those are the main ones to make sure exist; all are on a MicroSD card.
Any help will be greeted with big smiles, including opinion about "Did I make the right backups?"
Don't ask me how, but I somehow set pattern and forgot it in one hour. I use face rec. as well but after reboot I need to unlock with pattern.
For last 10h I tried all methods how to unlock phone, but no success.
I'm using original, ROM, my G6 model is H870, running Pie, unlocked bootloader, so I can use TWRP. I spent most of my time and knowledge to unlock phone with adb/twrp. Best option I found is to delete gesture.key file which is located under /data/system.
Problem is, that /data is encrypted ...
Is there anyone who managed to remove pattern/lock without loosing data?
Thank you for your time!
akulp said:
Don't ask me how, but I somehow set pattern and forgot it in one hour. I use face rec. as well but after reboot I need to unlock with pattern.
For last 10h I tried all methods how to unlock phone, but no success.
I'm using original, ROM, my G6 model is H870, running Pie, unlocked bootloader, so I can use TWRP. I spent most of my time and knowledge to unlock phone with adb/twrp. Best option I found is to delete gesture.key file which is located under /data/system.
Problem is, that /data is encrypted ...
Is there anyone who managed to remove pattern/lock without loosing data?
Thank you for your time!
Click to expand...
Click to collapse
Maybe this will work: https://************/delete-android-security-pin/
Edit: link gets truncated... Just search 'Remove pin twrp' on Google and click the first result.
krilok said:
Maybe this will work: https://************/delete-android-security-pin/
Edit: link gets truncated... Just search 'Remove pin twrp' on Google and click the first result.
Click to expand...
Click to collapse
Non of this solutions work.
This is pretty the same as I said. My problem is that /data is encrypted and I can't find/see any .key files.
Also I can't do "su" command inside adb shell because of "insuff. privileges" ...
I tried all this solutions:
https://forum.xda-developers.com/showthread.php?p=49666433#post49666433
For method 1 -5 there is a problem with .key files which are not seen to my TWRP/Aroma browser. I don't know If I'm doing anything wrong in method 7, but also after mount I can't access /data/system (/data is empty).
In method 6 I'm stucked on
"Run pull settings.db.cmd inside By-pass security Hacks folder to pull out the setting file out of your phone." step.
I get "insuff. privileges" error.
akulp said:
Non of this solutions work.
This is pretty the same as I said. My problem is that /data is encrypted and I can't find/see any .key files.
Also I can't do "su" command inside adb shell because of "insuff. privileges" ...
I tried all this solutions:
https://forum.xda-developers.com/showthread.php?p=49666433#post49666433
For method 1 -5 there is a problem with .key files which are not seen to my TWRP/Aroma browser. I don't know If I'm doing anything wrong in method 7, but also after mount I can't access /data/system (/data is empty).
In method 6 I'm stucked on
"Run pull settings.db.cmd inside By-pass security Hacks folder to pull out the setting file out of your phone." step.
I get "insuff. privileges" error.
Click to expand...
Click to collapse
Have you tried this?
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008
Basically, the files you have to delete in the /data/system folder in TWRP are:
password.key
pattern.key
locksettings.db
locksettings.db-shm
locksettings.db-wal
It happened to me a while ago and I didn't have any '.key' files either; I just deleted the rest and when I booted up, I had no lock screen security PIN nor registered fingerprints but could re-set them again through security settings. I didn't need to flash any files nor fiddle around with adb commands, and all my data remained untouched...
If you can't find all those five files or the '.key' files, just delete the ones you can find and it should work. Otherwise, you'll probably have to do a full reset and reinstall...
krilok said:
Have you tried this?
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008
Basically, the files you have to delete in the /data/system folder in TWRP are:
password.key
pattern.key
locksettings.db
locksettings.db-shm
locksettings.db-wal
It happened to me a while ago and I didn't have any '.key' files either; I just deleted the rest and when I booted up, I had no lock screen security PIN nor registered fingerprints but could re-set them again through security settings. I didn't need to flash any files nor fiddle around with adb commands, and all my data remained untouched...
If you can't find all those five files or the '.key' files, just delete the ones you can find and it should work. Otherwise, you'll probably have to do a full reset and reinstall...
Click to expand...
Click to collapse
Problem is, that I don't have any files/folders at all in my /data. I even don't see system folder inside data.
akulp said:
Problem is, that I don't have any files/folders at all in my /data. I even don't see system folder inside data.
Click to expand...
Click to collapse
Sounds like your data folder is not mounted when you boot to TWRP... Have you checked? Reboot to TWRP, select the Mount option; data should be ticked by default. It it isn't, select it, go back to TWRP file manager, and see if you can now browse folders and files...
krilok said:
Sounds like your data folder is not mounted when you boot to TWRP... Have you checked? Reboot to TWRP, select the Mount option; data should be ticked by default. It it isn't, select it, go back to TWRP file manager, and see if you can now browse folders and files...
Click to expand...
Click to collapse
Unfortunately it's checked ... It's seems from this post:
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008/page12
nobody managed to get to (encrypted) /data on Pie.
akulp said:
Unfortunately it's checked ... It's seems from this post:
https://forum.xda-developers.com/android/software-hacking/remove-lockscreen-recovery-t3530008/page12
nobody managed to get to (encrypted) /data on Pie.
Click to expand...
Click to collapse
Last comment on that thread says the solution also works on Havoc Os 2.9, which is based on Pie... Maybe that person wasn't encrypted to begin with, but, if it doesn't work for you, I guess then the only way to go is a full reset... Good luck!
krilok said:
Last comment on that thread says the solution also works on Havoc Os 2.9, which is based on Pie... Maybe that person wasn't encrypted to begin with, but, if it doesn't work for you, I guess then the only way to go is a full reset... Good luck!
Click to expand...
Click to collapse
Yep, I saw that post ... I relly don't have any more ideas. Should be inside "mount modul" in TWRP /data listed?
I only have System, Cache and SD ... and i can check System only if i check bottom "mount system partition read-only" option.
But that's nothing to do with /data.
akulp said:
Yep, I saw that post ... I relly don't have any more ideas. Should be inside "mount modul" in TWRP /data listed?
I only have System, Cache and SD ... and i can check System only if i check bottom "mount system partition read-only" option.
But that's nothing to do with /data.
Click to expand...
Click to collapse
Data option should show. At least it does on mine... You can maybe try updating Twrp version?
I'm on last TWRP.... Meantime I already made full reset ....
If you have encrypted data partition, you're pretty much banned from messing with it, unless you manage to exploit your way through the adb, which requires you to have it enabled and in trust relation with your PC to begin with.
The way I'd go around this is to place an "always yes su" binary and perform pattern removal process through init.d or similar solution. In case if su commands are restricted, kernel with permissive SELinux needs to be flashed.
On a side note, isn't this Q&A?
I also had a problem with data folder not being mounted when booting to TWRP. I tried a full reset and immediately i have access to the Data folder (but theres nothing left inside so this is kinda useless). Then later when i did a reboot into the TWRP it happened again, couldnt access to anything even when the "mount Data" option is ticked, only until i did the full reset again that it could finally work.
It turned out the problem is with the TWRP itself, i flashed another custom recovery (OrangeFox-R10-Stable-h870, which is btw a better recovery than TWRP in my opinion) and the problem never occurred again.
So either try out that new Recovery or a different version of TWRP and see if it solves the problem. And always, ALWAYS, make a full backup of all your data before messing with anything (i had to learn that the hard way so trust me).
Do this,
- you should know that I am using "orange fox recovery" not "twrp",and stock "pie"
- reboot to recovery and go to system/data
- delete this files:
gatekeeper.password.key
gatekeeper.pattern.key
locksettings.db
-reboot the phone and that's it.
Dear Dev's plz help me.
Patterns connects only 2 dots and remaining two dots connect separately one by one.
Then I've to delete data/system/lock screen file from twrp. Any solution without restoring modem ? Or any other solution you have? Please share here.
Thanksgiving
Simply boot into TWRP and enter your PIN (if you've set one) to decrypt the stroage. If you don't have TWRP (for whatever reason) you can do so via ADB too but ONLY if you've connected your phone to your PC beforehand and also accepted it's fingerprint on the phone itself.
Delete (or rename) the following files inside /data/system (note that probably not all of them exist for you, simply delete those you can find):
password.key
pattern.key
locksettings.db-wal
locksettings.db-shm
locksettings.db
Reboot the phone and (if you've set a PIN) enter it to decrypt the storage one more time. After that you can simply unlock your phone with a swipe.
Go into Settings > Security and set your preferred unlock method again, Android will ask you if you want to set a boot-time code too. Select whatever you want here, it's a nice security addition but can be annoying sometimes.
Enjoy your phone again!