Skip to content

Commit 61e1ac0

Browse files
codebytereaduh95
authored andcommitted
crypto: enable NODE_EXTRA_CA_CERTS with BoringSSL
PR-URL: #52217 Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Yagiz Nizipli <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
1 parent 014bf01 commit 61e1ac0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/node.cc

+4-3
Original file line numberDiff line numberDiff line change
@@ -1084,7 +1084,8 @@ InitializeOncePerProcessInternal(const std::vector<std::string>& args,
10841084
}
10851085

10861086
if (!(flags & ProcessInitializationFlags::kNoInitOpenSSL)) {
1087-
#if HAVE_OPENSSL && !defined(OPENSSL_IS_BORINGSSL)
1087+
#if HAVE_OPENSSL
1088+
#ifndef OPENSSL_IS_BORINGSSL
10881089
auto GetOpenSSLErrorString = []() -> std::string {
10891090
std::string ret;
10901091
ERR_print_errors_cb(
@@ -1184,13 +1185,13 @@ InitializeOncePerProcessInternal(const std::vector<std::string>& args,
11841185
CHECK(crypto::CSPRNG(buffer, length).is_ok());
11851186
return true;
11861187
});
1187-
1188+
#endif // !defined(OPENSSL_IS_BORINGSSL)
11881189
{
11891190
std::string extra_ca_certs;
11901191
if (credentials::SafeGetenv("NODE_EXTRA_CA_CERTS", &extra_ca_certs))
11911192
crypto::UseExtraCaCerts(extra_ca_certs);
11921193
}
1193-
#endif // HAVE_OPENSSL && !defined(OPENSSL_IS_BORINGSSL)
1194+
#endif // HAVE_OPENSSL
11941195
}
11951196

11961197
if (!(flags & ProcessInitializationFlags::kNoInitializeNodeV8Platform)) {

0 commit comments

Comments
 (0)