diff options
author | Matt Caswell <matt@openssl.org> | 2021-07-19 16:17:50 +0100 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2021-07-22 13:52:46 +0200 |
commit | 929f651eaa763625eab602516706a1bf4ba3bc32 (patch) | |
tree | 4ecd5a579078b6a75e99f4c7952fe80c3a5a5367 /include/crypto | |
parent | 5dc6489bb6026b679eb6cbe696e4227da9c7032e (diff) |
Fix custom EVP_PKEY_METHOD implementations where no engine is present
It is possible to have a custom EVP_PKEY_METHOD implementation without
having an engine. In those cases we were failing to use that custom
implementation.
Fixes #16088
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Nicola Tuveri <nic.tuv@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/16118)
Diffstat (limited to 'include/crypto')
-rw-r--r-- | include/crypto/evp.h | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/include/crypto/evp.h b/include/crypto/evp.h index 3707977d9d..68aab33cae 100644 --- a/include/crypto/evp.h +++ b/include/crypto/evp.h @@ -22,19 +22,8 @@ */ #define EVP_MD_CTX_FLAG_KEEP_PKEY_CTX 0x0400 -/* - * An EVP_PKEY_CTX can have the following support states: - * - * Supports legacy implementations only: - * - * engine != NULL || keytype == NULL - * - * Supports provided implementations: - * - * engine == NULL && keytype != NULL - */ #define evp_pkey_ctx_is_legacy(ctx) \ - ((ctx)->engine != NULL || (ctx)->keytype == NULL) + ((ctx)->keymgmt == NULL) #define evp_pkey_ctx_is_provided(ctx) \ (!evp_pkey_ctx_is_legacy(ctx)) |