summaryrefslogtreecommitdiffstats
path: root/crypto/evp/p_dec.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2021-03-02 15:52:00 +0000
committerMatt Caswell <matt@openssl.org>2021-03-08 15:13:09 +0000
commit7bc0fdd3fd4535e06c35b92d71afab9a6de94cc5 (patch)
tree2e57cd75e2b81a4ae2bc8d375096e094f8b5b0e5 /crypto/evp/p_dec.c
parentcc57dc962516410f6269023c8a93913617414b5e (diff)
Make the EVP_PKEY_get0* functions have a const return type
OTC have decided that the EVP_PKEY_get0* functions should have a const return type. This is a breaking change to emphasise that these values should be considered as immutable. Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Shane Lontis <shane.lontis@oracle.com> Reviewed-by: Paul Dale <pauli@openssl.org> (Merged from https://github.com/openssl/openssl/pull/14319)
Diffstat (limited to 'crypto/evp/p_dec.c')
-rw-r--r--crypto/evp/p_dec.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/evp/p_dec.c b/crypto/evp/p_dec.c
index 6ac344e394..2e90705656 100644
--- a/crypto/evp/p_dec.c
+++ b/crypto/evp/p_dec.c
@@ -16,6 +16,7 @@
#include <openssl/evp.h>
#include <openssl/objects.h>
#include <openssl/x509.h>
+#include "crypto/evp.h"
int EVP_PKEY_decrypt_old(unsigned char *key, const unsigned char *ek, int ekl,
EVP_PKEY *priv)
@@ -28,7 +29,7 @@ int EVP_PKEY_decrypt_old(unsigned char *key, const unsigned char *ek, int ekl,
}
ret =
- RSA_private_decrypt(ekl, ek, key, EVP_PKEY_get0_RSA(priv),
+ RSA_private_decrypt(ekl, ek, key, evp_pkey_get0_RSA_int(priv),
RSA_PKCS1_PADDING);
err:
return ret;