crypto: enable auto cert chaining for BoringSSL
OpenSSL enables this feature by default, but BoringSSL doesn't. This change makes it so that when building node with BoringSSL, the behaviour matches OpenSSL's. PR-URL: https://github.com/nodejs/node/pull/22110 Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
This commit is contained in:
parent
c9c4550dd4
commit
7dae8729aa
@ -463,6 +463,11 @@ void SecureContext::Init(const FunctionCallbackInfo<Value>& args) {
|
||||
SSL_CTX_set_options(sc->ctx_.get(), SSL_OP_NO_SSLv2);
|
||||
SSL_CTX_set_options(sc->ctx_.get(), SSL_OP_NO_SSLv3);
|
||||
|
||||
// Enable automatic cert chaining. This is enabled by default in OpenSSL, but
|
||||
// disabled by default in BoringSSL. Enable it explicitly to make the
|
||||
// behavior match when Node is built with BoringSSL.
|
||||
SSL_CTX_clear_mode(sc->ctx_.get(), SSL_MODE_NO_AUTO_CHAIN);
|
||||
|
||||
// SSL session cache configuration
|
||||
SSL_CTX_set_session_cache_mode(sc->ctx_.get(),
|
||||
SSL_SESS_CACHE_SERVER |
|
||||
|
Loading…
x
Reference in New Issue
Block a user