Skip to content

Commit 9d56af0

Browse files
JakujeNIIBE Yutaka
authored andcommitted
Revert "tests: Expect the OEAP tests to fail in FIPS mode."
This reverts commit 249ca43. The pubkey encryption has already separate explicit FIPS service indicator.
1 parent a7b5cab commit 9d56af0

File tree

2 files changed

+5
-22
lines changed

2 files changed

+5
-22
lines changed

tests/basic.c

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16892,33 +16892,29 @@ check_pubkey_crypt (int n, gcry_sexp_t skey, gcry_sexp_t pkey, int algo,
1689216892
"(flags oaep)",
1689316893
1,
1689416894
0,
16895-
0,
16896-
FLAG_NOFIPS },
16895+
0 },
1689716896
{ GCRY_PK_RSA,
1689816897
"(data\n (flags oaep)\n (hash-algo sha1)\n"
1689916898
" (value #11223344556677889900AA#))\n",
1690016899
"(flags oaep)(hash-algo sha1)",
1690116900
1,
1690216901
0,
16903-
0,
16904-
FLAG_NOFIPS },
16902+
0 },
1690516903
{ GCRY_PK_RSA,
1690616904
"(data\n (flags oaep)\n (hash-algo sha1)\n (label \"test\")\n"
1690716905
" (value #11223344556677889900AA#))\n",
1690816906
"(flags oaep)(hash-algo sha1)(label \"test\")",
1690916907
1,
1691016908
0,
16911-
0,
16912-
FLAG_NOFIPS },
16909+
0 },
1691316910
{ GCRY_PK_RSA,
1691416911
"(data\n (flags oaep)\n (hash-algo sha1)\n (label \"test\")\n"
1691516912
" (value #11223344556677889900AA#)\n"
1691616913
" (random-override #4253647587980912233445566778899019283747#))\n",
1691716914
"(flags oaep)(hash-algo sha1)(label \"test\")",
1691816915
1,
1691916916
0,
16920-
0,
16921-
FLAG_NOFIPS },
16917+
0 },
1692216918
{ 0,
1692316919
"(data\n (flags )\n" " (value #11223344556677889900AA#))\n",
1692416920
NULL,
@@ -16964,7 +16960,7 @@ check_pubkey_crypt (int n, gcry_sexp_t skey, gcry_sexp_t pkey, int algo,
1696416960
"(flags pkcs1)",
1696516961
1,
1696616962
0,
16967-
GPG_ERR_ENCODING_PROBLEM, FLAG_SPECIAL | FLAG_NOFIPS },
16963+
GPG_ERR_ENCODING_PROBLEM, FLAG_SPECIAL },
1696816964
{ 0,
1696916965
"(data\n (flags pss)\n"
1697016966
" (value #11223344556677889900AA#))\n",

tests/pkcs1v2.c

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -186,24 +186,11 @@ check_oaep (void)
186186
err = gcry_pk_encrypt (&ciph, plain, pub_key);
187187
if (err)
188188
{
189-
if (in_fips_mode)
190-
{
191-
gcry_sexp_release (plain);
192-
plain = NULL;
193-
continue;
194-
}
195189
show_sexp ("plain:\n", ciph);
196190
fail ("gcry_pk_encrypt failed: %s\n", gpg_strerror (err));
197191
}
198192
else
199193
{
200-
if (in_fips_mode)
201-
{
202-
fail ("The OAEP encryption unexpectedly worked in FIPS mode\n");
203-
gcry_sexp_release (plain);
204-
plain = NULL;
205-
continue;
206-
}
207194
if (extract_cmp_data (ciph, "a", tbl[tno].m[mno].encr,
208195
tbl[tno].m[mno].desc))
209196
{

0 commit comments

Comments
 (0)