summaryrefslogtreecommitdiffstats
path: root/ssl/ssl_lib.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2020-02-06 16:54:09 +0100
committerMatt Caswell <matt@openssl.org>2020-02-08 00:27:58 +0100
commit709b5e8a3e10963072ce390df7e736308853aa85 (patch)
treea3705aad1ecbfa1e100082d8eafb6c71ab93f1bb /ssl/ssl_lib.c
parentFix no-dh (diff)
downloadopenssl-709b5e8a3e10963072ce390df7e736308853aa85.tar.xz
openssl-709b5e8a3e10963072ce390df7e736308853aa85.zip
Fix no-engine
We don't need to check if an engine has a cipher/digest in a no-engine build. Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/11031)
Diffstat (limited to '')
-rw-r--r--ssl/ssl_lib.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c
index 977b599055..08fcd83ea7 100644
--- a/ssl/ssl_lib.c
+++ b/ssl/ssl_lib.c
@@ -5848,12 +5848,14 @@ const EVP_CIPHER *ssl_evp_cipher_fetch(OPENSSL_CTX *libctx,
int nid,
const char *properties)
{
+#ifndef OPENSSL_NO_ENGINE
/*
* If there is an Engine available for this cipher we use the "implicit"
* form to ensure we use that engine later.
*/
if (ENGINE_get_cipher_engine(nid) != NULL)
return EVP_get_cipherbynid(nid);
+#endif
/* Otherwise we do an explicit fetch */
return EVP_CIPHER_fetch(libctx, OBJ_nid2sn(nid), properties);
@@ -5891,12 +5893,14 @@ const EVP_MD *ssl_evp_md_fetch(OPENSSL_CTX *libctx,
int nid,
const char *properties)
{
+#ifndef OPENSSL_NO_ENGINE
/*
* If there is an Engine available for this digest we use the "implicit"
* form to ensure we use that engine later.
*/
if (ENGINE_get_digest_engine(nid) != NULL)
return EVP_get_digestbynid(nid);
+#endif
/* Otherwise we do an explicit fetch */
return EVP_MD_fetch(libctx, OBJ_nid2sn(nid), properties);