mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-06-12 05:07:45 +02:00
Better handling of data encryption
This commit is contained in:
@ -363,10 +363,10 @@ get_flags() {
|
||||
KEEPVERITY=false
|
||||
fi
|
||||
fi
|
||||
ISENCRYPTED=false
|
||||
grep ' /data ' /proc/mounts | grep -q 'dm-' && ISENCRYPTED=true
|
||||
[ "$(getprop ro.crypto.state)" = "encrypted" ] && ISENCRYPTED=true
|
||||
if [ -z $KEEPFORCEENCRYPT ]; then
|
||||
ISENCRYPTED=false
|
||||
grep ' /data ' /proc/mounts | grep -q 'dm-' && ISENCRYPTED=true
|
||||
[ -d /data/unencrypted ] && ISENCRYPTED=true
|
||||
# No data access means unable to decrypt in recovery
|
||||
if $ISENCRYPTED || ! $DATA; then
|
||||
KEEPFORCEENCRYPT=true
|
||||
|
Reference in New Issue
Block a user