Skip to content

Commit 78e9941

Browse files
jasnelladdaleaxdanbevgengjiawenLPardue
committed
quic: initial quic implementation
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]>
1 parent ae9efc1 commit 78e9941

File tree

127 files changed

+28014
-105
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

127 files changed

+28014
-105
lines changed

LICENSE

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1316,6 +1316,58 @@ The externally maintained libraries used by Node.js are:
13161316
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
13171317
"""
13181318

1319+
- ngtcp2, located at deps/ngtcp2, is licensed as follows:
1320+
"""
1321+
The MIT License
1322+
1323+
Copyright (c) 2016 ngtcp2 contributors
1324+
1325+
Permission is hereby granted, free of charge, to any person obtaining
1326+
a copy of this software and associated documentation files (the
1327+
"Software"), to deal in the Software without restriction, including
1328+
without limitation the rights to use, copy, modify, merge, publish,
1329+
distribute, sublicense, and/or sell copies of the Software, and to
1330+
permit persons to whom the Software is furnished to do so, subject to
1331+
the following conditions:
1332+
1333+
The above copyright notice and this permission notice shall be
1334+
included in all copies or substantial portions of the Software.
1335+
1336+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
1337+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
1338+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
1339+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
1340+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
1341+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
1342+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1343+
"""
1344+
1345+
- nghttp3, located at deps/nghttp3, is licensed as follows:
1346+
"""
1347+
The MIT License
1348+
1349+
Copyright (c) 2019 nghttp3 contributors
1350+
1351+
Permission is hereby granted, free of charge, to any person obtaining
1352+
a copy of this software and associated documentation files (the
1353+
"Software"), to deal in the Software without restriction, including
1354+
without limitation the rights to use, copy, modify, merge, publish,
1355+
distribute, sublicense, and/or sell copies of the Software, and to
1356+
permit persons to whom the Software is furnished to do so, subject to
1357+
the following conditions:
1358+
1359+
The above copyright notice and this permission notice shall be
1360+
included in all copies or substantial portions of the Software.
1361+
1362+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
1363+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
1364+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
1365+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
1366+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
1367+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
1368+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1369+
"""
1370+
13191371
- node-inspect, located at deps/node-inspect, is licensed as follows:
13201372
"""
13211373
Copyright Node.js contributors. All rights reserved.

configure.py

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,11 @@
117117
choices=valid_os,
118118
help='operating system to build for ({0})'.format(', '.join(valid_os)))
119119

120+
parser.add_option('--experimental-quic',
121+
action='store_true',
122+
dest='experimental_quic',
123+
help='enable experimental quic support')
124+
120125
parser.add_option('--gdb',
121126
action='store_true',
122127
dest='gdb',
@@ -259,6 +264,48 @@
259264
dest='shared_nghttp2_libpath',
260265
help='a directory to search for the shared nghttp2 DLLs')
261266

267+
shared_optgroup.add_option('--shared-ngtcp2',
268+
action='store_true',
269+
dest='shared_ngtcp2',
270+
help='link to a shared ngtcp2 DLL instead of static linking')
271+
272+
shared_optgroup.add_option('--shared-ngtcp2-includes',
273+
action='store',
274+
dest='shared_ngtcp2_includes',
275+
help='directory containing ngtcp2 header files')
276+
277+
shared_optgroup.add_option('--shared-ngtcp2-libname',
278+
action='store',
279+
dest='shared_ngtcp2_libname',
280+
default='ngtcp2',
281+
help='alternative lib name to link to [default: %default]')
282+
283+
shared_optgroup.add_option('--shared-ngtcp2-libpath',
284+
action='store',
285+
dest='shared_ngtcp2_libpath',
286+
help='a directory to search for the shared ngtcp2 DLLs')
287+
288+
shared_optgroup.add_option('--shared-nghttp3',
289+
action='store_true',
290+
dest='shared_nghttp3',
291+
help='link to a shared nghttp3 DLL instead of static linking')
292+
293+
shared_optgroup.add_option('--shared-nghttp3-includes',
294+
action='store',
295+
dest='shared_nghttp3_includes',
296+
help='directory containing nghttp3 header files')
297+
298+
shared_optgroup.add_option('--shared-nghttp3-libname',
299+
action='store',
300+
dest='shared_nghttp3_libname',
301+
default='nghttp3',
302+
help='alternative lib name to link to [default: %default]')
303+
304+
shared_optgroup.add_option('--shared-nghttp3-libpath',
305+
action='store',
306+
dest='shared_nghttp3_libpath',
307+
help='a directory to search for the shared nghttp3 DLLs')
308+
262309
shared_optgroup.add_option('--shared-openssl',
263310
action='store_true',
264311
dest='shared_openssl',
@@ -1145,6 +1192,14 @@ def configure_node(o):
11451192
else:
11461193
o['variables']['debug_nghttp2'] = 'false'
11471194

1195+
if options.experimental_quic:
1196+
if options.shared_openssl:
1197+
raise Exception('QUIC requires modified version of OpenSSL and cannot be'
1198+
' enabled with --shared-openssl.')
1199+
o['variables']['experimental_quic'] = 1
1200+
else:
1201+
o['variables']['experimental_quic'] = 'false'
1202+
11481203
o['variables']['node_no_browser_globals'] = b(options.no_browser_globals)
11491204

11501205
o['variables']['node_shared'] = b(options.shared)
@@ -1272,6 +1327,8 @@ def without_ssl_error(option):
12721327
without_ssl_error('--openssl-no-asm')
12731328
if options.openssl_fips:
12741329
without_ssl_error('--openssl-fips')
1330+
if options.experimental_quic:
1331+
without_ssl_error('--experimental-quic')
12751332
return
12761333

12771334
if options.use_openssl_ca_store:

deps/openssl/openssl.gyp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,13 @@
1616
'OPENSSL_NO_HW',
1717
],
1818
'conditions': [
19+
[
20+
# Disable building QUIC support in openssl if experimental_quic
21+
# is not enabled.
22+
'experimental_quic!=1', {
23+
'defines': ['OPENSSL_NO_QUIC=1'],
24+
}
25+
],
1926
[ 'openssl_no_asm==1', {
2027
'includes': ['./openssl_no_asm.gypi'],
2128
}, 'target_arch=="arm64" and OS=="win"', {

0 commit comments

Comments
 (0)