Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a603a300 authored by Kevin Chyn's avatar Kevin Chyn
Browse files

Check for null HAT and add logging

Bug: 154364967

Test: atest com.android.server.biometrics
Change-Id: I7dfe5dd8e740eef0fc74cd2e68a19dc35eb2c49e
parent 9e34dce8
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -551,11 +551,17 @@ final class AuthSession {
        try {
            switch (reason) {
                case BiometricPrompt.DISMISSED_REASON_CREDENTIAL_CONFIRMED:
                    if (credentialAttestation != null) {
                        mKeyStore.addAuthToken(credentialAttestation);
                    } else {
                        Slog.e(TAG, "credentialAttestation is null");
                    }
                case BiometricPrompt.DISMISSED_REASON_BIOMETRIC_CONFIRMED:
                case BiometricPrompt.DISMISSED_REASON_BIOMETRIC_CONFIRM_NOT_REQUIRED:
                    if (mTokenEscrow != null) {
                        mKeyStore.addAuthToken(mTokenEscrow);
                    } else {
                        Slog.e(TAG, "mTokenEscrow is null");
                    }
                    mClientReceiver.onAuthenticationSucceeded(
                            Utils.getAuthenticationTypeForResult(reason));