summaryrefslogtreecommitdiff
path: root/libs/androidfw/FileStream.cpp
diff options
context:
space:
mode:
author Eric Biggers <ebiggers@google.com> 2023-06-26 22:05:10 +0000
committer Eric Biggers <ebiggers@google.com> 2023-10-06 17:03:21 +0000
commit220d6a284ebe18675e9b017474c3b07e65be55ba (patch)
treeffab995c41e0a66174135e350be01ba42f25439e /libs/androidfw/FileStream.cpp
parentf258e777bc64e5c7b19b841c3fa5063b68204031 (diff)
Allow constructing a PIN LockscreenCredential with mInvalidChars
KeyguardManager#setLock() (both overloads) and LockSettingsShellCommand can try to set a PIN containing arbitrary characters. The check for digits-only happens in PasswordMetrics#validatePasswordMetrics(). However, due to one of my recent changes, before getting to that point, constructing the LockscreenCredential throws IllegalArgumentException if the PIN contains any chars outside ASCII 32–127. This is because I had thought this case would only be possible for PASSWORD. As it's needed for PIN too, allow this case. Bug: 219511761 Bug: 232900169 Bug: 243881358 Bug: 288904180 Test: atest LockscreenCredentialTest Change-Id: Icd101f2dbb0c700a0cc5442a81c0c9ac345737b3 Merged-In: Icd101f2dbb0c700a0cc5442a81c0c9ac345737b3 (cherry picked from commit a775edfa3acbf0612b1589ccd1e71e66314b8f90)
Diffstat (limited to 'libs/androidfw/FileStream.cpp')
0 files changed, 0 insertions, 0 deletions