crypto: remove deprecated ECDH calls w/ OpenSSL 1.1

These are both no-ops in OpenSSL 1.1.0.

PR-URL: https://github.com/nodejs/node/pull/16130
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Rod Vagg <rod@vagg.org>
This commit is contained in:
David Benjamin 2017-09-23 02:18:23 -04:00 committed by Rod Vagg
parent b54a4d871f
commit f7410405e4

View File

@ -1078,8 +1078,10 @@ void SecureContext::SetECDHCurve(const FunctionCallbackInfo<Value>& args) {
node::Utf8Value curve(env->isolate(), args[0]);
#if OPENSSL_VERSION_NUMBER < 0x10100000L
SSL_CTX_set_options(sc->ctx_, SSL_OP_SINGLE_ECDH_USE);
SSL_CTX_set_ecdh_auto(sc->ctx_, 1);
#endif
if (strcmp(*curve, "auto") == 0)
return;