[RECOVERY] TWRP 3.1.1 for libra/aqua

Cozzmy13

Senior Member
Aug 17, 2014
1,311
3,747
113
21
Suceava
Thanks for your work!
Encryption still not working.
Errorlogpart again (not changed):

Code:
Using scrypt with keymaster for cryptfs KDF
keymaster module name is Keymaster QTI HAL
keymaster version is 256
Found keymaster1 module, using keymaster1 API.
could not open keymaster device in keystore (Operation not permitted)
Failed to init keymaster
Signing failed
kdf failed
failure decrypting master key
Failed to decrypt master key
See the post I just made lol.
It works fine now.
 

Ezier

Member
Jan 7, 2018
6
0
0
How to know bootloader version

I started to unlock the device by flashing libra_images_6.1.7_20151221.0000.11_5.1_cn_b09dac70a0 then did the unlocking process, flashing TWRP 3.1.1. with this method I was successfully flash LineageOS 15 and MIUI 9 ROM by MIUIPRO. Few days ago I tried to install XOSP ROM but when flashing the XOSP 7.1 through TWRP it said "firmware doesn't support this ROM" (if i wasn't wrong noticing the error). I got error also when installed RR ROM. Does it mean i'm on Lollipop bootloader?

Now my device is on LineageOS 15.1
 

longu

Senior Member
Apr 6, 2007
166
9
0
New build is up, twrp-20171221-1538.img.
Decryption is totally fixed, tested it myself with official LineageOS 14.1.

@ThePeKo @laserkater @groche97 @ch55
I do confirm that it's the first TWRP for my Mi4s which managed to decrypt my encrypted storage, but I do have 2 issues:
1. xiaomi.eu OTA is not installing
2. when I try to install new update via Install option (zip) I get the following error message:
Code:
this package is for "aqua" devices; this is a "libra"
Regards.

EDIT:
I managed to install the ROM (update) I wanted with a simple workaround:
I edited /META-INF/com/google/android/updater-script in zip file and replaced:

getprop("ro.product.device") == "aqua"
to

getprop("ro.product.device") == "libra"
I would appreciate if you fix your TWRP for Mi4s as it's the only I found which is working fine with encrypted device.
Thank you in advance!
Best regards.
 
Last edited:

gothed

Senior Member
Dec 24, 2013
571
101
0
33
Yogyakarta
I started to unlock the device by flashing libra_images_6.1.7_20151221.0000.11_5.1_cn_b09dac70a0 then did the unlocking process, flashing TWRP 3.1.1. with this method I was successfully flash LineageOS 15 and MIUI 9 ROM by MIUIPRO. Few days ago I tried to install XOSP ROM but when flashing the XOSP 7.1 through TWRP it said "firmware doesn't support this ROM" (if i wasn't wrong noticing the error). I got error also when installed RR ROM. Does it mean i'm on Lollipop bootloader?

Now my device is on LineageOS 15.1
same problem here sir, when i try to flash AEX v4.6 rom, it is stuck on installation process even after flashing the latest miui firmware (8.5.1.0)

still can't find the solutions for this
 

saywa

Senior Member
Oct 4, 2010
147
39
0
i never needed to unlock the bootloader, i just cant flash the recovery in version 3.1.1.1
i tried 3.0.2.0 and that works
i noticed 3.1.1.1 has 20 MB and 3.0.2.0 has 40+ MB
so i think the file is corrupt, please forward this ....
3.1.1.1 does not boot
 
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone