Skip to content
This repository has been archived by the owner on Aug 11, 2020. It is now read-only.

Commit

Permalink
quic: initial quic implementation
Browse files Browse the repository at this point in the history
Co-authored-by: Anna Henningsen <[email protected]>
Co-authored-by: Daniel Bevenius <[email protected]>
Co-authored-by: gengjiawen <[email protected]>
Co-authored-by: James M Snell <[email protected]>
Co-authored-by: Lucas Pardue <[email protected]>
Co-authored-by: Ouyang Yadong <[email protected]>
Co-authored-by: Juan Jos<C3><A9> Arboleda <[email protected]>
Co-authored-by: Trivikram Kamat <[email protected]>
Co-authored-by: Denys Otrishko <[email protected]>
  • Loading branch information
9 people committed Feb 13, 2020
1 parent 5f51577 commit 76d2afc
Show file tree
Hide file tree
Showing 126 changed files with 26,542 additions and 457 deletions.
26 changes: 26 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -1316,6 +1316,32 @@ The externally maintained libraries used by Node.js are:
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
"""

- ngtcp2, located at deps/ngtcp2, is licensed as follows:
"""
The MIT License

Copyright (c) 2016 ngtcp2 contributors

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
"""

- node-inspect, located at deps/node-inspect, is licensed as follows:
"""
Copyright Node.js contributors. All rights reserved.
Expand Down
36 changes: 36 additions & 0 deletions configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,11 @@
choices=valid_os,
help='operating system to build for ({0})'.format(', '.join(valid_os)))

parser.add_option('--experimental-quic',
action='store_true',
dest='experimental_quic',
help='enable experimental quic support')

parser.add_option('--gdb',
action='store_true',
dest='gdb',
Expand Down Expand Up @@ -259,6 +264,27 @@
dest='shared_nghttp2_libpath',
help='a directory to search for the shared nghttp2 DLLs')

shared_optgroup.add_option('--shared-ngtcp2',
action='store_true',
dest='shared_ngtcp2',
help='link to a shared ngtcp2 DLL instead of static linking')

shared_optgroup.add_option('--shared-ngtcp2-includes',
action='store',
dest='shared_ngtcp2_includes',
help='directory containing ngtcp2 header files')

shared_optgroup.add_option('--shared-ngtcp2-libname',
action='store',
dest='shared_ngtcp2_libname',
default='ngtcp2',
help='alternative lib name to link to [default: %default]')

shared_optgroup.add_option('--shared-ngtcp2-libpath',
action='store',
dest='shared_ngctp2_libpath',
help='a directory to search for the shared ngtcp2 DLLs')

shared_optgroup.add_option('--shared-openssl',
action='store_true',
dest='shared_openssl',
Expand Down Expand Up @@ -1121,6 +1147,14 @@ def configure_node(o):
else:
o['variables']['debug_nghttp2'] = 'false'

if options.experimental_quic:
if options.shared_openssl:
raise Exception('QUIC requires modified version of OpenSSL and cannot be'
' enabled with --shared-openssl.')
o['variables']['experimental_quic'] = 1
else:
o['variables']['experimental_quic'] = 'false'

o['variables']['node_no_browser_globals'] = b(options.no_browser_globals)

o['variables']['node_shared'] = b(options.shared)
Expand Down Expand Up @@ -1248,6 +1282,8 @@ def without_ssl_error(option):
without_ssl_error('--openssl-no-asm')
if options.openssl_fips:
without_ssl_error('--openssl-fips')
if options.experimental_quic:
without_ssl_error('--experimental-quic')
return

if options.use_openssl_ca_store:
Expand Down
119 changes: 119 additions & 0 deletions doc/api/errors.md
Original file line number Diff line number Diff line change
Expand Up @@ -1640,6 +1640,125 @@ A non-context-aware native addon was loaded in a process that disallows them.

A given value is out of the accepted range.

<a id="ERR_QUIC_CANNOT_SET_GROUPS"></a>
### `ERR_QUIC_CANNOT_SET_GROUPS`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUIC_ERROR"></a>
### `ERR_QUIC_ERROR`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUIC_TLS13_REQUIRED"></a>
### `ERR_QUIC_TLS13_REQUIRED`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICCLIENTSESSION_FAILED"></a>
### `ERR_QUICCLIENTSESSION_FAILED`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICCLIENTSESSION_FAILED_SETSOCKET"></a>
### `ERR_QUICCLIENTSESSION_FAILED_SETSOCKET`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSESSION_DESTROYED"></a>
### `ERR_QUICSESSION_DESTROYED`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSESSION_INVALID_DCID"></a>
### `ERR_QUICSESSION_INVALID_DCID`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSESSION_UPDATEKEY"></a>
### `ERR_QUICSESSION_UPDATEKEY`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSESSION_VERSION_NEGOTIATION"></a>
### `ERR_QUICSESSION_VERSION_NEGOTIATION`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSOCKET_DESTROYED"></a>
### `ERR_QUICSOCKET_DESTROYED`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSOCKET_INVALID_STATELESS_RESET_SECRET_LENGTH"></a>
### `ERR_QUICSOCKET_INVALID_STATELESS_RESET_SECRET_LENGTH`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSOCKET_LISTENING"></a>
### `ERR_QUICSOCKET_LISTENING`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSOCKET_UNBOUND"></a>
### `ERR_QUICSOCKET_UNBOUND`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSTREAM_DESTROYED"></a>
### `ERR_QUICSTREAM_DESTROYED`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSTREAM_INVALID_PUSH"></a>
### `ERR_QUICSTREAM_INVALID_PUSH`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSTREAM_OPEN_FAILED"></a>
### `ERR_QUICSTREAM_OPEN_FAILED`

> Stability: 1 - Experimental
TBD

<a id="ERR_QUICSTREAM_UNSUPPORTED_PUSH"></a>
### `ERR_QUICSTREAM_UNSUPPORTED_PUSH`

> Stability: 1 - Experimental
TBD

<a id="ERR_REQUIRE_ESM"></a>
### `ERR_REQUIRE_ESM`

Expand Down
1 change: 1 addition & 0 deletions doc/api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
* [Process](process.html)
* [Punycode](punycode.html)
* [Query Strings](querystring.html)
* [QUIC](quic.html)
* [Readline](readline.html)
* [REPL](repl.html)
* [Report](report.html)
Expand Down
Loading

0 comments on commit 76d2afc

Please sign in to comment.