From 4a9fe33c8e12f4fefae0471c0834f8e674dc7e4e Mon Sep 17 00:00:00 2001 From: Tomas Mraz Date: Wed, 7 Apr 2021 19:35:13 +0200 Subject: Implement provider-side keymgmt_dup function To avoid mutating key data add OSSL_FUNC_KEYMGMT_DUP function to the provider API and implement it for all asym-key key managements. Use it when copying everything to an empty EVP_PKEY which is the case with EVP_PKEY_dup(). Fixes #14658 Reviewed-by: Shane Lontis (Merged from https://github.com/openssl/openssl/pull/14793) --- include/crypto/rsa.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/crypto/rsa.h') diff --git a/include/crypto/rsa.h b/include/crypto/rsa.h index 73bf03f615..8c6ce49a7d 100644 --- a/include/crypto/rsa.h +++ b/include/crypto/rsa.h @@ -63,6 +63,7 @@ int ossl_rsa_set0_all_params(RSA *r, const STACK_OF(BIGNUM) *primes, int ossl_rsa_get0_all_params(RSA *r, STACK_OF(BIGNUM_const) *primes, STACK_OF(BIGNUM_const) *exps, STACK_OF(BIGNUM_const) *coeffs); +RSA *ossl_rsa_dup(const RSA *rsa); int ossl_rsa_todata(RSA *rsa, OSSL_PARAM_BLD *bld, OSSL_PARAM params[]); int ossl_rsa_fromdata(RSA *rsa, const OSSL_PARAM params[]); -- cgit v1.2.3