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

Commit ce1d0ae6 authored by Automerger Merge Worker's avatar Automerger Merge Worker
Browse files

Merge "Revert "Fixing default behavior for keys requiring auth"" into rvc-dev...

Merge "Revert "Fixing default behavior for keys requiring auth"" into rvc-dev am: 291718cd am: 32d19158 am: 2da711e7 am: 586c9e5f

Change-Id: Ie9694055e9f20e3010a5dbf489da12111e6e78a9
parents 71d24064 586c9e5f
Loading
Loading
Loading
Loading
+2 −3
Original line number Original line Diff line number Diff line
@@ -764,9 +764,8 @@ public final class KeyGenParameterSpec implements AlgorithmParameterSpec, UserAu
        private @KeyProperties.BlockModeEnum String[] mBlockModes;
        private @KeyProperties.BlockModeEnum String[] mBlockModes;
        private boolean mRandomizedEncryptionRequired = true;
        private boolean mRandomizedEncryptionRequired = true;
        private boolean mUserAuthenticationRequired;
        private boolean mUserAuthenticationRequired;
        private int mUserAuthenticationValidityDurationSeconds = 0;
        private int mUserAuthenticationValidityDurationSeconds = -1;
        private @KeyProperties.AuthEnum int mUserAuthenticationType =
        private @KeyProperties.AuthEnum int mUserAuthenticationType;
                KeyProperties.AUTH_BIOMETRIC_STRONG;
        private boolean mUserPresenceRequired = false;
        private boolean mUserPresenceRequired = false;
        private byte[] mAttestationChallenge = null;
        private byte[] mAttestationChallenge = null;
        private boolean mUniqueIdIncluded = false;
        private boolean mUniqueIdIncluded = false;
+2 −3
Original line number Original line Diff line number Diff line
@@ -562,9 +562,8 @@ public final class KeyProtection implements ProtectionParameter, UserAuthArgs {
        private @KeyProperties.BlockModeEnum String[] mBlockModes;
        private @KeyProperties.BlockModeEnum String[] mBlockModes;
        private boolean mRandomizedEncryptionRequired = true;
        private boolean mRandomizedEncryptionRequired = true;
        private boolean mUserAuthenticationRequired;
        private boolean mUserAuthenticationRequired;
        private @KeyProperties.AuthEnum int mUserAuthenticationType =
        private @KeyProperties.AuthEnum int mUserAuthenticationType;
                KeyProperties.AUTH_BIOMETRIC_STRONG;
        private int mUserAuthenticationValidityDurationSeconds = -1;
        private int mUserAuthenticationValidityDurationSeconds = 0;
        private boolean mUserPresenceRequired = false;
        private boolean mUserPresenceRequired = false;
        private boolean mUserAuthenticationValidWhileOnBody;
        private boolean mUserAuthenticationValidWhileOnBody;
        private boolean mInvalidatedByBiometricEnrollment = true;
        private boolean mInvalidatedByBiometricEnrollment = true;
+2 −1
Original line number Original line Diff line number Diff line
@@ -165,7 +165,8 @@ public abstract class KeymasterUtils {
            }
            }
            args.addUnsignedLong(KeymasterDefs.KM_TAG_USER_SECURE_ID,
            args.addUnsignedLong(KeymasterDefs.KM_TAG_USER_SECURE_ID,
                    KeymasterArguments.toUint64(sid));
                    KeymasterArguments.toUint64(sid));
            args.addEnum(KeymasterDefs.KM_TAG_USER_AUTH_TYPE, spec.getUserAuthenticationType());
            args.addEnum(KeymasterDefs.KM_TAG_USER_AUTH_TYPE,
                    KeymasterDefs.HW_AUTH_PASSWORD | KeymasterDefs.HW_AUTH_BIOMETRIC);
            args.addUnsignedInt(KeymasterDefs.KM_TAG_AUTH_TIMEOUT,
            args.addUnsignedInt(KeymasterDefs.KM_TAG_AUTH_TIMEOUT,
                    spec.getUserAuthenticationValidityDurationSeconds());
                    spec.getUserAuthenticationValidityDurationSeconds());
            if (spec.isUserAuthenticationValidWhileOnBody()) {
            if (spec.isUserAuthenticationValidWhileOnBody()) {