Skip to content

Commit 15664c8

Browse files
committed
Deduce tls temp curve from certificate strength
1 parent 92913c4 commit 15664c8

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

src/node_crypto.cc

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1381,11 +1381,9 @@ void SecureContext::SetECDHCurve(const FunctionCallbackInfo<Value>& args) {
13811381

13821382
node::Utf8Value curve(env->isolate(), args[0]);
13831383

1384-
if (strcmp(*curve, "from_certificate") == 0)
1384+
if (strcmp(*curve, "auto") == 0) {
13851385
return set_settings_from_certificate(env, sc->ctx_.get());
1386-
1387-
if (strcmp(*curve, "auto") == 0)
1388-
return;
1386+
}
13891387

13901388
if (!SSL_CTX_set1_curves_list(sc->ctx_.get(), *curve))
13911389
return env->ThrowError("Failed to set ECDH curve");

0 commit comments

Comments
 (0)