]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
providers/implementations/keymgmt/ecx_kmgmt.c.in: remove PCT on ECX import
authorEugene Syromiatnikov <esyr@openssl.org>
Tue, 16 Sep 2025 14:25:33 +0000 (16:25 +0200)
committerTomas Mraz <tomas@openssl.org>
Thu, 18 Sep 2025 11:50:35 +0000 (13:50 +0200)
While PCT on import has been removed for DH, EC, RSA, and SLH-DSA,
ECX seems to be overlooked.  Correct that omission.

Complements: 7f7f75816f26 "import pct: remove import PCTs for most algorithms"
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
Reviewed-by: Paul Dale <ppzgs1@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/28573)

(cherry picked from commit 05d12fdd955d4cb3efc769becc3d5ceb9a322fdc)

providers/implementations/keymgmt/ecx_kmgmt.c

index e6d326a907055e1aeab17f11627b7554591a9acf..0ebe8b4d59b1f4f0d75f09b8b46c7439040f763d 100644 (file)
@@ -218,14 +218,6 @@ static int ecx_import(void *keydata, int selection, const OSSL_PARAM params[])
     include_private = selection & OSSL_KEYMGMT_SELECT_PRIVATE_KEY ? 1 : 0;
     ok = ok && ossl_ecx_key_fromdata(key, params, include_private);
 
-#ifdef FIPS_MODULE
-    if (ok > 0 && ecx_key_type_is_ed(key->type) && !ossl_fips_self_testing())
-        if (key->haspubkey && key->privkey != NULL) {
-            ok = ecd_fips140_pairwise_test(key, key->type, 1);
-            if (ok <= 0)
-                ossl_set_error_state(OSSL_SELF_TEST_TYPE_PCT_IMPORT);
-        }
-#endif  /* FIPS_MODULE */
     return ok;
 }