Merge "Don't include password on default encryption command" into mnc-dr-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
68521fd7ce
@@ -2415,8 +2415,13 @@ class MountService extends IMountService.Stub
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
mCryptConnector.execute("cryptfs", "enablecrypto", "inplace", CRYPTO_TYPES[type],
|
if (type == StorageManager.CRYPT_TYPE_DEFAULT) {
|
||||||
new SensitiveArg(password));
|
mCryptConnector.execute("cryptfs", "enablecrypto", "inplace",
|
||||||
|
CRYPTO_TYPES[type]);
|
||||||
|
} else {
|
||||||
|
mCryptConnector.execute("cryptfs", "enablecrypto", "inplace",
|
||||||
|
CRYPTO_TYPES[type], new SensitiveArg(password));
|
||||||
|
}
|
||||||
} catch (NativeDaemonConnectorException e) {
|
} catch (NativeDaemonConnectorException e) {
|
||||||
// Encryption failed
|
// Encryption failed
|
||||||
return e.getCode();
|
return e.getCode();
|
||||||
|
|||||||
Reference in New Issue
Block a user