Skip to content

Commit

Permalink
doc: add note to tls docs about secureContext availability
Browse files Browse the repository at this point in the history
tls.createServer() and new tls.Server() ignore secureContext option.
  • Loading branch information
tgerk authored and Trott committed Jan 16, 2023
1 parent 7895484 commit 605c94c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions doc/api/tls.md
Expand Up @@ -1940,8 +1940,7 @@ from `process.argv` as the default value of the `sessionIdContext` option, other
APIs that create secure contexts have no default value.

The `tls.createSecureContext()` method creates a `SecureContext` object. It is
usable as an argument to several `tls` APIs, such as [`tls.createServer()`][]
and [`server.addContext()`][], but has no public methods.
usable as an argument to several `tls` APIs, such as [`server.addContext()`][], but has no public methods. (Note: [`tls.createServer()`][] and [`tls.Server`][] constructor do *not* support the `secureContext` option.)

A key is _required_ for ciphers that use certificates. Either `key` or
`pfx` can be used to provide it.
Expand Down

0 comments on commit 605c94c

Please sign in to comment.