Provide better API methods that can provide face/fp auth status
1. `isFingerprintAuthUsuallyAllowed` is true when fp is enrolled and is not disabled through device policy 2. `isFingerprintAuthCurrentlyAllowed` is true when `isFingerprintAuthUsuallyAllowed` is true and strong auth flags don't restrict fp auth 3. `isFaceAuthUsuallyAllowed` is true when face is enrolled, not disabled by device policy and enabled in biometricManager 4. `isFaceAuthCurrentlyAllowed` is true when `isFaceAuthUsuallyAllowed` is true and face auth is allowed in current posture and strong auth flags don't prevent face auth from running a. If face auth is class3 then this will rely on strong biometric allowed strong auth flag b. If face auth is not class3 then this will rely on non strong biometric allowed strong auth flag Motivation for the change: 1. Modern arch replacement for methods like KeyguardUpdateMonitor `isUnlockingWithFingerprintAllowed` and `isUnlockingWithBiometricAllowed` 2. `KeyguardUpdateMonitor#isUnlockingWithBiometricAllowed` doesn't actually check for enrollment state, which is the root cause of the bug. 3. In all places where we check if fingerprint is enrolled, we always check if fp is enabled and if fp is allowed by strong auth flags. Same for face as well. Bug: 293472698 Test: atest BouncerMessageRepositoryTest Test: atest AlternateBouncerInteractorTest Test: atest BiometricSettingsRepositoryTest Test: atest DeviceEntryFaceAuthRepositoryTest Change-Id: I9ae5e54aa473ff6c02d551607a3c0907585aa6a6
Loading
Please register or sign in to comment