Keystore: make KeyUsage checks more lenient

The CTS tests covering key attestation were turned on for StrongBox in
Android 15 (aosp/2870494).

However, some existing implementations of StrongBox have incorrect
behaviour around the `KeyUsage` X.509 extension in the attestation
certificate.

So loosen the checks for StrongBox on vendor API level <= Android 14.

Adapted from aosp/3502995

Bug: 393501832
Bug: 397547226
Test: atest CtsKeystoreTestCases:android.keystore.cts.KeyAttestationTest
Flag: EXEMPT bug fix
Change-Id: Idc5f5e50ba278b41ef3825453013534dae8d0bd1
Merged-In: Idc5f5e50ba278b41ef3825453013534dae8d0bd1
1 file changed