Ignore INVALID tags in generated key characteristics.
INVALID tags are added for unsupported key parameters in the resulting
key characteristics from backend implementation. Changes are made to
ignore the INVALID tags while validating key characteristics.
Bug: 347810234
Bug: 351968535
Test: atest keystore2_client_tests
Change-Id: Idcf24d26f7217bc0aaaa8acb1b830e7b9dc0d33f
diff --git a/keystore2/test_utils/key_generations.rs b/keystore2/test_utils/key_generations.rs
index fdb2afb..c4161c0 100644
--- a/keystore2/test_utils/key_generations.rs
+++ b/keystore2/test_utils/key_generations.rs
@@ -401,9 +401,8 @@
) {
// Make sure key authorizations contains only `ALLOWED_TAGS_IN_KEY_AUTHS`
authorizations.iter().all(|auth| {
- // Ignore `INVALID` tag if the backend is Keymaster and not KeyMint.
- // Keymaster allows INVALID tag for unsupported key parameters.
- if sl.is_keymaster() && auth.keyParameter.tag == Tag::INVALID {
+ // Ignore `INVALID` tag
+ if auth.keyParameter.tag == Tag::INVALID {
return true;
}
assert!(