Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions doc/api/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,9 @@ network by default.
Attempts to do so will throw an `ERR_ACCESS_DENIED` unless the
user explicitly passes the `--allow-net` flag when starting Node.js.

This includes Unix domain sockets and Windows named pipes. Their paths are not
checked against [`--allow-fs-read`][] or [`--allow-fs-write`][].

Example:

```js
Expand Down
7 changes: 7 additions & 0 deletions doc/api/permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,13 @@ flag. For WASI, use the [`--allow-wasi`][] flag. For FFI, use the
[`--allow-ffi`][] flag. The [`node:ffi`](ffi.md) module is only available in
builds with FFI support.

Unix domain sockets and Windows named pipes are governed by the network
permission. Binding, listening on, or connecting to them through `node:net`
requires [`--allow-net`][] and is not checked against [`--allow-fs-read`][] or
[`--allow-fs-write`][], even though a Unix domain socket is created as a file
system entry. Granting [`--allow-net`][] therefore allows creating sockets and
connecting to local services at any path the operating system permits.

To allow use of OpenSSL STORE loaders, for example to load a private key
from a {URL} passed to [`crypto.createPrivateKey()`][], use the
[`--allow-openssl-store`][] flag.
Expand Down
2 changes: 2 additions & 0 deletions doc/node.1
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,8 @@ When using the Permission Model, the process will not be able to access
network by default.
Attempts to do so will throw an \fBERR_ACCESS_DENIED\fR unless the
user explicitly passes the \fB--allow-net\fR flag when starting Node.js.
This includes Unix domain sockets and Windows named pipes. Their paths are not
checked against \fB--allow-fs-read\fR or \fB--allow-fs-write\fR.
Example:
.Bd -literal
const http = require('node:http');
Expand Down
Loading