fix(shim): restore nspace attest key lookup

Reverts 5f72acb. The nspace attestation key lookup was part of
the score-4 baseline and closes a real NPE on KEY_ID-domain
references where the alias field is null. Reverted in error
during the score-4-to-14 rollback; restoring to match the
working baseline.
This commit is contained in:
Enginex0
2026-05-19 14:35:19 +01:00
parent 2704eff797
commit 0b2c34ff8c
@@ -495,7 +495,8 @@ class KeyMintSecurityLevelInterceptor(
ConfigurationManager.shouldGenerate(callingUid) || ConfigurationManager.shouldGenerate(callingUid) ||
(ConfigurationManager.shouldPatch(callingUid) && isAttestKeyRequest) || (ConfigurationManager.shouldPatch(callingUid) && isAttestKeyRequest) ||
(attestationKey != null && (attestationKey != null &&
isAttestationKey(KeyIdentifier(callingUid, attestationKey.alias))) (attestationKey.alias?.let { isAttestationKey(KeyIdentifier(callingUid, it)) }
?: attestationKeys.any { kid -> kid.uid == callingUid && generatedKeys[kid]?.nspace == attestationKey.nspace }))
val isAuto = ConfigurationManager.isAutoMode(callingUid) val isAuto = ConfigurationManager.isAutoMode(callingUid)