summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorShane Lontis <shane.lontis@oracle.com>2021-02-19 19:15:41 +1000
committerShane Lontis <shane.lontis@oracle.com>2021-02-26 10:32:22 +1000
commit94553e85b68af4513a8ee89cd2a0d4e044d75139 (patch)
tree2150abcbe848f0d1973b0186bd6864595e3f18a2 /test
parent2d968951227acd422f0e712035de3216d47fc980 (diff)
Fix external symbols for bn
Partial fix for #12964 This adds ossl_ names for symbols related to bn_* Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/14296)
Diffstat (limited to 'test')
-rw-r--r--test/bn_internal_test.c8
-rw-r--r--test/evp_libctx_test.c6
-rw-r--r--test/evp_pkey_provided_test.c8
3 files changed, 13 insertions, 9 deletions
diff --git a/test/bn_internal_test.c b/test/bn_internal_test.c
index 2dda2345cb..952369c7a1 100644
--- a/test/bn_internal_test.c
+++ b/test/bn_internal_test.c
@@ -34,7 +34,8 @@ static int test_is_prime_enhanced(void)
/* test passing a prime returns the correct status */
&& TEST_true(BN_set_word(bn, 11))
/* return extra parameters related to composite */
- && TEST_true(bn_miller_rabin_is_prime(bn, 10, ctx, NULL, 1, &status))
+ && TEST_true(ossl_bn_miller_rabin_is_prime(bn, 10, ctx, NULL, 1,
+ &status))
&& TEST_int_eq(status, BN_PRIMETEST_PROBABLY_PRIME);
BN_free(bn);
return ret;
@@ -53,7 +54,8 @@ static int test_is_composite_enhanced(int id)
ret = TEST_ptr(bn = BN_new())
/* negative tests for different composite numbers */
&& TEST_true(BN_set_word(bn, composites[id]))
- && TEST_true(bn_miller_rabin_is_prime(bn, 10, ctx, NULL, 1, &status))
+ && TEST_true(ossl_bn_miller_rabin_is_prime(bn, 10, ctx, NULL, 1,
+ &status))
&& TEST_int_ne(status, BN_PRIMETEST_PROBABLY_PRIME);
BN_free(bn);
@@ -78,7 +80,7 @@ static int test_bn_small_factors(void)
if (p > 751)
break;
}
- ret = TEST_BN_eq(bn_get0_small_factors(), b);
+ ret = TEST_BN_eq(ossl_bn_get0_small_factors(), b);
err:
BN_free(b);
return ret;
diff --git a/test/evp_libctx_test.c b/test/evp_libctx_test.c
index 302ec2c9b1..bd0ddb7371 100644
--- a/test/evp_libctx_test.c
+++ b/test/evp_libctx_test.c
@@ -93,7 +93,8 @@ static int test_dsa_param_keygen(int tstid)
* these 'safe primes' should not be used normally for dsa *.
*/
static const BIGNUM *bn[] = {
- &_bignum_dh2048_256_p, &_bignum_dh2048_256_q, &_bignum_dh2048_256_g
+ &ossl_bignum_dh2048_256_p, &ossl_bignum_dh2048_256_q,
+ &ossl_bignum_dh2048_256_g
};
/*
@@ -201,7 +202,8 @@ err:
static int test_dh_safeprime_param_keygen(int tstid)
{
static const BIGNUM *bn[] = {
- &_bignum_ffdhe2048_p, &_bignum_ffdhe2048_q, &_bignum_const_2
+ &ossl_bignum_ffdhe2048_p, &ossl_bignum_ffdhe2048_q,
+ &ossl_bignum_const_2
};
return do_dh_param_keygen(tstid, bn);
}
diff --git a/test/evp_pkey_provided_test.c b/test/evp_pkey_provided_test.c
index e2c28d3565..fd0dcdd38a 100644
--- a/test/evp_pkey_provided_test.c
+++ b/test/evp_pkey_provided_test.c
@@ -523,11 +523,11 @@ static int test_fromdata_dh_named_group(void)
&priv_out))
|| !TEST_BN_eq(priv, priv_out)
|| !TEST_true(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_P, &p))
- || !TEST_BN_eq(&_bignum_ffdhe2048_p, p)
+ || !TEST_BN_eq(&ossl_bignum_ffdhe2048_p, p)
|| !TEST_true(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_Q, &q))
|| !TEST_ptr(q)
|| !TEST_true(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_G, &g))
- || !TEST_BN_eq(&_bignum_const_2, g)
+ || !TEST_BN_eq(&ossl_bignum_const_2, g)
|| !TEST_false(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_COFACTOR,
&j))
|| !TEST_ptr_null(j)
@@ -667,11 +667,11 @@ static int test_fromdata_dh_fips186_4(void)
&priv_out))
|| !TEST_BN_eq(priv, priv_out)
|| !TEST_true(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_P, &p))
- || !TEST_BN_eq(&_bignum_ffdhe2048_p, p)
+ || !TEST_BN_eq(&ossl_bignum_ffdhe2048_p, p)
|| !TEST_true(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_Q, &q))
|| !TEST_ptr(q)
|| !TEST_true(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_G, &g))
- || !TEST_BN_eq(&_bignum_const_2, g)
+ || !TEST_BN_eq(&ossl_bignum_const_2, g)
|| !TEST_false(EVP_PKEY_get_bn_param(pk, OSSL_PKEY_PARAM_FFC_COFACTOR,
&j))
|| !TEST_ptr_null(j)