aboutsummaryrefslogtreecommitdiff
path: root/crypto/rsa/rsa_gen.c
diff options
context:
space:
mode:
authorEnji Cooper <ngie@FreeBSD.org>2025-08-08 19:24:09 +0000
committerEnji Cooper <ngie@FreeBSD.org>2025-08-08 19:33:57 +0000
commitfbc35f82f0eca4571df0d753da74571e01ace763 (patch)
treeb1140e447e6c40c2bc65e7fc3413664fe98c3666 /crypto/rsa/rsa_gen.c
parent1095efe41feed8ea5a6fe5ca123c347ae0914801 (diff)
Diffstat (limited to 'crypto/rsa/rsa_gen.c')
-rw-r--r--crypto/rsa/rsa_gen.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/crypto/rsa/rsa_gen.c b/crypto/rsa/rsa_gen.c
index f76bb7748369..32084a822cac 100644
--- a/crypto/rsa/rsa_gen.c
+++ b/crypto/rsa/rsa_gen.c
@@ -734,3 +734,18 @@ err:
return ret;
}
+
+#ifdef FIPS_MODULE
+int ossl_rsa_key_pairwise_test(RSA *rsa)
+{
+ OSSL_CALLBACK *stcb;
+ void *stcbarg;
+ int res;
+
+ OSSL_SELF_TEST_get_callback(rsa->libctx, &stcb, &stcbarg);
+ res = rsa_keygen_pairwise_test(rsa, stcb, stcbarg);
+ if (res <= 0)
+ ossl_set_error_state(OSSL_SELF_TEST_TYPE_PCT);
+ return res;
+}
+#endif /* FIPS_MODULE */