From c8faee8c0b658e462c8bb2ec8bf6ec208c57279b Mon Sep 17 00:00:00 2001 From: Tim Jacomb Date: Mon, 13 Jan 2025 11:16:01 +0000 Subject: [PATCH] crypto: added support for reading certificates from macOS system store --- doc/api/cli.md | 8 + doc/api/tls.md | 3 + node.gypi | 5 +- src/crypto/crypto_context.cc | 320 +++++++++++++++++- src/node_options.cc | 4 + src/node_options.h | 1 + test/parallel/parallel.status | 3 + test/parallel/test-cli-node-options.js | 3 + test/parallel/test-cli-node-print-help.js | 2 +- test/parallel/test-native-certs-macos.mjs | 47 +++ ...rocess-env-allowed-flags-are-documented.js | 1 + 11 files changed, 388 insertions(+), 9 deletions(-) create mode 100644 test/parallel/test-native-certs-macos.mjs diff --git a/doc/api/cli.md b/doc/api/cli.md index 16ec96ec50ca35..ececfcefb687c7 100644 --- a/doc/api/cli.md +++ b/doc/api/cli.md @@ -2861,6 +2861,13 @@ The following values are valid for `mode`: * `silent`: If supported by the OS, mapping will be attempted. Failure to map will be ignored and will not be reported. +### `--use-system-ca` + +Node.js uses the trusted CA certificates present in the system store along with +the `--use-bundled-ca`, `--use-openssl-ca` options. + +This option is available to macOS only. + ### `--v8-options`