From 2eaf7138528d30c331d83ab8346a97e66b5499e2 Mon Sep 17 00:00:00 2001 From: Ken Sumrall Date: Fri, 14 Jan 2011 12:45:48 -0800 Subject: [PATCH] Cleanup a few issues with the cryptfs code. Now that the framework shuts down quickly, remove the 30 second sleep when enabling crypto. Also, stop spewing the secret master key to the disk in the system log! Change-Id: Icb3f9456ababe3dff8de52cbbae92da0e9e5dd2f --- cryptfs.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/cryptfs.c b/cryptfs.c index ac2cefd..cf509c9 100644 --- a/cryptfs.c +++ b/cryptfs.c @@ -285,7 +285,7 @@ static int create_crypto_blk_dev(struct crypt_mnt_ftr *crypt_ftr, unsigned char convert_key_to_hex_ascii(master_key, crypt_ftr->keysize, master_key_ascii); sprintf(crypt_params, "%s %s 0 %s 0", crypt_ftr->crypto_type_name, master_key_ascii, real_blk_name); - SLOGD("crypt_params = %s\n", crypt_params); + //SLOGD("crypt_params = %s\n", crypt_params); // Only for debugging, prints the master key! crypt_params += strlen(crypt_params) + 1; crypt_params = (char *) (((unsigned long)crypt_params + 7) & ~8); /* Align to an 8 byte boundary */ tgt->next = crypt_params - buffer; @@ -459,7 +459,7 @@ static int get_orig_mount_parms(char *mount_point, char *fs_type, char *real_blk static int wait_and_unmount(char *mountpoint) { int i, rc; -#define WAIT_UNMOUNT_COUNT 100 +#define WAIT_UNMOUNT_COUNT 20 /* Now umount the tmpfs filesystem */ for (i=0; i