Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 672879f

Browse filesBrowse files
sam-githubcodebytere
authored andcommitted
doc: use real protocol names in ALPN example
PR-URL: #24232 Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent fbf5321 commit 672879f
Copy full SHA for 672879f

File tree

Expand file treeCollapse file tree

1 file changed

+4
-3
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+4
-3
lines changed
Open diff view settings
Collapse file

‎doc/api/tls.md‎

Copy file name to clipboardExpand all lines: doc/api/tls.md
+4-3Lines changed: 4 additions & 3 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -888,9 +888,10 @@ changes:
888888
* `ALPNProtocols`: {string[]|Buffer[]|Uint8Array[]|Buffer|Uint8Array}
889889
An array of strings, `Buffer`s or `Uint8Array`s, or a single `Buffer` or
890890
`Uint8Array` containing the supported ALPN protocols. `Buffer`s should have
891-
the format `[len][name][len][name]...` e.g. `0x05hello0x05world`, where the
892-
first byte is the length of the next protocol name. Passing an array is
893-
usually much simpler, e.g. `['hello', 'world']`.
891+
the format `[len][name][len][name]...` e.g. `'\x08http/1.1\x08http/1.0'`,
892+
where the `len` byte is the length of the next protocol name. Passing an
893+
array is usually much simpler, e.g. `['http/1.1', 'http/1.0']`.
894+
Protocols earlier in the list have higher preference than those later.
894895
* `servername`: {string} Server name for the SNI (Server Name Indication) TLS
895896
extension. It is the name of the host being connected to, and must be a host
896897
name, and not an IP address. It can be used by a multi-homed server to

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.