diff options
author | Peiwei Hu <jlu.hpw@foxmail.com> | 2022-05-24 17:57:33 +0200 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2022-06-02 11:06:41 +0200 |
commit | 2cba2e160d5b028e4a777e8038744a8bc4280629 (patch) | |
tree | 806dd88d75132a8b1b91c29c171f600885a75efe /test/acvp_test.c | |
parent | Fix the check of evp_pkey_ctx_set_params_strict (diff) | |
download | openssl-2cba2e160d5b028e4a777e8038744a8bc4280629.tar.xz openssl-2cba2e160d5b028e4a777e8038744a8bc4280629.zip |
Fix the checks of EVP_PKEY_CTX_set/get_* functions
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18399)
Diffstat (limited to 'test/acvp_test.c')
-rw-r--r-- | test/acvp_test.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/acvp_test.c b/test/acvp_test.c index 7617918a66..45509095af 100644 --- a/test/acvp_test.c +++ b/test/acvp_test.c @@ -1091,9 +1091,9 @@ static int rsa_keygen_test(int id) if (!TEST_ptr(ctx = EVP_PKEY_CTX_new_from_name(libctx, "RSA", NULL)) || !TEST_ptr(e_bn = BN_bin2bn(tst->e, tst->e_len, NULL)) || !TEST_int_gt(EVP_PKEY_keygen_init(ctx), 0) - || !TEST_true(EVP_PKEY_CTX_set_params(ctx, params)) - || !TEST_true(EVP_PKEY_CTX_set_rsa_keygen_bits(ctx, tst->mod)) - || !TEST_true(EVP_PKEY_CTX_set1_rsa_keygen_pubexp(ctx, e_bn)) + || !TEST_int_gt(EVP_PKEY_CTX_set_params(ctx, params), 0) + || !TEST_int_gt(EVP_PKEY_CTX_set_rsa_keygen_bits(ctx, tst->mod), 0) + || !TEST_int_gt(EVP_PKEY_CTX_set1_rsa_keygen_pubexp(ctx, e_bn), 0) || !TEST_int_gt(EVP_PKEY_keygen(ctx, &pkey), 0) || !TEST_true(pkey_get_bn_bytes(pkey, OSSL_PKEY_PARAM_RSA_TEST_P1, &p1, &p1_len)) |