diff options
author | Shane Lontis <shane.lontis@oracle.com> | 2021-04-08 12:05:14 +0200 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2021-04-15 18:42:04 +0200 |
commit | a732a4c329144f0b4c60372d9b7106c6b88ddd9f (patch) | |
tree | f5dd1f0e6d8ebfb89a3ec536b94a8b1297148d6a /crypto/evp/keymgmt_lib.c | |
parent | Add OID for mdc2WithRSASignature and remove related TODO 3.0 (diff) | |
download | openssl-a732a4c329144f0b4c60372d9b7106c6b88ddd9f.tar.xz openssl-a732a4c329144f0b4c60372d9b7106c6b88ddd9f.zip |
Add EVP_PKEY_todata() and EVP_PKEY_export() functions.
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/14800)
Diffstat (limited to 'crypto/evp/keymgmt_lib.c')
-rw-r--r-- | crypto/evp/keymgmt_lib.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/crypto/evp/keymgmt_lib.c b/crypto/evp/keymgmt_lib.c index 80aea65e88..f196bc4d88 100644 --- a/crypto/evp/keymgmt_lib.c +++ b/crypto/evp/keymgmt_lib.c @@ -80,6 +80,8 @@ EVP_PKEY *evp_keymgmt_util_make_pkey(EVP_KEYMGMT *keymgmt, void *keydata) int evp_keymgmt_util_export(const EVP_PKEY *pk, int selection, OSSL_CALLBACK *export_cb, void *export_cbarg) { + if (pk == NULL || export_cb == NULL) + return 0; return evp_keymgmt_export(pk->keymgmt, pk->keydata, selection, export_cb, export_cbarg); } |