OSDN Git Service

e4crypt_is_native has been moved into system/extras.
authorPaul Crowley <paulcrowley@google.com>
Wed, 27 Apr 2016 17:25:12 +0000 (10:25 -0700)
committerPaul Crowley <paulcrowley@google.com>
Tue, 10 May 2016 15:43:07 +0000 (08:43 -0700)
Bug: 28318405
Change-Id: Id962764cf7fb5f58b769bf99aeb6d3d69cb66991

Ext4Crypt.cpp

index c214d54..1d4cebc 100644 (file)
@@ -26,7 +26,6 @@
 #include <sstream>
 #include <string>
 
-#include <cutils/properties.h>
 #include <dirent.h>
 #include <errno.h>
 #include <fcntl.h>
@@ -61,7 +60,7 @@ static constexpr int FLAG_STORAGE_DE = 1 << 0;
 static constexpr int FLAG_STORAGE_CE = 1 << 1;
 
 namespace {
-const std::string device_key_dir = std::string() + DATA_MNT_POINT + "/unencrypted";
+const std::string device_key_dir = std::string() + DATA_MNT_POINT + e4crypt_unencrypted_folder;
 const std::string device_key_path = device_key_dir + "/key";
 const std::string device_key_temp = device_key_dir + "/temp";
 
@@ -95,13 +94,6 @@ struct ext4_encryption_key {
 };
 }
 
-// TODO replace with proper function to test for file encryption
-bool e4crypt_is_native() {
-    char value[PROPERTY_VALUE_MAX];
-    property_get("ro.crypto.type", value, "none");
-    return !strcmp(value, "file");
-}
-
 static bool e4crypt_is_emulated() {
     return property_get_bool("persist.sys.emulate_fbe", false);
 }