summaryrefslogtreecommitdiffstats
path: root/test/endecode_test.c
diff options
context:
space:
mode:
authorTomas Mraz <tomas@openssl.org>2022-09-13 22:38:30 +0200
committerPauli <pauli@openssl.org>2022-09-16 08:34:53 +1000
commite1289d90d0069ea1c3ea8ae80bfc3916077ec24e (patch)
tree9e8b5ce32338417fa988ecae7c25373550a4112d /test/endecode_test.c
parentc342004e07fd2c03a672f79353d13554fe0ffdaf (diff)
With fips provider 3.0.0 skip tests related to explicit curves handling
Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Shane Lontis <shane.lontis@oracle.com> Reviewed-by: Paul Dale <pauli@openssl.org> (Merged from https://github.com/openssl/openssl/pull/19201)
Diffstat (limited to 'test/endecode_test.c')
-rw-r--r--test/endecode_test.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/endecode_test.c b/test/endecode_test.c
index c139fe63be..14648287eb 100644
--- a/test/endecode_test.c
+++ b/test/endecode_test.c
@@ -47,6 +47,7 @@ OSSL_provider_init_fn ossl_legacy_provider_init;
static int default_libctx = 1;
static int is_fips = 0;
+static int is_fips_3_0_0 = 0;
static OSSL_LIB_CTX *testctx = NULL;
static OSSL_LIB_CTX *keyctx = NULL;
@@ -174,7 +175,7 @@ static int test_encode_decode(const char *file, const int line,
output_type, output_structure, pass, pcipher)))
goto end;
- if ((flags & FLAG_FAIL_IF_FIPS) != 0 && is_fips) {
+ if ((flags & FLAG_FAIL_IF_FIPS) != 0 && is_fips && !is_fips_3_0_0) {
if (TEST_false(decode_cb(file, line, (void **)&pkey2, encoded,
encoded_len, output_type, output_structure,
(flags & FLAG_DECODE_WITH_TYPE ? type : NULL),
@@ -1323,6 +1324,11 @@ int setup_tests(void)
return 0;
}
+ /* FIPS(3.0.0): provider imports explicit params but they won't work #17998 */
+ is_fips_3_0_0 = fips_provider_version_eq(testctx, 3, 0, 0);
+ if (is_fips_3_0_0 < 0)
+ return 0;
+
#ifdef STATIC_LEGACY
/*
* This test is always statically linked against libcrypto. We must not