diff options
author | Richard Levitte <levitte@openssl.org> | 2020-07-30 10:09:43 +0200 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2020-08-20 12:37:35 +0200 |
commit | 2274d22d39fd65b83c9c969cba86c8f03b3e0bec (patch) | |
tree | dd86a9ea759bc5d2d1bd541afe0d28a929018e6d /crypto/err | |
parent | 6cc1dfca88c565ddacd9ea9aa8261ef9c0c37335 (diff) |
STORE: Distinguish public keys from private keys
While public keys and private keys use the same type (EVP_PKEY), just
with different contents, callers still need to distinguish between the
two to be able to know what functions to call with them (for example,
to be able to choose between EVP_PKEY_print_private() and
EVP_PKEY_print_public()).
The OSSL_STORE backend knows what it loaded, so it has the capacity to
inform.
Note that the same as usual still applies, that a private key EVP_PKEY
contains the public parts, but not necessarily the other way around.
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/12673)
Diffstat (limited to 'crypto/err')
-rw-r--r-- | crypto/err/openssl.txt | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/err/openssl.txt b/crypto/err/openssl.txt index 7431248d8f..e83f1013ec 100644 --- a/crypto/err/openssl.txt +++ b/crypto/err/openssl.txt @@ -2717,8 +2717,9 @@ OSSL_STORE_R_LOADER_INCOMPLETE:116:loader incomplete OSSL_STORE_R_LOADING_STARTED:117:loading started OSSL_STORE_R_NOT_A_CERTIFICATE:100:not a certificate OSSL_STORE_R_NOT_A_CRL:101:not a crl -OSSL_STORE_R_NOT_A_KEY:102:not a key OSSL_STORE_R_NOT_A_NAME:103:not a name +OSSL_STORE_R_NOT_A_PRIVATE_KEY:102:not a private key +OSSL_STORE_R_NOT_A_PUBLIC_KEY:122:not a public key OSSL_STORE_R_NOT_PARAMETERS:104:not parameters OSSL_STORE_R_PASSPHRASE_CALLBACK_ERROR:114:passphrase callback error OSSL_STORE_R_PATH_MUST_BE_ABSOLUTE:108:path must be absolute |