File tree Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -2466,7 +2466,7 @@ void SSLWrap<Base>::CertCbDone(const FunctionCallbackInfo<Value>& args) {
2466
2466
// Store the SNI context for later use.
2467
2467
w->sni_context_ = BaseObjectPtr<SecureContext>(sc);
2468
2468
2469
- if (UseSNIContext (w->ssl_ , sc ) && !w->SetCACerts (sc)) {
2469
+ if (UseSNIContext (w->ssl_ , w-> sni_context_ ) && !w->SetCACerts (sc)) {
2470
2470
// Not clear why sometimes we throw error, and sometimes we call
2471
2471
// onerror(). Both cause .destroy(), but onerror does a bit more.
2472
2472
unsigned long err = ERR_get_error (); // NOLINT(runtime/int)
Original file line number Diff line number Diff line change
1
+ #include " base_object-inl.h"
1
2
#include " env-inl.h"
2
3
#include " node_buffer.h"
3
4
#include " node_crypto.h"
@@ -223,7 +224,7 @@ long VerifyPeerCertificate( // NOLINT(runtime/int)
223
224
return err;
224
225
}
225
226
226
- int UseSNIContext (const SSLPointer& ssl, SecureContext* context) {
227
+ int UseSNIContext (const SSLPointer& ssl, BaseObjectPtr< SecureContext> context) {
227
228
SSL_CTX* ctx = context->ctx_ .get ();
228
229
X509* x509 = SSL_CTX_get0_certificate (ctx);
229
230
EVP_PKEY* pkey = SSL_CTX_get0_privatekey (ctx);
Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ long VerifyPeerCertificate( // NOLINT(runtime/int)
71
71
const SSLPointer& ssl,
72
72
long def = X509_V_ERR_UNSPECIFIED); // NOLINT(runtime/int)
73
73
74
- int UseSNIContext (const SSLPointer& ssl, SecureContext* context);
74
+ int UseSNIContext (const SSLPointer& ssl, BaseObjectPtr< SecureContext> context);
75
75
76
76
const char * GetClientHelloALPN (const SSLPointer& ssl);
77
77
You can’t perform that action at this time.
0 commit comments