diff options
author | 2023-10-25 18:59:13 +0000 | |
---|---|---|
committer | 2023-10-25 18:59:13 +0000 | |
commit | c410ea7aabbfc5578bc62c452ead4122919a719f (patch) | |
tree | 7630299786c4b41010eb34d8fdf942a1677583a1 | |
parent | b3ac3137cbe5054c7ade3d4b476135bf9dd0bbb4 (diff) | |
parent | 912e35b698089b41083153e271ddef13e8e7261d (diff) |
Merge "Improve documentation for unlockUserKeyIfUnsecured()" into main
-rw-r--r-- | core/java/com/android/internal/widget/LockPatternUtils.java | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/core/java/com/android/internal/widget/LockPatternUtils.java b/core/java/com/android/internal/widget/LockPatternUtils.java index a3e27062fa7b..8d11672144b2 100644 --- a/core/java/com/android/internal/widget/LockPatternUtils.java +++ b/core/java/com/android/internal/widget/LockPatternUtils.java @@ -1934,15 +1934,21 @@ public class LockPatternUtils { } /** - * Unlocks the credential-encrypted storage for the given user if the user is not secured, i.e. - * doesn't have an LSKF. + * If the user is not secured, ie doesn't have an LSKF, then decrypt the user's synthetic + * password and use it to unlock various cryptographic keys associated with the user. This + * primarily includes unlocking the user's credential-encrypted (CE) storage. It also includes + * deriving or decrypting the vendor auth secret and sending it to the AuthSecret HAL. + * <p> + * These tasks would normally be done when the LSKF is verified. This method is where these + * tasks are done when the user doesn't have an LSKF. It's called when the user is started. + * <p> + * Except on permission denied, this method doesn't throw an exception on failure. However, the + * last thing that it does is unlock CE storage, and whether CE storage has been successfully + * unlocked can be determined by {@link StorageManager#isCeStorageUnlocked()}. * <p> - * Whether the storage has been unlocked can be determined by - * {@link StorageManager#isUserKeyUnlocked()}. - * * Requires the {@link android.Manifest.permission#ACCESS_KEYGUARD_SECURE_STORAGE} permission. * - * @param userId the ID of the user whose storage to unlock + * @param userId the ID of the user whose keys to unlock */ public void unlockUserKeyIfUnsecured(@UserIdInt int userId) { try { |