diff options
author | Paul Lawrence <paullawrence@google.com> | 2015-04-28 22:07:10 +0000 |
---|---|---|
committer | Paul Lawrence <paullawrence@google.com> | 2015-05-29 17:39:16 +0000 |
commit | 0a423d994a0dbd05924ae6cff702b5d4d7dd43f0 (patch) | |
tree | de7a20a355c1e1bb0c71fa8dc8d67a204d2c6bce /fs_mgr | |
parent | 0aab798312364971ad3d2052306f3c9a8aed6c57 (diff) | |
download | system_core-0a423d994a0dbd05924ae6cff702b5d4d7dd43f0.zip system_core-0a423d994a0dbd05924ae6cff702b5d4d7dd43f0.tar.gz system_core-0a423d994a0dbd05924ae6cff702b5d4d7dd43f0.tar.bz2 |
DO NOT MERGE Securely encrypt the master key
(chery-picked from commit 806d10be2336f32cdca16c2540cbf3d548f2fec7)
Move all key management into vold
Reuse vold's existing key management through the crypto footer
to manage the device wide keys.
Use ro.crypto.type flag to determine crypto type, which prevents
any issues when running in block encrypted mode, as well as speeding
up boot in block or no encryption.
This is one of four changes to enable this functionality:
https://android-review.googlesource.com/#/c/148586/
https://android-review.googlesource.com/#/c/148604/
https://android-review.googlesource.com/#/c/148606/
https://android-review.googlesource.com/#/c/148607/
Bug: 18151196
Change-Id: I6a8a18f43ae837e330e2785bd26c2c306ae1816b
Diffstat (limited to 'fs_mgr')
-rw-r--r-- | fs_mgr/fs_mgr.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/fs_mgr/fs_mgr.c b/fs_mgr/fs_mgr.c index 740f894..15d44ef 100644 --- a/fs_mgr/fs_mgr.c +++ b/fs_mgr/fs_mgr.c @@ -31,7 +31,7 @@ #include <dirent.h> #include <ext4.h> #include <ext4_sb.h> -#include <ext4_crypt.h> +#include <ext4_crypt_init_extensions.h> #include <linux/loop.h> #include <private/android_filesystem_config.h> @@ -486,16 +486,6 @@ static int handle_encryptable(struct fstab *fstab, const struct fstab_rec* rec) return FS_MGR_MNTALL_FAIL; } - // Link it to the normal place so ext4_crypt functions work normally - strlcat(tmp_mnt, "/unencrypted", sizeof(tmp_mnt)); - char link_path[PATH_MAX]; - strlcpy(link_path, rec->mount_point, sizeof(link_path)); - strlcat(link_path, "/unencrypted", sizeof(link_path)); - if (symlink(tmp_mnt, link_path)) { - ERROR("Error creating symlink to unencrypted directory\n"); - return FS_MGR_MNTALL_FAIL; - } - return FS_MGR_MNTALL_DEV_NON_DEFAULT_FILE_ENCRYPTED; } |