| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent d77eaee commit ddc5afd
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1392,6 +1392,12 @@ The `callback` function, if specified, will be added as a listener for the | |||
| 1392 | 1392 | ||
| 1393 | 1393 | `tls.connect()` returns a [`tls.TLSSocket`][] object. | |
| 1394 | 1394 | ||
| 1395 | + Unlike the `https` API, `tls.connect()` does not enable the | ||
| 1396 | + SNI (Server Name Indication) extension by default, which may cause some | ||
| 1397 | + servers to return an incorrect certificate or reject the connection | ||
| 1398 | + altogether. To enable SNI, set the `servername` option in addition | ||
| 1399 | + to `host`. | ||
| 1400 | + | ||
| 1395 | 1401 | The following illustrates a client for the echo server example from | |
| 1396 | 1402 | [`tls.createServer()`][]: | |
| 1397 | 1403 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments