From c235c62ff052d6422a5d33ed22f0834190bd2ec3 Mon Sep 17 00:00:00 2001 From: Valerio Setti Date: Tue, 8 Sep 2026 18:06:58 +0200 Subject: [PATCH] crypto_knowledge: make HASH_ALGS_WITHOUT_OID a frozenset() Signed-off-by: Valerio Setti --- scripts/mbedtls_framework/crypto_knowledge.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/mbedtls_framework/crypto_knowledge.py b/scripts/mbedtls_framework/crypto_knowledge.py index a6301ba00..c3a07ffa4 100644 --- a/scripts/mbedtls_framework/crypto_knowledge.py +++ b/scripts/mbedtls_framework/crypto_knowledge.py @@ -485,13 +485,13 @@ class Algorithm: return False return kdf_alg in self.KEY_DERIVATIONS_INCOMPATIBLE_WITH_AGREEMENT - HASH_ALGS_WITHOUT_OID = [ + HASH_ALGS_WITHOUT_OID = frozenset([ 'PSA_ALG_BLAKE2S_HASH256', 'PSA_ALG_BLAKE2B_HASH512', 'PSA_ALG_AES_MMO_ZIGBEE', 'PSA_ALG_ASCON_HASH256', 'PSA_ALG_SHAKE256_512', - ] + ]) def is_valid_rsa_alg_with_hash(self) -> bool: """Whether the specified combinaton of RSA_PKCS1V15_SIGN() and hash is supported. Rationale: there are hash algorithms for which OID is not standardized (or not yet),