@@ -119,7 +119,6 @@ static bool extra_root_certs_loaded = false;
119
119
template void SSLWrap<TLSWrap>::AddMethods(Environment* env,
120
120
Local<FunctionTemplate> t);
121
121
template void SSLWrap<TLSWrap>::ConfigureSecureContext(SecureContext* sc);
122
- template void SSLWrap<TLSWrap>::SetSNIContext(SecureContext* sc);
123
122
template int SSLWrap<TLSWrap>::SetCACerts(SecureContext* sc);
124
123
template void SSLWrap<TLSWrap>::MemoryInfo(MemoryTracker* tracker) const ;
125
124
template SSL_SESSION* SSLWrap<TLSWrap>::GetSessionCallback(
@@ -2425,12 +2424,7 @@ void SSLWrap<Base>::CertCbDone(const FunctionCallbackInfo<Value>& args) {
2425
2424
if (cons->HasInstance (ctx)) {
2426
2425
SecureContext* sc = Unwrap<SecureContext>(ctx.As <Object>());
2427
2426
CHECK_NOT_NULL (sc);
2428
- // XXX: There is a method w->SetSNIContext(sc), and you might think that
2429
- // it makes sense to call that here and make setting w->sni_context_ part
2430
- // of it. In fact, that passes the test suite, although SetSNIContext()
2431
- // performs a lot more operations.
2432
- // If anybody is familiar enough with the TLS code to know whether it makes
2433
- // sense, please do so or document why it doesn't.
2427
+ // Store the SNI context for later use.
2434
2428
w->sni_context_ = BaseObjectPtr<SecureContext>(sc);
2435
2429
2436
2430
if (UseSNIContext (w->ssl_ , sc) && !w->SetCACerts (sc)) {
@@ -2471,15 +2465,6 @@ void SSLWrap<Base>::DestroySSL() {
2471
2465
}
2472
2466
2473
2467
2474
- template <class Base >
2475
- void SSLWrap<Base>::SetSNIContext(SecureContext* sc) {
2476
- ConfigureSecureContext (sc);
2477
- CHECK_EQ (SSL_set_SSL_CTX (ssl_.get (), sc->ctx_ .get ()), sc->ctx_ .get ());
2478
-
2479
- SetCACerts (sc);
2480
- }
2481
-
2482
-
2483
2468
template <class Base >
2484
2469
int SSLWrap<Base>::SetCACerts(SecureContext* sc) {
2485
2470
int err = SSL_set1_verify_cert_store (ssl_.get (),
0 commit comments