Skip to content

Commit cca9cb7

Browse files
Brahmaji Khyperb1iss
authored andcommitted
keyguard: Fix password doesnot sanitize after verification
Add sanitizePassword call after the verification is success so that the password/pin/pattern goes to default_password. This will avoid security vulnerability. Change-Id: I711b9e38e1812bad9fa7ab8d0ab9e35963138a69
1 parent 931814d commit cca9cb7

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

packages/Keyguard/src/com/android/keyguard/KeyguardAbsKeyInputView.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,7 @@ public void onChecked(boolean matched, int timeoutMs) {
147147

148148
private void onPasswordChecked(boolean matched, int timeoutMs, boolean isValidPassword) {
149149
if (matched) {
150+
mLockPatternUtils.sanitizePassword();
150151
mDismissing = true;
151152
mCallback.reportUnlockAttempt(true, 0);
152153
mCallback.dismiss(true);

packages/Keyguard/src/com/android/keyguard/KeyguardPatternView.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,7 @@ public void onChecked(boolean matched, int timeoutMs) {
262262

263263
private void onPatternChecked(boolean matched, int timeoutMs, boolean isValidPattern) {
264264
if (matched) {
265+
mLockPatternUtils.sanitizePassword();
265266
mCallback.reportUnlockAttempt(true, 0);
266267
mLockPatternView.setDisplayMode(LockPatternView.DisplayMode.Correct);
267268
mCallback.dismiss(true);

0 commit comments

Comments
 (0)