summaryrefslogtreecommitdiffstats
path: root/crypto/evp/p_lib.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2018-03-15 12:19:16 +0000
committerMatt Caswell <matt@openssl.org>2018-03-15 12:47:27 +0000
commitf929439f61e7e4cf40e06de56880758b5344f198 (patch)
tree648214966a8152d218f81d3420b56fffdf744da4 /crypto/evp/p_lib.c
parente8f9f08f17e4f15ee737115d336d110dc8dea0ec (diff)
Rename EVP_PKEY_new_private_key()/EVP_PKEY_new_public_key()
Renamed to EVP_PKEY_new_raw_private_key()/EVP_new_raw_public_key() as per feedback. Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/5520)
Diffstat (limited to 'crypto/evp/p_lib.c')
-rw-r--r--crypto/evp/p_lib.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/crypto/evp/p_lib.c b/crypto/evp/p_lib.c
index 073d2df888..c1b3393aa9 100644
--- a/crypto/evp/p_lib.c
+++ b/crypto/evp/p_lib.c
@@ -220,9 +220,9 @@ static int pkey_set_type(EVP_PKEY *pkey, ENGINE *e, int type, const char *str,
return 1;
}
-EVP_PKEY *EVP_PKEY_new_private_key(int type, ENGINE *e,
- const unsigned char *priv,
- size_t len)
+EVP_PKEY *EVP_PKEY_new_raw_private_key(int type, ENGINE *e,
+ const unsigned char *priv,
+ size_t len)
{
EVP_PKEY *ret = EVP_PKEY_new();
@@ -233,13 +233,13 @@ EVP_PKEY *EVP_PKEY_new_private_key(int type, ENGINE *e,
}
if (ret->ameth->set_priv_key == NULL) {
- EVPerr(EVP_F_EVP_PKEY_NEW_PRIVATE_KEY,
+ EVPerr(EVP_F_EVP_PKEY_NEW_RAW_PRIVATE_KEY,
EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE);
goto err;
}
if (!ret->ameth->set_priv_key(ret, priv, len)) {
- EVPerr(EVP_F_EVP_PKEY_NEW_PRIVATE_KEY, EVP_R_KEY_SETUP_FAILED);
+ EVPerr(EVP_F_EVP_PKEY_NEW_RAW_PRIVATE_KEY, EVP_R_KEY_SETUP_FAILED);
goto err;
}
@@ -250,9 +250,9 @@ EVP_PKEY *EVP_PKEY_new_private_key(int type, ENGINE *e,
return NULL;
}
-EVP_PKEY *EVP_PKEY_new_public_key(int type, ENGINE *e,
- const unsigned char *pub,
- size_t len)
+EVP_PKEY *EVP_PKEY_new_raw_public_key(int type, ENGINE *e,
+ const unsigned char *pub,
+ size_t len)
{
EVP_PKEY *ret = EVP_PKEY_new();
@@ -263,13 +263,13 @@ EVP_PKEY *EVP_PKEY_new_public_key(int type, ENGINE *e,
}
if (ret->ameth->set_pub_key == NULL) {
- EVPerr(EVP_F_EVP_PKEY_NEW_PUBLIC_KEY,
+ EVPerr(EVP_F_EVP_PKEY_NEW_RAW_PUBLIC_KEY,
EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE);
goto err;
}
if (!ret->ameth->set_pub_key(ret, pub, len)) {
- EVPerr(EVP_F_EVP_PKEY_NEW_PUBLIC_KEY, EVP_R_KEY_SETUP_FAILED);
+ EVPerr(EVP_F_EVP_PKEY_NEW_RAW_PUBLIC_KEY, EVP_R_KEY_SETUP_FAILED);
goto err;
}