summaryrefslogtreecommitdiffstats
path: root/test/drbg_cavs_test.c
diff options
context:
space:
mode:
authorPauli <paul.dale@oracle.com>2019-04-11 08:52:22 +1000
committerPauli <paul.dale@oracle.com>2019-04-11 08:52:22 +1000
commit6c7d80ab3b2a13074ca270a6d056c59ac431155a (patch)
treea44ab97f1136735d7147b377b13cd69c53f65bc2 /test/drbg_cavs_test.c
parent3a86f1db282569c538273cc48462a3fa5fcffa39 (diff)
Reseeding without derivation function is not supported in FIPS mode.
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> (Merged from https://github.com/openssl/openssl/pull/8648)
Diffstat (limited to 'test/drbg_cavs_test.c')
-rw-r--r--test/drbg_cavs_test.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/drbg_cavs_test.c b/test/drbg_cavs_test.c
index 99d44725b1..8138269bff 100644
--- a/test/drbg_cavs_test.c
+++ b/test/drbg_cavs_test.c
@@ -254,6 +254,11 @@ static int test_cavs_kats(const struct drbg_kat *test[], int i)
const struct drbg_kat *td = test[i];
int rv = 0;
+#ifdef FIPS_MODE
+ /* FIPS mode doesn't support instantiating without a derivation function */
+ if ((td->flags & USE_DF) == 0)
+ return 1;
+#endif
switch (td->type) {
case NO_RESEED:
if (!single_kat_no_reseed(td))