From 3bd73edbae9a4c476eb14a5a909d9e6658224a8a Mon Sep 17 00:00:00 2001 From: Jeff Sharkey Date: Wed, 18 Nov 2015 10:20:18 -0700 Subject: [PATCH] Mark this coreApp as being encryptionAware. Historically, apps marked with "coreApp" were prepared to run in a limited boot environment, and were critical to booting the device, so in the new file-based encryption world we're marking these apps with both "forceDeviceEncrypted" and "encryptionAware" attributes. Bug: 22358539 Change-Id: Idf9fb8d4b0cc1cd504c9ab7ed770d2cd86d3d506 --- AndroidManifest.xml | 4 +++- src/com/android/settings/DevelopmentSettings.java | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/AndroidManifest.xml b/AndroidManifest.xml index df00ad16805..3f3cfd792a1 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -92,7 +92,9 @@ android:requiredForAllUsers="true" android:supportsRtl="true" android:allowBackup="false" - android:usesCleartextTraffic="true"> + android:usesCleartextTraffic="true" + android:forceDeviceEncrypted="true" + android:encryptionAware="true"> diff --git a/src/com/android/settings/DevelopmentSettings.java b/src/com/android/settings/DevelopmentSettings.java index af34647c1e9..c25d2d399bd 100644 --- a/src/com/android/settings/DevelopmentSettings.java +++ b/src/com/android/settings/DevelopmentSettings.java @@ -54,6 +54,7 @@ import android.os.StrictMode; import android.os.SystemProperties; import android.os.UserManager; import android.os.storage.IMountService; +import android.os.storage.StorageManager; import android.provider.SearchIndexableResource; import android.provider.Settings; import android.provider.Settings.Global; @@ -421,7 +422,7 @@ public class DevelopmentSettings extends SettingsPreferenceFragment IMountService mountService = IMountService.Stub.asInterface(service); if (!mountService.isConvertibleToFBE()) { removePreference(KEY_CONVERT_FBE); - } else if (mountService.isPerUserEncryptionEnabled()) { + } else if ("file".equals(SystemProperties.get("ro.crypto.type", "none"))) { convertFbePreference.setEnabled(false); convertFbePreference.setSummary(getResources() .getString(R.string.convert_to_file_encryption_done));