errors: fix undefined HTTP2 and tls errors

Includes implementation of tls, HTTP2 error with documentation.

PR-URL: https://github.com/nodejs/node/pull/21564
Refs: https://github.com/nodejs/node/issues/21440
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
This commit is contained in:
Shailesh Shekhawat 2018-06-27 22:05:32 +08:00 committed by Vse Mozhet Byt
parent f9b739ebbc
commit 3950a3e0b1
2 changed files with 12 additions and 0 deletions

View File

@ -1014,6 +1014,11 @@ provided.
The `Http2Session` closed with a non-zero error code.
<a id="ERR_HTTP2_SETTINGS_CANCEL"></a>
### ERR_HTTP2_SETTINGS_CANCEL
The `Http2Session` settings canceled.
<a id="ERR_HTTP2_SOCKET_BOUND"></a>
### ERR_HTTP2_SOCKET_BOUND
@ -1624,6 +1629,11 @@ recommended to use 2048 bits or larger for stronger security.
A TLS/SSL handshake timed out. In this case, the server must also abort the
connection.
<a id="ERR_TLS_RENEGOTIATE"></a>
### ERR_TLS_RENEGOTIATE
An attempt to renegotiate the TLS session failed.
<a id="ERR_TLS_RENEGOTIATION_DISABLED"></a>
### ERR_TLS_RENEGOTIATION_DISABLED

View File

@ -582,6 +582,7 @@ E('ERR_HTTP2_SEND_FILE', 'Directories cannot be sent', Error);
E('ERR_HTTP2_SEND_FILE_NOSEEK',
'Offset or length can only be specified for regular files', Error);
E('ERR_HTTP2_SESSION_ERROR', 'Session closed with error code %s', Error);
E('ERR_HTTP2_SETTINGS_CANCEL', 'HTTP2 session settings canceled', Error);
E('ERR_HTTP2_SOCKET_BOUND',
'The socket is already bound to an Http2Session', Error);
E('ERR_HTTP2_STATUS_101',
@ -804,6 +805,7 @@ E('ERR_TLS_CERT_ALTNAME_INVALID',
'Hostname/IP does not match certificate\'s altnames: %s', Error);
E('ERR_TLS_DH_PARAM_SIZE', 'DH parameter size %s is less than 2048', Error);
E('ERR_TLS_HANDSHAKE_TIMEOUT', 'TLS handshake timeout', Error);
E('ERR_TLS_RENEGOTIATE', 'Attempt to renegotiate TLS session failed', Error);
E('ERR_TLS_RENEGOTIATION_DISABLED',
'TLS session renegotiation disabled for this socket', Error);