How to disable encryption? - Moto Z Play Questions & Answers

Hi, I'm wondering if anyone knows how to disable force encryption? I know we have to unpack and edit boot.img, but so far I've only come with tools for the linux environment. And I'm on Windows, so just wondering if anyone knows the steps. Or also would be great if someone has already done it, and can just share the boot.img modified. Thanks in advance.

boot into twrp,Advance - Disable force encryption, when it done, select Root system,and go back to first menu,select Wipe - Format Data,swipe down,tap 'yes' to continue, and wait it finish, reboot to system~ have fun!
!!!remember backup your data!!!
forgive my bad english

yefonme said:
boot into twrp,Advance - Disable force encryption, when it done, select Root system,and go back to first menu,select Wipe - Format Data,swipe down,tap 'yes' to continue, and wait it finish, reboot to system~ have fun!
!!!remember backup your data!!!
forgive my bad english
Click to expand...
Click to collapse
there is no disable force encryption option in twrp. nor a root option.

fix-this! said:
there is no disable force encryption option in twrp. nor a root option.
Click to expand...
Click to collapse
There is in the chinese version of TWRP.

On twrp you can format data and that for me disabled encryption. I formatted data, reboot again on recovery and it was disabled.
Enviado de meu XT1635-02 usando Tapatalk

Related

[SCRIPT] (Depreciated) Wipe Encrypted Data Without Wiping Internal Storage

Update: The latest TWRP is already capable of decrypting data. This method is now unnecessary and depreciated. Use factory reset in TWRP menu instead
Disclaimer: This mod will wipe your data. I am not responsible for data loss after using this mod.
I tested on my device several times, it's working for me so internal storage is always preserved, but I cannot guarantee if anything is messed up on your side. Please read the post carefully before using this mod!
Always backup your important data before modifying your phone's software!
To compensate the mistake I have done in the modified SuperSU script (I fixed it eventually though ), I decided to release a mod I consider quite useful for most people.
I've used the 10 for quite some time, and I've been messing with it from day 1.
Since the encryption is required for the phone to have proper radio signal (more info here), we are forced to keep our devices encrypted.
And because HTC uses proprietary encryption method, TWRP is unable to decrypt our data partition, which causes the recovery unable to read anything from data.
This is actually quite a big problem. If you want to full wipe and clean flash your favorite custom rom, the "Factory Reset" option in TWRP is not available, so you are forced to wipe the whole data partition, which will cause all your personal files stored in internal storage to be removed.
If you're a flashaholic like I am, you are forced not to store anything important in the phone storage because it will be wiped every time trying to clean flash a rom.
To breakthrough this inconvenience, I created this flashable zip to accomplish something similar to the "Factory Reset" option in TWRP.
Requirement: You have to use the systemless root of SuperSU to use this mod. If you want to flash the wipe script with SuperSU, flash SuperSU first, then flash the wipe script.
Important: If you have chosen "Require PIN/password/pattern to start device" in the "Secure startup" page during the initial setup, you CANNOT use this mod!
If you have to enter your PIN/password/pattern before your device booted up, this means that you have secure startup enabled. You CANNOT use this mod!
If secure startup is enabled and you flash this zip, your encryption will be messed up and you will have to format the whole data partition eventually to make your phone working again.
After flashing the mod, your data will not be wiped immediately in recovery because we cannot do so. It will wipe the data AFTER you rebooted back to system. It will reboot again after the wipe is done. If you flashed SuperSU at the same time with this mod, you will experience 2 consecutive reboot loops. This is normal behavior, don't panic.
If devs are interested in including this zip into your rom, you can use it in the same way as SuperSU:
Code:
package_extract_dir("wipe", "/tmp/wipe");
run_program("/sbin/busybox", "unzip", "/tmp/wipe/wipe.zip", "META-INF/com/google/android/*", "-d", "/tmp/wipe");
run_program("/sbin/busybox", "sh", "/tmp/wipe/META-INF/com/google/android/update-binary", "dummy", "1", "/tmp/wipe/wipe.zip");
For those who are interested in what this zip actually do, here is a brief explanation:
If secure startup is disabled, data will be decrypted as soon as the device booted up. We can only access data after it is decrypted. So our only choice is to wipe data after the device has booted up.
I created a script to wipe all data except SuperSU app, su binary image, and your internal storage.
SuperSU will automatically run scripts inside the directory /su/su.d, so after putting the script into the folder, SuperSU will the wipe script at boot time.
The problem is: su.img is also located in /data, how can we push files into the image? Fortunately, our master Chainfire has thought of this problem. The image /cache/su.img will be merged with /data/su.img during boot. So I just need to place the script into /cache/su.img, then Chainfire's script will do all the rest of the work automatically. If you're interested in the merging process, take a look at launch_daemonsu.sh in the ramdisk of a SuperSU modified boot for more details.
Is this helpful in regards to initial routing and flashing a rom or only afterwards to flash a new one?
topjohnwu said:
Disclaimer: This mod will wipe your data. I am not responsible for data loss after using this mod.
I tested on my device several times, it's working for me so internal storage is always preserved, but I cannot guarantee if anything is messed up on your side. Please read the post carefully before using this mod!
Always backup your important data before modifying your phone's software!
To compensate the mistake I have done in the modified SuperSU script (I fixed it eventually though ), I decided to release a mod I consider quite useful for most people.
I've used the 10 for quite some time, and I've been messing with it from day 1.
Since the encryption is required for the phone to have proper radio signal (more info here), we are forced to keep our devices encrypted.
And because HTC uses proprietary encryption method, TWRP is unable to decrypt our data partition, which causes the recovery unable to read anything from data.
This is actually quite a big problem. If you want to full wipe and clean flash your favorite custom rom, the "Factory Reset" option in TWRP is not available, so you are forced to wipe the whole data partition, which will cause all your personal files stored in internal storage to be removed.
If you're a flashaholic like I am, you are forced not to store anything important in the phone storage because it will be wiped every time trying to clean flash a rom.
To breakthrough this inconvenience, I created this flashable zip to accomplish something similar to the "Factory Reset" option in TWRP.
Requirement: You have to use the systemless root of SuperSU to use this mod. If you want to flash the wipe script with SuperSU, flash SuperSU first, then flash the wipe script.
Important: If you have chosen "Require PIN/password/pattern to start device" in the "Secure startup" page during the initial setup, you CANNOT use this mod!
If you have to enter your PIN/password/pattern before your device booted up, this means that you have secure startup enabled. You CANNOT use this mod!
If secure startup is enabled and you flash this zip, your encryption will be messed up and you will have to format the whole data partition eventually to make your phone working again.
After flashing the mod, your data will not be wiped immediately in recovery because we cannot do so. It will wipe the data AFTER you rebooted back to system. It will reboot again after the wipe is done. If you flashed SuperSU at the same time with this mod, you will experience 2 consecutive reboot loops. This is normal behavior, don't panic.
If devs are interested in including this zip into your rom, you can use it in the same way as SuperSU:
Code:
package_extract_dir("wipe", "/tmp/wipe");
run_program("/sbin/busybox", "unzip", "/tmp/wipe/wipe.zip", "META-INF/com/google/android/*", "-d", "/tmp/wipe");
run_program("/sbin/busybox", "sh", "/tmp/wipe/META-INF/com/google/android/update-binary", "dummy", "1", "/tmp/wipe/wipe.zip");
For those who are interested in what this zip actually do, here is a brief explanation:
If secure startup is disabled, data will be decrypted as soon as the device booted up. We can only access data after it is decrypted. So our only choice is to wipe data after the device has booted up.
I created a script to wipe all data except SuperSU app, su binary image, and your internal storage.
SuperSU will automatically run scripts inside the directory /su/su.d, so after putting the script into the folder, SuperSU will the wipe script at boot time.
The problem is: su.img is also located in /data, how can we push files into the image? Fortunately, our master Chainfire has thought of this problem. The image /cache/su.img will be merged with /data/su.img during boot. So I just need to place the script into /cache/su.img, then Chainfire's script will do all the rest of the work automatically. If you're interested in the merging process, take a look at launch_daemonsu.sh in the ramdisk of a SuperSU modified boot for more details.
Click to expand...
Click to collapse
Is the systemless one the one you patched?
Sent from my LG-H830 using XDA-Developers mobile app
stonew5082 said:
Is this helpful in regards to initial routing and flashing a rom or only afterwards to flash a new one?
Click to expand...
Click to collapse
It functions the same as "Factory Reset" in TWRP, which means it will wipe all data, but your personal files stored in internal storage will remain on the device.
StickyEyez said:
Is the systemless one the one you patched?
Sent from my LG-H830 using XDA-Developers mobile app
Click to expand...
Click to collapse
Actually you can use the original version. But I suggest you to use my patched one, in case you accidentally wiped your whole data partition (this mod will not do this), you will stay encrypted, and your data signal will be fine
Hi topjohnwu
@ jollywhitefoot suggested you might be able to help to wipe userdata from download mode.
My phone will not get passed message "Your phones is encrypted" "TO DECRYPT YOUR PHONE. ENTER YOUR SCREEN LOCK PASSWORD" I had no screen lock password... i have different passwords to decrypt . Each time i put a password in it resest phone and does factory rest and then reboots straight into Bootloader again.
Phone has no recovery " Failed to boot into recovery mode" red writing on a black screen.
Phoned has OEM Relocked ....cant fastboot or unlock bootloader again
Please can you help
tailor999 said:
Hi topjohnwu
@ jollywhitefoot suggested you might be able to help to wipe userdata from download mode.
My phone will not get passed message "Your phones is encrypted" "TO DECRYPT YOUR PHONE. ENTER YOUR SCREEN LOCK PASSWORD" I had no screen lock password... i have different passwords to decrypt . Each time i put a password in it resest phone and does factory rest and then reboots straight into Bootloader again.
Phone has no recovery " Failed to boot into recovery mode" red writing on a black screen.
Phoned has OEM Relocked ....cant fastboot or unlock bootloader again
Please can you help
Click to expand...
Click to collapse
You can try to unlock your bootloader again.
If you cannot unlock it, then I regret to say that your phone might be doomed.
Never try to relock your phone if it's not in 100% stock condition and perfectly working.
topjohnwu said:
You can try to unlock your bootloader again.
If you cannot unlock it, then I regret to say that your phone might be doomed.
Never try to relock your phone if it's not in 100% stock condition and perfectly working.
Click to expand...
Click to collapse
I have tried unlocking boot loader again. The log shows oem needs to be unlocked.
When a RUU comes out, would that help recover the phone?
Sent from my ONE A2003 using XDA-Developers mobile app
tailor999 said:
Hi topjohnwu
@ jollywhitefoot suggested you might be able to help to wipe userdata from download mode.
My phone will not get passed message "Your phones is encrypted" "TO DECRYPT YOUR PHONE. ENTER YOUR SCREEN LOCK PASSWORD" I had no screen lock password... i have different passwords to decrypt . Each time i put a password in it resest phone and does factory rest and then reboots straight into Bootloader again.
Phone has no recovery " Failed to boot into recovery mode" red writing on a black screen.
Phoned has OEM Relocked ....cant fastboot or unlock bootloader again
Please can you help
Click to expand...
Click to collapse
Assuming you have a stock recovery image..
Boot to bootloader then recovery.
Long press power for a few seconds then tap volume up.
You can then factory reset in stock recovery
LeeDroid said:
Assuming you have a stock recovery image..
Boot to bootloader then recovery.
Long press power for a few seconds then tap volume up.
You can then factory reset in stock recovery
Click to expand...
Click to collapse
Oh dam it, just seen your post a bit late. Car phone warehouse has just collected my handset :silly: - im sure they'll send it back saying ive lost warranty :crying:
tailor999 said:
Oh dam it, just seen your post a bit late. Car phone warehouse has just collected my handset :silly: - im sure they'll send it back saying ive lost warranty :crying:
Click to expand...
Click to collapse
Oh dear....
topjohnwu said:
Requirement: You have to use the systemless root of SuperSU to use this mod. If you want to flash the wipe script with SuperSU, flash SuperSU first, then flash the wipe script.
Important: If you have chosen "Require PIN/password/pattern to start device" in the "Secure startup" page during the initial setup, you CANNOT use this mod!
If you have to enter your PIN/password/pattern before your device booted up, this means that you have secure startup enabled. You CANNOT use this mod!
If secure startup is enabled and you flash this zip, your encryption will be messed up and you will have to format the whole data partition eventually to make your phone working again.
Click to expand...
Click to collapse
the thing is i have selected no for secure boot but whenever i setup a fingerprint and boot then it gets enabled again even if i had disabled it...
any way around or am i missing on something.. currently on lee's rom
SacredDeviL666 said:
the thing is i have selected no for secure boot but whenever i setup a fingerprint and boot then it gets enabled again even if i had disabled it...
any way around or am i missing on something.. currently on lee's rom
Click to expand...
Click to collapse
you're talking about something different that he is. secure boot is a pin before you ever get the system loaded. you are talking about lockscreen pin/password, which, is mandatory if you use fingerprint scanner.
jollywhitefoot said:
you're talking about something different that he is. secure boot is a pin before you ever get the system loaded. you are talking about lockscreen pin/password, which, is mandatory if you use fingerprint scanner.
Click to expand...
Click to collapse
cool thank you...
I'm confused a bit. So every time I want to clean flash a rom, I can flash this script and it will wipe everything (system, data, cache etc.) except internal storage? Would dirty flashing a rom have any affect?
Ndaoud360 said:
I'm confused a bit. So every time I want to clean flash a rom, I can flash this script and it will wipe everything (system, data, cache etc.) except internal storage? Would dirty flashing a rom have any affect?
Click to expand...
Click to collapse
+1
Ndaoud360 said:
I'm confused a bit. So every time I want to clean flash a rom, I can flash this script and it will wipe everything (system, data, cache etc.) except internal storage? Would dirty flashing a rom have any affect?
Click to expand...
Click to collapse
It will only wipe data without internal storage.
You should flash this zip after you flash a rom.
It will wipe data after the device boots up.
topjohnwu said:
It will only wipe data without internal storage.
You should flash this zip after you flash a rom.
It will wipe data after the device boots up.
Click to expand...
Click to collapse
Ok so the process would be wipe system, cache, flash rom, flash data wipe script?
Ndaoud360 said:
Ok so the process would be wipe system, cache, flash rom, flash data wipe script?
Click to expand...
Click to collapse
Why would you wipe system this will be done by the rom installation, just flash the rom then flash the script & job done
LeeDroid said:
Why would you wipe system this will be done by the rom installation, just flash the rom then flash the script & job done
Click to expand...
Click to collapse
huh? Ever since I began rooting phones, I would wipe system, data and cache before a clean flash of a rom. I guess I never knew the rom does it for you. I thought the rom just over wrote the system possibly leaving remnants of the old system which could lead to issues which is why devs advise to full wipe when switching roms.
Ndaoud360 said:
huh? Ever since I began rooting phones, I would wipe system, data and cache before a clean flash of a rom. I guess I never knew the rom does it for you. I thought the rom just over wrote the system possibly leaving remnants of the old system which could lead to issues which is why devs advise to full wipe when switching roms.
Click to expand...
Click to collapse
Ah, a full wipe is only applicable to data buddy, if a rom dev doesn't wipe system before their installation, they need a good slap with a frozen kipper.
Cache is entirely optional

Can't root after latest firmware update :(

Hello guys, i have an a5 2k17(sm-a520f), i flashed the latest firmware for the phone after being stuck in a bootloop(ksa firmware)
And the problem is that i tried many root methods like cf auto root which after flashing it the phone asks me to factory reset (no other options after booting)
And the cf auto root package generated by firmware.mobi gives nothing (not working i guess)
Also tried to flash the twrp recovery and then flash the supersu zip file after and i get the same messege i that verification failed and i have to factory reset, any help or ideas please?
Thank you
ahmad_salahat said:
Hello guys, i have an a5 2k17(sm-a520f), i flashed the latest firmware for the phone after being stuck in a bootloop(ksa firmware)
And the problem is that i tried many root methods like cf auto root which after flashing it the phone asks me to factory reset (no other options after booting)
And the cf auto root package generated by firmware.mobi gives nothing (not working i guess)
Also tried to flash the twrp recovery and then flash the supersu zip file after and i get the same messege i that verification failed and i have to factory reset, any help or ideas please?
Thank you
Click to expand...
Click to collapse
Have you used Odin?
moozer said:
Have you used Odin?
Click to expand...
Click to collapse
Yes of course :3
ahmad_salahat said:
Yes of course :3
Click to expand...
Click to collapse
Did you format data after flashing TWRP and then flash the Ashyx patch?
moozer said:
Did you format data after flashing TWRP and then flash the Ashyx patch?
Click to expand...
Click to collapse
Can't format data from twrp, because /data can't be mounted
ahmad_salahat said:
Can't format data from twrp, because /data can't be mounted
Click to expand...
Click to collapse
It's fine. You can. Your data has become encrypted.
Go here and download the patch : https://www.androidfilehost.com/?fid=24591000424951049
Save it to your external SD card
1. Enter recover
2. Format Data partition (Note: This will wipe the internal storage and ALL data contained within)
go to "Wipe" - tap "Format Data" button - type the word "yes" (without quotes) - tap the tick - go back to main screen​3. Check DATA is mountable.
go to Mount and check it is selected. Back tio mauin screen.​4. Flash root (Magisk or SU)
5. Flash boot image patch above.
6. Reboot into recovery
7. Flash your ROM and GAPPS. Have fun
moozer said:
It's fine. You can. Your data has become encrypted.
Go here and download the patch : https://www.androidfilehost.com/?fid=24591000424951049
Save it to your external SD card
1. Enter recover
2. Format Data partition (Note: This will wipe the internal storage and ALL data contained within)
go to "Wipe" - tap "Format Data" button - type the word "yes" (without quotes) - tap the tick - go back to main screen
3. Check DATA is mountable.
go to Mount and check it is selected. Back tio mauin screen.
4. Flash root (Magisk or SU)
5. Flash boot image patch above.
6. Reboot into recovery
7. Flash your ROM and GAPPS. Have fun
Click to expand...
Click to collapse
Thanks will try it tomorrow after i backup my data
ahmad_salahat said:
Thanks will try it tomorrow after i backup my data
Click to expand...
Click to collapse
How did you get on?
I has same problem. After update laters firmware patch date november. My phone can't flash custom recovery. Odin failed
Dr. Phone said:
I has same problem. After update laters firmware patch date november. My phone can't flash custom recovery. Odin failed
Click to expand...
Click to collapse
Do you have Developer Options enabled in settings?
Yes. OEM, USB has tick. But same problem
Dr. Phone said:
Yes. OEM, USB has tick. But same problem
Click to expand...
Click to collapse
Can you boot into TWRP?
Flash latest firmware then wait for the blue android screen that says installing updates etc etc...
After that screen immedietly boot into download mode and flash twrp then restart and again immedietly boot into twrp
---------- Post added at 02:52 PM ---------- Previous post was at 02:50 PM ----------
Just dont let phone boot into android
With this trick you should get /data decrypted so no needed to wipe and not need for no verity no encrypt patch because it lags your phone
ChARCOOL said:
Flash latest firmware then wait for the blue android screen that says installing updates etc etc...
After that screen immedietly boot into download mode and flash twrp then restart and again immedietly boot into twrp
---------- Post added at 02:52 PM ---------- Previous post was at 02:50 PM ----------
Just dont let phone boot into android
With this trick you should get /data decrypted so no needed to wipe and not need for no verity no encrypt patch because it lags your phone
Click to expand...
Click to collapse
Lags?
No verity no encrypt slowes your phone and it causes lock screen lag
ChARCOOL said:
No verity no encrypt slowes your phone and it causes lock screen lag
Click to expand...
Click to collapse
Erm...no it doesn't
---------- Post added at 20:07 ---------- Previous post was at 19:56 ----------
ChARCOOL said:
No verity no encrypt slowes your phone and it causes lock screen lag
Click to expand...
Click to collapse
Oh...hang on. Is it laggy on pin lock? That's different. I don't have that enabled on my device and just use swipe.
I don't have any lags or micro lags on my device at all and have flashed the zip.
It lags with no verity no encrypt
ChARCOOL said:
It lags with no verity no encrypt
Click to expand...
Click to collapse
HIGHLY unlikely considering it is encryption itself which causes lag. An unencrypted device isn't going to introduce lag.
It is more likely root has caused the issue.
ashyx said:
HIGHLY unlikely considering it is encryption itself which causes lag. An unencrypted device isn't going to introduce lag.
It is more likely root has caused the issue.
Click to expand...
Click to collapse
I was using your patch before I found this trick and it was lagging in lock screen with the patch and magisk.
After that I tried supersu still lags in lock screen. (because it's unencrypting phone like your patch)
Then i tried only magisk without any verity disabled force encrypt disabled patch.
And bum! no lock screen lags no verity error.
I have the same problem. I stitched A520FXXU2BQK1 firmware. (latest). After that The vendor disabled recovery. And now it is impossible to stitch others. For this reason I cannot stitch Twrp, Cwm and root.
Recovery msg : Only official released binar ies are allowed to be flashed (RECOVERY)
I also tried to stitch the previous firmwares to return root and twrp.. It did not help. I tried to return on the android 6 - he is not stitched

I need root on oreo 8.1 stock OTA

Hi, yesterday i've got OTA on stock rom, i reflash stock because i was rooted before, and after succesfully update, i tried to flash no verity from twrp 3.2.3.0 and magisk. I booted ok, the root is present, everything is fine but the phone is encrypted. I knew that no verity decrypt the phone but for me doesnt. Somebody knows or tried to root oreo stock? Thank you
To start with flashing magisk should mean you don't need to flash the no verity zip
Also only the official twrp from my thread will support encryption
Also if you change roms you must format data to remove encryption else the phone will boot to the encryption screen & will tell you the password is wrong
You can either format data in twrp - wipe format data (not advanced wipe. The option to the right of advanced wipe)
Or in fastboot enter the command
fastboot erase userdata
Note this will format everything on internal storage
Once you have booted the new rom you can encrypt again
I have official twrp 3.2.3.0, the phone is encrypted and rooted, but i want to be decrypted and i can't do that. I formated all phone, all data, in magisk appear checked preserved encryption.
I don't want to change rom, I only want stock and root, but not encryption
woozie.2007 said:
I don't want to change rom, I only want stock and root, but not encryption
Click to expand...
Click to collapse
If it was previously encrypted you still need to format data
This will remove encryption and everything on internal storage will be deleted
Then it should just be a case of flashing the latest version of Magisk
I don't have this device so I can't test it
The stock kernel may require forced encryption so you may not have a choice with stock but I can't check that
I just update ota 8.1, after that i flashed twrp via fastboot, then magisk 15.3. latest magisk didnt work, but i tried to flash no verity but the encryption still there even i formated all data and i configured the phone from zero
woozie.2007 said:
I just update ota 8.1, after that i flashed twrp via fastboot, then magisk 15.3. latest magisk didnt work, but i tried to flash no verity but the encryption still there even i formated all data and i configured the phone from zero
Click to expand...
Click to collapse
If you formatted data in twrp
Wipe - select option on right
Or
Format data as a different partition type then format it back to what it was
Will remove encryption
Also
fastboot erase userdata
Should do the same
You should get no prompt to enter decrypt key as device should no longer be encrypted
TheFixItMan said:
If you formatted data in twrp
Wipe - select option on right
Or
Format data as a different partition type then format it back to what it was
Will remove encryption
Also
fastboot erase userdata
Should do the same
You should get no prompt to enter decrypt key as device should no longer be encrypted
Click to expand...
Click to collapse
doesn't work...
woozie.2007 said:
doesn't work...
Click to expand...
Click to collapse
Without your device I can only put it down to user error as that's how I've always removed encryption
TheFixItMan said:
Without your device I can only put it down to user error as that's how I've always removed encryption
Click to expand...
Click to collapse
i know and i understand, i do it for many times on nougat, but now on oreo doesnt works, anyway thank you for help me
So, every method i tried i didnt succeed to make the phone unencrypted. I root it with magisk 17.1, in play store appears to be not certified. Is any problem? I mention before with 7.0 and magisk the phone was certified. Sugestions? Thanks
woozie.2007 said:
So, every method i tried i didnt succeed to make the phone unencrypted. I root it with magisk 17.1, in play store appears to be not certified. Is any problem? I mention before with 7.0 and magisk the phone was certified. Sugestions? Thanks
Click to expand...
Click to collapse
Change the device fingerprint
https://forum.xda-developers.com/apps/magisk/module-magiskhide-props-config-t3789228
Install above magisk module
In a terminal emulator (playstore) run the following
su
props
Select option to change fingerprint & change to a working moto g5 (or similar) fingerprint
Restart phone
Thank you sir, now appear certified in play, is still encrypted but rooted, i think is ok, right?

[Guide] How to Remove Device Encryption to Flash Custom ROMs

The Issue
The device does not allow to use the newly flashed Custom ROM as it is Encrypted thereby asking for Password every time the phone boots up and wiping Data Partition with a Custom Recovery also does not work.
The Solution
Step 1 - Type anything as Password when the device asks for it after booting up. Be Quick as the device will shut down if you don't type anything within a few seconds.
Step 2 - Check whether it says Decryption was successful but the data is corrupted and also instructs to do a factory reset by tapping the Reset button. If Yes then go to the next step as the subsequent steps will resolve the issue. If No then this guide can not help you.
Step 3 - Do not touch that Reset button and reboot the device to Recovery by long pressing the Power button and then pressing Power and Volume Down simultaneously and choosing to go to Recovery from the Fastboot/Bootloader Menu.
Step 4 - Now connect the phone to your PC and transfer everything from your internal storage (if you didn't do it before flashing the Custom ROM) using MTP as the next steps will wipe the internal storage. Eject your SD Card from the device.
Step 5 - Download the Platform Tools from the link : [url]https://drive.google.com/open?id=1LEcF5iAjRdno2_aPKv9DYdOYtviC5xB7[/URL] and after extracting the folder place it in the C drive.
Step 6 - Install Motorola Device Manager from the link : [url]https://drive.google.com/open?id=12k2joSx5G08oourGlYLdtLEdTuOC9CVb[/URL] on your PC.
Step 7 - Download the Stock Recovery from the link : [url]https://drive.google.com/file/d/1_gogMT_GgSvg6FKpe2q4Z51gh22ftUdt/view[/URL] and place it in the platform-tools folder.
Step 8 - Assuming that your phone is still connected to the PC go to the Fastboot/Bootloader menu on the device by using Reboot to Bootloader option from the Recovery.
Step 9 - Go to the platform-tools folder on the C drive of your PC and open a Command Prompt window there by holding Shift key while Right clicking on the mouse and choosing the option. Enter the command fastboot devices to ensure that your phone is connected to the PC.
Step 10 - Enter the command fastboot flash recovery recovery.img to flash the Stock Recovery on the phone.
Step 11 - Reboot the device and enter anything as Password when the device asks for it. Now tap the Reset button to do Factory Reset. The phone will reboot to Stock Recovery and ask you to perform Factory Reset. Choose Yes to proceed and it will take a few seconds to do so. Voila!!! Your phone is successfully Decrypted and now you can boot into the Custom ROM you flashed.
Step 12 - As the phone is already Decrypted there is no need to keep the Stock Recovery. You can flash the Custom Recovery of your choice by going to the proper website and following the instructions to flash it on your device.
N.B : It took me a couple of hours to figure out the solution to this issue when I faced it and I wrote this guide so that it will help people who face the same issue in future. A Thanks! is much appreciated .
I work with "format data" in twrp
kuzo said:
I work with "format data" in twrp
Click to expand...
Click to collapse
That didn't work in my case.
Otherwise it's the easiest way to do so.
I also do not work the "format data" the first time. you have to do it once and gives error, then restart , go to twrp and do it again and there if it works. and reinstall the rom again ... after that you can change rom normally
kuzo said:
I also do not work the "format data" the first time. you have to do it once and gives error, then restart , go to twrp and do it again and there if it works. and reinstall the rom again ... after that you can change rom normally
Click to expand...
Click to collapse
I did it at least four or five times and was unsuccessful.
The phone was only booting up normally with Stock ROM but always asked for Password if any custom ROM was flashed.
Then only I came up with the idea I posted here and was successful to remove the encryption.
data on the phone will not be deleted?
whitetornado said:
data on the phone will not be deleted?
Click to expand...
Click to collapse
Step 7: ". . . the next steps will wipe the internal storage. Eject your SD Card from the device."
You should expect that data will be deleted.
whitetornado said:
data on the phone will not be deleted?
Click to expand...
Click to collapse
Yes!
Step 10 will wipe the Internal Storage and the SD Card too if it is still in the device.
It's a safe practice to eject the SD Card before doing any operations.
Is this still required for Pie ROMs? I've unlocked my bootloader, installed TWRP and called it a day, didn't have to change anything, but I'm still on stock Oreo.
io_gh0st said:
Is this still required for Pie ROMs? I've unlocked my bootloader, installed TWRP and called it a day, didn't have to change anything, but I'm still on stock Oreo.
Click to expand...
Click to collapse
If you're still on stock and haven't flashed any custom ROMs in the past or decrypted your data by using the "format data" command in TWRP after unlocking the BL (like I did) your data partition should be still encrypted. Most custom ROMs, regardless if they're Oreo or Pie don't work with an encrypted data partition. If the developer of the ROM you'd like to flash doesn't recommend anything else you can decrypt by using the format data option in TWRP (the one you have to confirm with "yes") or maybe by following this guide, for me that was never necessary, you just may have to use "format data" twice to make it stick.
To prevent your system from re-encrypting you can flash magisk or use a disabled dm verity force encrypt zip:
https://yadi.sk/d/HLr5vjnkA8gaqw
This one can be found on
https://zackptg5.com/android.php
Sent from my Moto G5 Plus using XDA Labs
Wolfcity said:
If you're still on stock and haven't flashed any custom ROMs in the past or decrypted your data by using the "format data" command in TWRP after unlocking the BL (like I did) your data partition should be still encrypted.
Click to expand...
Click to collapse
The only time I've formatted /data was when I unlocked my bootloader. Immediately after this I've flashed TWRP, booted into it, installed magisk and restarted my device. It didn't asked for password or anything, this is why I'm confused. Since I haven't formatted using TWRP, it should be encrypted, right?
Wolfcity said:
Most custom ROMs, regardless if they're Oreo or Pie don't work with an encrypted data partition. If the developer of the ROM you'd like to flash doesn't recommend anything else you can decrypt by using the format data option in TWRP (the one you have to confirm with "yes") or maybe by following this guide, for me that was never necessary, you just may have to use "format data" twice to make it stick.
To prevent your system from re-encrypting you can flash magisk or use a disabled dm verity force encrypt zip:
https://yadi.sk/d/HLr5vjnkA8gaqw
This one can be found on
https://zackptg5.com/android.php
Sent from my Moto G5 Plus using XDA Labs
Click to expand...
Click to collapse
So since I installed magisk, then it shouldn't be encrypted, is that it? Sorry to sound soo noobish, but its been a while that I'm not flashing stuff and the last time I would just flash anything with no issues with encryption.
io_gh0st said:
The only time I've formatted /data was when I unlocked my bootloader. Immediately after this I've flashed TWRP, booted into it, installed magisk and restarted my device. It didn't asked for password or anything, this is why I'm confused. Since I haven't formatted using TWRP, it should be encrypted, right?
So since I installed magisk, then it shouldn't be encrypted, is that it? Sorry to sound soo noobish, but its been a while that I'm not flashing stuff and the last time I would just flash anything with no issues with encryption.
Click to expand...
Click to collapse
If you look into Settings->Security (see attached screenshots) what do you see there? (Mine is rooted and decrypted).
Edit: Check screenshots in the next post
Sent from my Moto G5 Plus using XDA Labs
Wolfcity said:
If you look into Settings->Security (see attached screenshots) what do you see there? (Mine is rooted and decrypted).
Click to expand...
Click to collapse
Sorry, wrong screenshots.
Sent from my Moto G5 Plus using XDA Labs
Wolfcity said:
If you look into Settings->Security (see attached screenshots) what do you see there? (Mine is rooted and decrypted).
Sent from my Moto G5 Plus using XDA Labs
Click to expand...
Click to collapse
It shows that my device is encrypted. So, to decrypt it, I have to wipe /data from TWRP, right? To make sure that it won't get encrypted again I have to wipe twice, or just flash the script you linked?
io_gh0st said:
It shows that my device is encrypted. So, to decrypt it, I have to wipe /data from TWRP, right? To make sure that it won't get encrypted again I have to wipe twice, or just flash the script you linked?
Click to expand...
Click to collapse
To decrypt it format/ data (not wipe, that's not enough, it's the option where you have to confirm with "yes"). As I did that I formatted data and after that flashed magisk. It doesn't work at first attempt so I went into TWRP and did it again.
Normally magisk should prevent your device from re - encrypting, if not flash the attached zip.
Sent from my Moto G5 Plus using XDA Labs
Wolfcity said:
To decrypt it format/ data (not wipe, that's not enough, it's the option where you have to confirm with "yes"). As I did that I formatted data and after that flashed magisk. It doesn't work at first attempt so I went into TWRP and did it again.
Normally magisk should prevent your device from re - encrypting, if not flash the attached zip.
Sent from my Moto G5 Plus using XDA Labs
Click to expand...
Click to collapse
By 'the attached zip' I believe you meant the one you've talked about a few posts ago?
io_gh0st said:
By 'the attached zip' I believe you meant the one you've talked about a few posts ago?
Click to expand...
Click to collapse
Exactly. Here's the latest one:
https://zackptg5.com/downloads/Disable_Dm-Verity_ForceEncrypt_05.21.2019.zip
Sent from my Moto G5 Plus using XDA Labs
Link is broken but I got the one from the other link made just a few months prior... Was there much a difference between that and the latest?
Thanks
itcanbdone said:
Link is broken but I got the one from the other link made just a few months prior... Was there much a difference between that and the latest?
Thanks
Click to expand...
Click to collapse
@Zackptg5 seems to have changed his side a bit, here's the actual link:
https://zackptg5.com/downloads/Disable_Dm-Verity_ForceEncrypt_08.18.2019.zip
Sent from my Moto G5 Plus using XDA Labs
Wolfcity said:
To decrypt it format/ data (not wipe, that's not enough, it's the option where you have to confirm with "yes"). As I did that I formatted data and after that flashed magisk. It doesn't work at first attempt so I went into TWRP and did it again.
Normally magisk should prevent your device from re - encrypting, if not flash the attached zip.
Sent from my Moto G5 Plus using XDA Labs
Click to expand...
Click to collapse
Do I need to select "Format Data" under "Wipe" to decrypt it? On TWRP, I see Wipe -> Format Data. If yes, do I need to remove SD card that has my system backup and custom ROM? Thanks.
---------- Post added at 03:14 AM ---------- Previous post was at 03:02 AM ----------
kuzo said:
I also do not work the "format data" the first time. you have to do it once and gives error, then restart , go to twrp and do it again and there if it works. and reinstall the rom again ... after that you can change rom normally
Click to expand...
Click to collapse
Are you referring to the "Format Data" tab under "Wipe" (that is, Wipe -> Format Data next to Advanced Wipe)? If yes, do I need to take out a SD card where I have a backup and custom ROM? Thanks.

Oreo Installation - Differences to Nougat?

Hello guys,
I'm a bit confused now from reading through different posts, each describing different methods.
Why can't we just Flash the IMG of Oreo like we would do with Stock Nougat?
Is this because it's still soak and hasn't really been released yet or am I missing something?
Also, where's the difference to just flash Stock Nougat and update to Oreo via the System Update button in the settings (that's called OTA, right?)?
Also I read "Flashing bootloader of equal or minor version will hardbrick your device"
Does that mean if I Flash that 2 times I Flash the same bl Version and I hardbrick my device?
I'm from Germany btw.
NPPS25.137.7 2.4 (I read, I have to be on 137.93.2.5 but I can just either flash it directly or flash an earlier stock and update until I'm there I guess?)
XT1676
Boot loader: B8.23
Note: I thought it would be better to post that in q&a instead of the reply section of the stock Oreo fastboot update post, since this are kind of general questions to the Oreo update topic.
Greetings,
7080
Flashing an oero stock rom firmware image is exactly the same as flashing a nougat stock rom firmware image (although there's a few more img_sparsechunks to flash)
You won't brick your phone if the firmware you are flashing the the same or newer
You will brick your phone if you try and flash a gpt & bootloader that is lower than the version currently on your phone
You can downgrade by flashing everything except these parts
There's no difference to flashing an ota via stock recovery to doing it via system update - however you must be on a fully unmodified stock rom else it will fail and potentially brick your phone
Don't confuse flashing an ota with flashing a complete stock rom firmware image
And ota must meet certain requirements - eg must be on a certain stock firmware version
A stock firmware image (complete stock firmware) can be flashed on any device (to which the image is for) that has the same or older bootloader version
TheFixItMan said:
Don't confuse flashing an ota with flashing a complete stock rom firmware image
And ota must meet certain requirements - eg must be on a certain stock firmware version
A stock firmware image (complete stock firmware) can be flashed on any device (to which the image is for) that has the same or older bootloader version
Click to expand...
Click to collapse
Thank you!
It took me some time to find out that OTA's only apply from one specific version to an other (the post from "tfwboredom" with all OTA's he was able to catch was a big help) and when i didnt get any OTA's (after flashing stock Nougat) i did an OTA update via adb. After that, my phone offered me OTA's again and i could upgrade until Oreo --.13 i guess. I rediscovered a thread with the full fastboot stock Oreo firmware --.16 then (forgot i already had downloaded it with my phone to my sd ^^) and flashed this then with the computer.
My Problem right now is the thing with the auto encryption.
Im on OPP28.85-16 now with TWRP64bit installed and was also able to get root by flashing newest Magisk (18.0) and the f2fs-loopback-bug-workaround (I dont really know for what that is) and installing MagiskManager v6.1 after booting system.
However, when i return to twrp after booting into system it asks me for a password to disable encryption and also wont flash things properly until i format data or do a factory reset. But after booting into system this encryption will be applied again. Flashing no-verity-encrypt didnt solve the problem.
What i want to find out now is:
1. Why is it automatically encrypting again and how can i disable that?
2. When i disabled that, can i encrypt my phone in the settings and use that password then to unlock twrp?
3. Where is the difference between this auto encryption and when i click in system settings on encrypt phone?
As far as i understood, in Nougat no-verity-encrypt was to prevent the dm-verity...thing to encrypt your phone but i could still enable encryption in the system settings.
(4. what is the purpose of f2fs bug fix?) - and has it enything to do with encryption?
G5-User7080 said:
Thank you!
It took me some time to find out that OTA's only apply from one specific version to an other (the post from "tfwboredom" with all OTA's he was able to catch was a big help) and when i didnt get any OTA's (after flashing stock Nougat) i did an OTA update via adb. After that, my phone offered me OTA's again and i could upgrade until Oreo --.13 i guess. I rediscovered a thread with the full fastboot stock Oreo firmware --.16 then (forgot i already had downloaded it with my phone to my sd ^^) and flashed this then with the computer.
My Problem right now is the thing with the auto encryption.
Im on OPP28.85-16 now with TWRP64bit installed and was also able to get root by flashing newest Magisk (18.0) and the f2fs-loopback-bug-workaround (I dont really know for what that is) and installing MagiskManager v6.1 after booting system.
However, when i return to twrp after booting into system it asks me for a password to disable encryption and also wont flash things properly until i format data or do a factory reset. But after booting into system this encryption will be applied again. Flashing no-verity-encrypt didnt solve the problem.
What i want to find out now is:
1. Why is it automatically encrypting again and how can i disable that?
2. When i disabled that, can i encrypt my phone in the settings and use that password then to unlock twrp?
3. Where is the difference between this auto encryption and when i click in system settings on encrypt phone?
As far as i understood, in Nougat no-verity-encrypt was to prevent the dm-verity...thing to encrypt your phone but i could still enable encryption in the system settings.
(4. what is the purpose of f2fs bug fix?) - and has it enything to do with encryption?
Click to expand...
Click to collapse
You need to format data to remove encryption
Wipe - option on the right
If you encrypt again once booted you need to use a twrp that supports encryption - the 64bit version posted in most rom threads don't support encryption but I did post the source code to my test version which someone compiled which may have encryption support
You can try it
https://drive.google.com/file/d/1kgFyYfjEyqAEXOGjg_UfeedlQwaLVF1F/view
All you should need to do is flash magisk - try version 17
You probably will need to change the device fingerprint to pass CtsProfile
Use this module
https://forum.xda-developers.com/apps/magisk/module-magiskhide-props-config-t3789228
TheFixItMan said:
You need to format data to remove encryption
Wipe - option on the right
Click to expand...
Click to collapse
- Yes, i did that, but when i boot system after it and return to twrp its again encrypted, but ill try a clean stock oreo flash -> twrp -> format data -> reboot -> return to twrp
If you encrypt again once booted you need to use a twrp that supports encryption - the 64bit version posted in most rom threads don't support encryption but I did post the source code to my test version which someone compiled which may have encryption support
You can try it
https://drive.google.com/file/d/1kgFyYfjEyqAEXOGjg_UfeedlQwaLVF1F/view
Click to expand...
Click to collapse
- Oh ok, i switched to 64bit version because of efs backup when still on Nougat, but i read somewhere that the 32bit version has that now, too, so could i also go just back to 32bit twrp?
As far as i remember, i never had a Problem with encryption on Nougat with 64bit.
- What does that mean that twrp supports encryption, when data gets encrypted every time, how should twrp be able to read that then?
All you should need to do is flash magisk - try version 17
Click to expand...
Click to collapse
- why 17 and not 18? i mean 18 worked when i tried it?
You probably will need to change the device fingerprint to pass CtsProfile
Use this module
https://forum.xda-developers.com/apps/magisk/module-magiskhide-props-config-t3789228
Click to expand...
Click to collapse
- I have currently no lock enabled, because i want to do a twrp backup after everything is done, what is the problem with fingerprint and what is CtsProfile?
I'll try that things out, thank you, and edit this when i find some things out
What i want at the end is a rooted Oreo (done) with a working twrp, where i can still flash and backup and restore without wiping data every time and if possible i want to use the normal encryption (the one when i boot system and set it up in settings).
I still dont really get what this auto encryption is.
As far I was aware the 64bit twrp cannot decrypt data apart from the test one I posted
If you don't have a twrp that supports data encryption your phone will still work, you just won't be able to use/flash zips to the data partition or backup/restore that partition
If you get a decrypt data when you boot your phone normally and it doesn't decrypt then you must remove encryption and boot the rom first before applying encryption again
My official 32bit twrp does support data encryption and will work on any 32bit rom including stock oero
Use any version of Magisk that works for you - I no longer own this device & only tested with magisk 17
Everything worked pretty well until i wanted to restore an older backup, I tried to format data before doing the restore but it failed.
After i flashed twrp (official 32bit this time) i did a factory reset to remove decryption and rebooted recovery to prevent the system fromr eplacing it. But when i use format data after that (or already in first place, could be that i tried that, too) it fails, it sais data successfully decrypted and continues and then theres an error. And when i try then a factory reset, too it fails, too.
However, after changing file system to ext4 and than formatting again (i dont remember exactly) i endet up with a working f2fs data partition and was able to use format data and restore backup,...
I am very confused now, because i dont get at all what the heck is the problem, should i not format data and do factory reset or does this happen when i flash the f2fs bug workaround before or is it because i booted the system and begun to change the settings, i have no idea,.. but ill try out and write you when i find something out!
EDIT:
Ok i found some things out, still dont understand at all, but it seems that
format data fails after booting into system
but works after rebooting twrp again
factory reset fails after format data fails
but works after format data works
works not after rebooting twrp, only if format data was successfull before (bec that works again after rebooting twrp)
rebooting system after format data failed will result into a bootloop into recovery with error when trying to enter recovery after manually going to bootloader -> recovery it works
It may help to see it in a table:
After flashing Oreo(boots up) and then twrp:
format data failed
factory reset failed
After flashing Oreo(boots up) and twrp and rebooting twrp:
format data successfull
factory reset successfull
reboot system
reboot twrp
format data failed
factory reset failed
reboot system results in bootloop into recovery with error
reboot twrp
factory reset failed
format data successull
reboot system
reboot twrp
factory reset successull
format data failed
factory reset failed
reboot twrp
factory reset failed
format data successull
factory reset successull
Output when format data fails:
Code:
[CODE]Data successfully decrypted, new block device: '/dev/block/dm-0'
Updating partition details...
...done
Successfully decrypted with default password.
Updating partition details...
...done
Full SELinux support is present.
MTP Enabled
I guess thats the log from twrp start and what followes is the one for format data
Code:
Formatting Data using mkfs.f2fs...
mkfs.f2fs -t 0 /dev/block/mmcblk0p54 process ended with ERROR: 255
Unable to wipe Data.
Unable to format to remove encryption.
Updating partition details...
Failed to mount '/data' (Device or resource busy)
...done
Unable to mount Storage
[/CODE]
And for factory reset after it:
Code:
Failed to mount '/data' (Device or resource busy)
Formatting Cache using make_ext4fs...
Updating partition details...
Failed to mount '/data' (Device or resource busy)
...done
Unable to mount storage
Try a
fastboot erase userdata
Type this in cmd on pc with phone connected via USB in bootloader mode
This will erase everything on internal
TheFixItMan said:
Try a
fastboot erase userdata
Type this in cmd on pc with phone connected via USB in bootloader mode
This will erase everything on internal
Click to expand...
Click to collapse
when should i do that?
Instead of using frmat data?
So when i flash twrp and boot into it first thing i should do is format data right? So i should just after flashing erase userdata and THEN enter twrp or what?
I'll copy in my reply from an other thread where 2 ppl tried to help me.
G5-User7080 said:
hmm, i did as follows:
flash stock (oreo) be sure sparsechunk 0-8 are ALL flashed
let phone start and turn it off again
flash twrp
boot recovery and factory reset
reboot recovery
flash magisk 18
reboot system
install magisk 6.1 apk
The thing is, when i dont reboot recovery after its installation the system will overwrite it with stock recovery and as far as i understood i need to reboot twrp for that.
I just did as i did for Nougat there regarding the post from 'Johny Cipeli':
6. In the Decrypt /data screen, press cancel, then "Swipe to Allow Modifications"
7. Go to WIPE, then "Swipe to Factory Reset"
8. Come back to TWRP main menu, go to REBOOT, then RECOVERY, then DO NOT INSTALL
So should i do then:
flash stock (oreo) be sure sparsechunk 0-8 are ALL flashed
let phone start and turn it off again
flash twrp
boot recovery
reboot recovery
format data
flash magisk 18
reboot system
install magisk 6.1 apk
or is this irrelevant if i first format data, then reboot twrp and then flash magisk?
Why do you flash no-verity? I tried that out earlier but it made no difference on the standard encryption.
I tryed a bit around with the data errors and found some things out, would you mind switching to this thread for the following?
Thank you for helping me, I just get totally confused by the Oreo process,.. worked so easy on nougat
Click to expand...
Click to collapse
As I rooted the device it was on Oreo OPS28.85-13-3 by OTA and I did it like this:
flash latest official twrp 3.2.3.1
make a backup of EFS and persist
boot recovery (now it prompts you to give in a decryption code, just press skip)
format data (F2FS)
don't reboot now
flash magisk 18 (I flashed 17.2 and updated later, no clue why)
reboot to system
install magisk 6.1 apk (if it's missing, in my case it was present)
if you reboot to twrp now it shouldn't prompt you to give in a decryption key anymore
G5-User7080 said:
when should i do that?
Instead of using frmat data?
So when i flash twrp and boot into it first thing i should do is format data right? So i should just after flashing erase userdata and THEN enter twrp or what?
I'll copy in my reply from an other thread where 2 ppl tried to help me.
Click to expand...
Click to collapse
It's the same as format data in twrp
To have it all in one Thread:
Wolfcity said:
So if you can't decrypt your data partition by formatting it (F2FS) and flashing magisk right after it without a reboot in between it may be possible that the bug is still present.
In that case you can give it a try and flash the fix from TWRP, maybe one of the older versions because the latest ones doesn't work for everyone.
Click to expand...
Click to collapse
hmm, i did as follows:
flash stock (oreo) be sure sparsechunk 0-8 are ALL flashed
let phone start and turn it off again
flash twrp
boot recovery and factory reset
reboot recovery
flash magisk 18
reboot system
install magisk 6.1 apk
The thing is, when i dont reboot recovery after its installation the system will overwrite it with stock recovery and as far as i understood i need to reboot twrp for that.
I just did as i did for Nougat there regarding the post from 'Johny Cipeli':
6. In the Decrypt /data screen, press cancel, then "Swipe to Allow Modifications"
7. Go to WIPE, then "Swipe to Factory Reset"
8. Come back to TWRP main menu, go to REBOOT, then RECOVERY, then DO NOT INSTALL
So should i do then:
flash stock (oreo) be sure sparsechunk 0-8 are ALL flashed
let phone start and turn it off again
flash twrp
boot recovery
reboot recovery
format data
flash magisk 18
reboot system
install magisk 6.1 apk
or is this irrelevant if i first format data, then reboot twrp and then flash magisk?
woozie.2007 said:
i dont think so, I rooted in that method, after update to oreo 8.1 stock, i flash official terp, then I flashed no verity 6.0 adn then format data partition. After that i booted in android, it say is encrypted, i can't decrypt it, but it works very well. I rooted two moto g5 stock oreo in that mode. Good luck
Click to expand...
Click to collapse
Why do you flash no-verity? I tried that out earlier but it made no difference on the standard encryption.
woozie.2007 said:
i flashed no verity because i want to decrypt the phone, but i didnt do that, not works, but works twrp for flashing, backup and restore without any problems. I cant say because of no verity or not, but it works. My phone is encrypted, but rooted with magisk 18.0 and i can install any module i want
Click to expand...
Click to collapse
As far as i know from 'TheFixItMan', he said that the 32bit twrp is able to surpass the encryption somehow.
But i guess this is kind of a standard encryption and not the "real encryption" could that be?
Because, i thought encryption means, you have to enter a password on boot to decrypt it.
When you set up your password under security you can choose to enter it on boot and then it will ask you for this password everytime BEFORE booting your system, and this will also be your password to decrypt data for twrp then. But i dont know if thats the "real encryption" or that standatd thing is, too, but just decrypts automatically on boot.
Thank you for helping me, I just get totally confused by the Oreo process,.. worked so easy on nougat
in security option, the phone appear to be encrypted, in nougat after flash no verity the phone was decrypted. In oreo i dont know why is appear encrypted and i cant decrypt with no verity....
Wolfcity said:
As I rooted the device it was on Oreo OPS28.85-13-3 by OTA and I did it like this:
flash latest official twrp 3.2.3.1
make a backup of EFS and persist
boot recovery (now it prompts you to give in a decryption code, just press skip)
format data (F2FS)
don't reboot now
flash magisk 18 (I flashed 17.2 and updated later, no clue why)
reboot to system
install magisk 6.1 apk (if it's missing, in my case it was present)
if you reboot to twrp now it shouldn't prompt you to give in a decryption key anymore
Click to expand...
Click to collapse
I dont have the option to backup efs,.. im using twrp 3.2.3-0 (the latest i could get from official twrp site) but i already did backup efs and persist in nougat, isnt that enough? DO i have to do that again on Oreo?
Also its not asking me for a decryption code, are you using 64bit twrp then?
And i remember that twrp got overwritten 2 or 3 times by stock recovery, and i thought that was because i didnt rebooted twrp again, since i rebooted twrp after formatting data it didnt happen again.
Also it did work for me using the 1. method i wrote earlier, i successfully rooted my phone, im just wondering now which is the "better" or "correct method to either
boot recovery, reboot recovery, format data and flash magisk
boot recovery, format data, reboot recovery, flash magisk
boot recovery, format data, flash magisk, boot system (but i guess next time you enter twrp it gets overwritten by stock recovery then)
boot recovery, format data, flash magisk, reboot recovery and boot system
or stay in bootloader (after flashing twrp) fastboot erase userdata, boot recovery, -data, -magisk, -system
or -recovery, -bootloader fastboot erase userdata, -recovery, -magisk, - system,.... you get the idea
woozie.2007 said:
in security option, the phone appear to be encrypted, in nougat after flash no verity the phone was decrypted. In oreo i dont know why is appear encrypted and i cant decrypt with no verity....
Click to expand...
Click to collapse
Because theres some sort of auto encryption which everytime reencrypts your phone.
I just dont get the sense of formatting data if it gets reencrypted anyway and twrp can surpass encryption.
G5-User7080 said:
After flashing Oreo(boots up) and then twrp:
format data failed
factory reset failed
After flashing Oreo(boots up) and twrp and rebooting twrp:
format data successfull
factory reset successfull
. . .
Click to expand...
Click to collapse
Had to correct that!
So in general after booting system, formatting data fails, maybe it works with fastboot erase userdata (didnt test it, cause i dont want to reflash Oreo again, i wanna go to bed.
But just rebooting recovery after booting first time in twrp works, so after that format data works. Works not..
Now im confused,.. after being in system and returning to twrp format data fails, but it seems when you fail it and then reboot recovery then it works...
So boot recovery, reboot recovery -> format data wont work BUT
boot recovery, format data fails, reboot recovery, format data will work WTF
So i guess either do factory reset instead of formatting data (thats also fine, or not?) or use fastboot erase userdata after flashing twrp in bootloader (i mean i do this while flashing oreo,.. so i dont really get why i have to do that again but i also dont really get why i have to format data a all)
Good night guys, thank you for your help,.. ill continue tomorrow.
G5-User7080 said:
Had to correct that!
So in general after booting system, formatting data fails, maybe it works with fastboot erase userdata (didnt test it, cause i dont want to reflash Oreo again, i wanna go to bed.
But just rebooting recovery after booting first time in twrp works, so after that format data works. Works not..
Now im confused,.. after being in system and returning to twrp format data fails, but it seems when you fail it and then reboot recovery then it works...
So boot recovery, reboot recovery -> format data wont work BUT
boot recovery, format data fails, reboot recovery, format data will work WTF
So i guess either do factory reset instead of formatting data (thats also fine, or not?) or use fastboot erase userdata after flashing twrp in bootloader (i mean i do this while flashing oreo,.. so i dont really get why i have to do that again but i also dont really get why i have to format data a all)
Good night guys, thank you for your help,.. ill continue tomorrow.
Click to expand...
Click to collapse
Latest official TWRP recovery is 3.2.3.1 for potter:
https://eu.dl.twrp.me/potter/
It has the ability to backup EFS and persist (see attached screenshot). I would make a backup just to be on the safe side.
To prevent the device from encrypting again the trick is to flash magisk after formatting data and before rebooting, it deactivates the "force encryption" flag (unless you tick the "keep force encryption" box in magisk manager).
Also I hadn't any problems to make TWRP stick.
Edit: A factory reset won't reformat data.
If you want your data partition decrypted or not depends on your needs. Encrypted is safe but you're not able to access it to make any changes unless you decrypt it again....
Wolfcity said:
Latest official TWRP recovery is 3.2.3.1 for potter:
https://eu.dl.twrp.me/potter/
It has the ability to backup EFS and persist (see attached screenshot). I would make a backup just to be on the safe side.
To prevent the device from encrypting again the trick is to flash magisk after formatting data and before rebooting, it deactivates the "force encryption" flag (unless you tick the "keep force encryption" box).
Also I hadn't any problems to make TWRP stick.
Edit: A factory reset won't reformat data.
If you want your data partition decrypted or not depends on your needs. Encrypted is safe but you're not able to access it to backup data or make any changes unless you decrypt it again....
Click to expand...
Click to collapse
I have the G5 not plus, theres no 3.2.3.1 yet. (Aber lustig, dass du auch aus deutschland bist (denk ich mal) ).
Ahh so i have to flash magisk right after decrypting by formatting data? But i cant successfully format data when i come from system as i wrote earlier so the question is if it works when i fastboot erase userdata to decrypt data and if data doesnt get reencrypted when i boot then twrp.
I guess if the force encryption reencrypts when i boot recovery, too it wont work, then i guess the only way is to enter recovery, do a failed attempt, reboot recovery, and successfully format data.
Edit:
It deactivates the "force encryption" flag (unless you tick the "keep force encryption" box).
Click to expand...
Click to collapse
Also after installing magisk and booting system it still says encrypted in settigns so i thought its not removing the force encrypt. And i dont have found that switch yet..
Wolfcity said:
To prevent the device from encrypting again the trick is to flash magisk after formatting data and before rebooting, it deactivates the "force encryption" flag (unless you tick the "keep force encryption" box in magisk manager).
Click to expand...
Click to collapse
Hi,
If i already have the phone encrypted and rooted with magisk, "keep force encryption" is tick, if I will untick the option will booting decrypted?
G5-User7080 said:
I have the G5 not plus, theres no 3.2.3.1 yet. (Aber lustig, dass du auch aus deutschland bist (denk ich mal) ).
Ahh so i have to flash magisk right after decrypting by formatting data? But i cant successfully format data when i come from system as i wrote earlier so the question is if it works when i fastboot erase userdata to decrypt data and if data doesnt get reencrypted when i boot then twrp.
I guess if the force encryption reencrypts when i boot recovery, too it wont work, then i guess the only way is to enter recovery, do a failed attempt, reboot recovery, and successfully format data.
Edit:
Also after installing magisk and booting system it still says encrypted in settigns so i thought its not removing the force encrypt. And i dont have found that switch yet..
Click to expand...
Click to collapse
Ah ok, I thought your device is a potter.
The checkbox is found inside magisk manager but it is unticked by default so the device should decrypt.
Have you tried the official twrp instead of the 64bit unofficial version?
Maybe try magisk 17.2 too as I did.
And yes, I'm from good old Germany too.
woozie.2007 said:
Hi,
If i already have the phone encrypted and rooted with magisk, "keep force encryption" is tick, if I will untick the option will booting decrypted?
Click to expand...
Click to collapse
I think you will have to decrypt data by formatting it, unticking the checkbox just prevents the device from encrypting itself again. You should find some additional informations:
https://www.didgeridoohan.com/magisk/MagiskInstallationIssues

Categories

Resources