Do you use encryption with a custom ROM ? - Xiaomi Redmi Note 4 Questions & Answers

I try official releases of lineage 15.1, Omnirom and when I run encryption from option (with password), android reboot without encryption of /data partition.
I have seen that unoffical release of lineage 16, Aosp 9 has issues in hardware encryption. No problem with official MIUI Rom also.
Are there any custom rom for mido that allow encryption ?
(My configuration, special MIDO TWRP treble support)
Thanks for your experience return.

I think it depend of the data partition if its F2FS or EXT4 , but i dont encrypt anymore , the one who would crack my phone would be left with unsatisfaction, at the end it would just prove that humans are never satisfied.

i am using lineage os 15.1 with encryption.
I didnt manually encrypted my phone but it got encrypted during installation of los 15.1

BK said:
I think it depend of the data partition if its F2FS or EXT4 , but i dont encrypt anymore , the one who would crack my phone would be left with unsatisfaction, at the end it would just prove that humans are never satisfied.
Click to expand...
Click to collapse
I use ext4 on another encryptedr mido with miui official.

Rohit338 said:
i am using lineage os 15.1 with encryption.
I didnt manually encrypted my phone but it got encrypted during installation of los 15.1
Click to expand...
Click to collapse
Are you sure ? because the assistant does not prompt for encryption but only for lock password.
I have tryed to reset with flashboot flash_all.sh but no difference after Los 15.1 install
What recovery do you use ? TWRP or REDWOLF ?

BK said:
I think it depend of the data partition if its F2FS or EXT4 , but i dont encrypt anymore , the one who would crack my phone would be left with unsatisfaction, at the end it would just prove that humans are never satisfied.
Click to expand...
Click to collapse
I can now answer, F2FS make no difference, same problem no encryption with custum rom

neo_mat said:
Are you sure ? because the assistant does not prompt for encryption but only for lock password.
I have tryed to reset with flashboot flash_all.sh but no difference after Los 15.1 install
What recovery do you use ? TWRP or REDWOLF ?
Click to expand...
Click to collapse
For installation i used twrp posted on 1st page.
but now i am using red wolf recovery.
yes it doesn't prompt for encryption but i think setting the lock pattern encrypted the phone as i have to draw the same pattern to access internal storage using red wolf and during booting.

Rohit338 said:
For installation i used twrp posted on 1st page.
but now i am using red wolf recovery.
yes it doesn't prompt for encryption but i think setting the lock pattern encrypted the phone as i have to draw the same pattern to access internal storage using red wolf and during booting.
Click to expand...
Click to collapse
Curious because, android need the password in order to decrypt…
Did your recovery prompt for password ? (recovery is OS independant) if not, your device is not encrypted.

neo_mat said:
Curious because, android need the password in order to decrypt…
Did your recovery prompt for password ? (recovery is OS independant) if not, your device is not encrypted.
Click to expand...
Click to collapse
yes recovery asks for password to decrypt internal storage by the way have you checked the screenshot i have attached.

thanks, yes i have seen sreenshot.
I really don't understand because it s do basic.
I use the same twrp,
I wipe all partitions
after that, the redmi note 4 is empty (no system, no data...)
I install los 15.1
run encryption with assistant
the redmi immediatly reboot without pass throught mi boot logo screen
and no encryption
I can loop that everytimes.
It's curious because the redmi immediatly reboot like a bad reboot. (like an error)
I don"t know if there is any log of that

steps that i followed
flashed twrp
wipe all
advance data format (entered YES to format)
and finally flashed los.

I found it !!!
This can save people.
I have to leave 4K block into userdata partition.
In fact, fastboot, and TWRP can break filesystem and resize filesystem to all partition size.
Encryption need 4K block in order to write encryption data about userdata patition.
I have resized my ext4 filesystem with resize2fs.
Now all is OK !!!!
After that, I also format from ext4 to f2fs.
Thanks

neo_mat said:
I found it !!!
This can save people.
I have to leave 4K block into userdata partition.
In fact, fastboot, and TWRP can break filesystem and resize filesystem to all partition size.
Encryption need 4K block in order to write encryption data about userdata patition.
I have resized my ext4 filesystem with resize2fs.
Now all is OK !!!!
After that, I also format from ext4 to f2fs.
Thanks
Click to expand...
Click to collapse
Great news! Does it mean you could encrypt your device on a Pie ROM?

Of course !
I can now encrypt my device.

neo_mat said:
Of course !
I can now encrypt my device.
Click to expand...
Click to collapse
That's great news. I am pretty used to flashing my beloved mido but I never used the tool you mentioned (resize2fs). Would be great if you could provide some kind of documentation how to do this?

neo_mat said:
I found it !!!
This can save people.
I have to leave 4K block into userdata partition.
In fact, fastboot, and TWRP can break filesystem and resize filesystem to all partition size.
Encryption need 4K block in order to write encryption data about userdata patition.
I have resized my ext4 filesystem with resize2fs.
Now all is OK !!!!
After that, I also format from ext4 to f2fs.
Thanks
Click to expand...
Click to collapse
how to do it, can you explain it please?

I'm trying to disable encryption because with pretty much every ROM I tried the phone ends up encrypted. Which is very annoying as it prevents dirty flashes (+ updates) and flashing things like Magisk after first boot

Related

Can't format my System and Data as F2FS

When I try to format my Data partition to F2FS it shows:
mkfs.f2fs -t 0 -r 16384 /dev/block/sda9 process ended with ERROR: 1
Unable to wipe Data.
Error changing file system.
And also when I format System to F2FS it succeeds but when I install a ROM (AOSiP) it won't install unless I reformat it back to ext4.
Hope anyone can help..
Thank you!
Heyyo, pretty much all ROMs will force system to default to ext4 for compatibility and stability reasons.
With that said? It is still possible to run any ROM that has f2fs support with your system as f2fs but you gotta work for it.
1. Install ROM (with gapps, etc)
2. Make a backup of system
3. Convert system to f2fs
4. In TWRP settings, enable the "instead of format use RM -rf"
5. Restore the backup of system
System should now be in f2fs... Albeit I can't remember if future ROM updates will revert to ext4 haven't tried system as f2fs in a long time...
As for data? Please flash the GalaticStryder build of TWRP found in my TWRP thread. It's a bug on TWRP for the make.f2fs not having the necessary updates for the encryption footer thus that encryption length error message.
Once you flash GS TWRP build? You should be good to go for converting data to f2fs.
ThE_MarD said:
Heyyo, pretty much all ROMs will force system to default to ext4 for compatibility and stability reasons.
With that said? It is still possible to run any ROM that has f2fs support with your system as f2fs but you gotta work for it.
1. Install ROM (with gapps, etc)
2. Make a backup of system
3. Convert system to f2fs
4. In TWRP settings, enable the "instead of format use RM -rf"
5. Restore the backup of system
System should now be in f2fs... Albeit I can't remember if future ROM updates will revert to ext4 haven't tried system as f2fs in a long time...
As for data? Please flash the GalaticStryder build of TWRP found in my TWRP thread. It's a bug on TWRP for the make.f2fs not having the necessary updates for the encryption footer thus that encryption length error message.
Once you flash GS TWRP build? You should be good to go for converting data to f2fs.
Click to expand...
Click to collapse
Hi! I know it's been so long since I posted this but when I flashed AOSPExtended it shows an "Encryption unsuccessful " screen for me whenever I format Data partition as F2FS :/
Update: Dirty Flashed latest AOSPExtended and made a backup of it, did what you instructed and when I boot the phone it goes to fastboot mode.
ThE_MarD said:
Heyyo, pretty much all ROMs will force system to default to ext4 for compatibility and stability reasons.
With that said? It is still possible to run any ROM that has f2fs support with your system as f2fs but you gotta work for it.
1. Install ROM (with gapps, etc)
2. Make a backup of system
3. Convert system to f2fs
4. In TWRP settings, enable the "instead of format use RM -rf"
5. Restore the backup of system
System should now be in f2fs... Albeit I can't remember if future ROM updates will revert to ext4 haven't tried system as f2fs in a long time...
As for data? Please flash the GalaticStryder build of TWRP found in my TWRP thread. It's a bug on TWRP for the make.f2fs not having the necessary updates for the encryption footer thus that encryption length error message.
Once you flash GS TWRP build? You should be good to go for converting data to f2fs.
Click to expand...
Click to collapse
Hi friend, does Lineage run well with the system partition in f2fs?
I use only the data, do you think it's worth the test?
Rom is great at it, congratulations! :good::good:
Jabbzz said:
Hi! I know it's been so long since I posted this but when I flashed AOSPExtended it shows an "Encryption unsuccessful " screen for me whenever I format Data partition as F2FS :/
Update: Dirty Flashed latest AOSPExtended and made a backup of it, did what you instructed and when I boot the phone it goes to fastboot mode.
Click to expand...
Click to collapse
Heyyo, hmm if that is the case I think AOSPExtended doesn't support quota for storage.. the only way to resolve this is to backup your data, copy it to USB OTG or to a PC and then going to wipe > format data > yes. After that you can copy back your data and restore the data backup.
drml said:
Hi friend, does Lineage run well with the system partition in f2fs?
I use only the data, do you think it's worth the test?
Rom is great at it, congratulations! :good::good:
Click to expand...
Click to collapse
Heyyo! To be honest I have not tested it much with f2fs. It feels smooth enough but then again ext4 still runs pretty darn good so any performance improvement is minor.
I only ever recommend converting the cache partition to f2fs as it constantly changes data and f2fs still doesn't handle file system fragmentation as well as others such as ext4 so f2fs on system and data still isn't as ideal as ext4 for long term performance retention.
ThE_MarD said:
Heyyo! To be honest I have not tested it much with f2fs. It feels smooth enough but then again ext4 still runs pretty darn good so any performance improvement is minor.
I only ever recommend converting the cache partition to f2fs as it constantly changes data and f2fs still doesn't handle file system fragmentation as well as others such as ext4 so f2fs on system and data still isn't as ideal as ext4 for long term performance retention.
Click to expand...
Click to collapse
f2fs ist superior to ext4 especially in write operations. That's way if you use f2fs you don't be affected to the slowness who comes with the time with the ext4. Otherwise ext4 exist longer and is more, lot of people assume this, stable. I use f2fs long enough to say that my last freezes with the f2fs filesystem are way back to 2014. Even then I would say that the troubles come with the custom roms than with the f2fs.
I use in my x2 the Lineage unofficial with f2fs without a single performance degradation and before that used Infrag nougat aicp with f2fs. F2fs is better but lot of people have trouble or they don't know how to convert the /data partition and before that that they must Backup the /internal Sdcard as the convert process wipe the whole /data + /internalsd
Here more Infos why f2fs is the better filesystem
https://www.google.com.cy/amp/s/www...ms-matter-interview-stan-dmitriev-tuxera/amp/
https://www.linux.org/threads/flash-friendly-file-system-f2fs.8931/

Twrp on redmi 6a

I flashed twrp on my redmi 6a, but i haven't been able to succeed at formatting data, or anything from advanced wipe. Also ADB sideload has refused to start. First i thougt it was because of the encrypted data and tried every way to decrypt like flashing universal disabler before magisk. I noticed that preserve force encryption in magisk was unticked but twrp still asked for the password and also my root was screwed big time and most apps couldn't find it, so i flashed the stocked rom and started afresh, now i want to try resurrection remix(not sure it's a good idea) but process is involved with formatting data and advanced wipe. I'm using twrp 3.2.3.2-cactus. Some help
it seems that no one can solve encryption problem in twrp?
All google result said that this should be formatting data partition. One question is: how could the format partition data whlie the partition is untouchable?
adista said:
it seems that no one can solve encryption problem in twrp?
All google result said that this should be formatting data partition. One question is: how could the format partition data whlie the partition is untouchable?
Click to expand...
Click to collapse
Use the TWRP-1020 one.
jonaaa, how does that work any different.

Disable internal storage encryption without wipe data

Is there anything way that i can disable data encryption? Both TWRP and orange fox not allow me to install anything and asking for password, i tried both lock password and mi password but nothing. I am trying to root my phone, i also tried to make a patched boot image with magisk manager but not install button was showing up.Any solution?
Stock rom with miui global 10.3.1.0 version
tzagaritos said:
Is there anything way that i can disable data encryption? Both TWRP and orange fox not allow me to install anything and asking for password, i tried both lock password and mi password but nothing. I am trying to root my phone, i also tried to make a patched boot image with magisk manager but not install button was showing up.Any solution?
Stock rom with miui global 10.3.1.0 version
Click to expand...
Click to collapse
Don´t waste your time trying to decipher the password, they´re advanced algorithms that Android uses to make the Encryption-By-Default to protect data user not a personal password that can be easily decoded.
You can flash any zip using adb sideload through Advanced options in recovery, the problem would be trying to boot up due to AVB implementation, I never cared about format data when is needed so my important files I ever have on my external SDCard.
Some members refer that such recovery can decrypt data or not, this is not a problem by its own but the ability to boot. The simple way to decrypt data is formatting it.
As a side note decrypt data will be required just in some cases like when you unlocked for first time, when you are coming back to a Miui upgraded rom then to an AOSP one but most of custom roms based on Miui don´t have encryption like ROS, Xiaomi.eu or Mi-Globe.
SubwayChamp said:
Don´t waste your time trying to decipher the password, they´re advanced algorithms that Android uses to make the Encryption-By-Default to protect data user not a personal password that can be easily decoded.
You can flash any zip using adb sideload through Advanced options in recovery, the problem would be trying to boot up due to AVB implementation, I never cared about format data when is needed so my important files I ever have on my external SDCard.
Some members refer that such recovery can decrypt data or not, this is not a problem by its own but the ability to boot. The simple way to decrypt data is formatting it.
As a side note decrypt data will be required just in some cases like when you unlocked for first time, when you are coming back to a Miui upgraded rom then to an AOSP one but most of custom roms based on Miui don´t have encryption like ROS, Xiaomi.eu or Mi-Globe.
Click to expand...
Click to collapse
thanks a lot , i did not know that i could flash zip files in that way, you saved me thanks again
use the custom TWRP by wzsx150, decryption is working with that one https://forum.xda-developers.com/mi-8-Lite/development/mi-8-lite-twrp-t3850019
borg4571 said:
use the custom TWRP by wzsx150, decryption is working with that one https://forum.xda-developers.com/mi-8-Lite/development/mi-8-lite-twrp-t3850019
Click to expand...
Click to collapse
Is possible to send me the img file through Google drive or anything familiar;its a mess trying yo download from the Chinese site
I have Android pie

Mi Pad 4 - Encryption bootloop

Hi together,
i have an problem with the tablet encryption.
i wanna swap from xiaomi.eu to another more actual custom rom..
i tried PixelExperience , Havoc-OS, dotOS, ArrowOs .. and everytime i activate the encryption it's end in an bootloop regardless of pin,password,pattern ..
I'm using the latest TWRP Version
- Wipe Dalvik/ART Cache, Cache, System, Vendor, Data
- Flash from zip
- start os and enable encryption
-> bootloop
My experience with this device is limited, but I faced a similar problem switching from stock rom to an older ROM not using any encryption.
I think it was only succesful after removing encryption. Maybe it also helps in your case?!
There are many guides how to remove encryption, most of them suggest "Advanced Swipe" combined with changing the file system.
I used TWRP to swipe "data" to ext2, then again swipe "data" back to ext4 and afterwards it still needed a tap on "File System Repair" for the "system" partition. After that, the flash and boot worked for that older ROM.
Maybe that will leave you with a better starting point for activating encryption of your ROM.
(But as I wrote: Just a guess, not based on experience.)
aes32 said:
My experience with this device is limited, but I faced a similar problem switching from stock rom to an older ROM not using any encryption.
I think it was only succesful after removing encryption. Maybe it also helps in your case?!
There are many guides how to remove encryption, most of them suggest "Advanced Swipe" combined with changing the file system.
I used TWRP to swipe "data" to ext2, then again swipe "data" back to ext4 and afterwards it still needed a tap on "File System Repair" for the "system" partition. After that, the flash and boot worked for that older ROM.
Maybe that will leave you with a better starting point for activating encryption of your ROM.
(But as I wrote: Just a guess, not based on experience.)
Click to expand...
Click to collapse
Hi,
thanks for your answer. As i wrote i delete nearly everything
The OS booted, but at the point where i want to enable encryption most roms get stuck in a bootloop.
After endless roms i found carbonrom which works.. Additionally i found an post from TWRP about encryption.. i don't know if it's connected, but i guess it's an similar problem cause AOSP..
Why doesn't TWRP support encryption on my device?
Why doesn't TWRP support encryption on my device?TWRP encryption is supported in 2 phases. The first item is keeping up with the newest support from AOSP, wh...
twrp.me
So i found a working rom, but not the solution or true cause of the bootloop problem
Ok, I understand.
I guess I don't know the encryption feature well enough to help.
Found some interesting stuff to read about it, not sure if it applies to the Mi Pad 4 and its custom ROMs, though:
Any way to encrypt /data/data and /sdcard on Xiaomi EU ROM?
Hello, Xiaomi EU ROM is running decrypted, that's a security breach... Is there a way to use Xiaomi EU ROM, based on Miui 10, in a encrypted phone? Thanks
forum.xda-developers.com
So the bootloop seems to be expected and if I got it right then the fstab.qcom needs an edit at least.
Mhm it's confusing me.. cause i run nearly 5 years xiaomi.eu rom encrypted from scratch on. i think with FDE .. the rom says encrypted and twrp says encrypted and the sdcard folder is only crypted filenames.. also interesting the article.. but i'm sceptical that edit the fstab.qcom maybe work on more "normal" AOSP roms..
so i found a working rom i'm not motivated enough to try the edit xD
xXZaretXx said:
Mhm it's confusing me.. cause i run nearly 5 years xiaomi.eu rom encrypted from scratch on. i think with FDE .. the rom says encrypted and twrp says encrypted and the sdcard folder is only crypted filenames.. also interesting the article.. but i'm sceptical that edit the fstab.qcom maybe work on more "normal" AOSP roms..
so i found a working rom i'm not motivated enough to try the edit xD
Click to expand...
Click to collapse
Yes, sorry, I fully understand your point of view.
It is confusing me as well.
I'm currently experimenting with some ROM's, so yesterday I gave encryption on Havoc-OS a try - even by starting with encrypted stock rom, flashing Havoc-OS and modifying fstab.qcom - but without success. It rebooted immediately and then seemed to be hanging idle during boot for a long time.
I was not interested in encryption so far, but of course it would be great if it worked. And I should be interested for the sake of privacy.
Thanks for reporting that it works with the carbon ROM.
Edit: In Lineage OS it will probably work too, based on the description of the ROM.
I will probably try that one next, because it is also supposed to have the "split screen" feature which I am looking for.
Encryption in Lineage OS seems to work fine, as expected.
I tried to analyze Havoc OS encryption once more: It seems not to be supported at all.
It does "something" trying to encrypt... because TWRP asked for a password the next time I rebooted to recovery. Problem is, decryption in TWRP did not work with the previously given password and the data partition seemed to be messed up (file system type was "emmc", and the data partition was not responding to any of tune2fs, e2fsck or alike).
I looked at the dmesg log, it seems during the boot attempt, the system just cannot work with data any more (hence the idle hang, I assume).
There are many many log lines, showing attempts to work with data and that the system actually expects an ext4 file system for "userdata" (=mmcblk0p64):
Code:
[ 2.990548] EXT4-fs (mmcblk0p64): VFS: Can't find ext4 filesystem
[ 2.990698] EXT4-fs (mmcblk0p64): VFS: Can't find ext4 filesystem
[ 2.996651] EXT4-fs (mmcblk0p64): VFS: Can't find ext4 filesystem
[ 2.996795] EXT4-fs (mmcblk0p64): VFS: Can't find ext4 filesystem

Use F2FS in Android 13

Is it Still Possible to use F2FS in Android 13 ?
I tried in LineageOS with No Gravity Kernel but i get a Bootloop.
Now i switched to PixelOS but it reformats the data partition to ext4 every time at reboot. Can someone tell me how to use f2fs or why it isnt possible anymore ?
F2fs only works on certain roms, crdroid 9 works with f2fs on data and cache. You can flash f2fstab to insert the f2fs format table in to the rom so you can use it, but not sure if this works with encryption.
noah001 said:
Is it Still Possible to use F2FS in Android 13 ?
I tried in LineageOS with No Gravity Kernel but i get a Bootloop.
Now i switched to PixelOS but it reformats the data partition to ext4 every time at reboot. Can someone tell me how to use f2fs or why it isnt possible anymore ?
Click to expand...
Click to collapse
first_damned said:
F2fs only works on certain roms, crdroid 9 works with f2fs on data and cache. You can flash f2fstab to insert the f2fs format table in to the rom so you can use it, but not sure if this works with encryption.
Click to expand...
Click to collapse
Thank you very much, f2fstab did it for me for LineageOS.
Do i need to reflash it after every update ?
noah001 said:
Thank you very much, f2fstab did it for me for LineageOS.
Do i need to reflash it after every update ?
Click to expand...
Click to collapse
I'm not sure sorry

Categories

Resources