From e72749b319703e730eb6df6d4e9405044d0f7ff5 Mon Sep 17 00:00:00 2001 From: Adam Majer Date: Wed, 21 Dec 2016 11:16:39 +0100 Subject: [PATCH] crypto: ability to select cert store at runtime PR-URL: https://github.com/nodejs/node/pull/8334 Backport-PR-URL: https://github.com/nodejs/node/pull/11794 Reviewed-By: Sam Roberts Reviewed-By: James M Snell Reviewed-By: Fedor Indutny --- doc/api/cli.md | 36 ++++++++++++++++++++++++++++++++++++ doc/node.1 | 25 +++++++++++++++++++++++++ src/node.cc | 25 ++++++++++++++++++++++++- src/node.h | 5 ++++- src/node_crypto.cc | 14 +++++++------- 5 files changed, 96 insertions(+), 9 deletions(-) diff --git a/doc/api/cli.md b/doc/api/cli.md index 74210a88eeac65..985feee2414dc0 100644 --- a/doc/api/cli.md +++ b/doc/api/cli.md @@ -243,6 +243,24 @@ Load an OpenSSL configuration file on startup. Among other uses, this can be used to enable FIPS-compliant crypto if Node.js is built with `./configure --openssl-fips`. +### `--use-openssl-ca`, `--use-bundled-ca` + + +Use OpenSSL's default CA store or use bundled Mozilla CA store as supplied by +current NodeJS version. The default store is selectable at build-time. + +Using OpenSSL store allows for external modifications of the store. For most +Linux and BSD distributions, this store is maintained by the distribution +maintainers and system administrators. OpenSSL CA store location is dependent on +configuration of the OpenSSL library but this can be altered at runtime using +environmental variables. + +The bundled CA store, as supplied by NodeJS, is a snapshot of Mozilla CA store +that is fixed at release time. It is identical on all supported platforms. + +See `SSL_CERT_DIR` and `SSL_CERT_FILE`. ### `--icu-data-dir=file`