0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-29 23:16:30 +01:00
Commit Graph

26459 Commits

Author SHA1 Message Date
Sam Roberts
42dbaed460 tls: support TLSv1.3
This introduces TLS1.3 support and makes it the default max protocol,
but also supports CLI/NODE_OPTIONS switches to disable it if necessary.

TLS1.3 is a major update to the TLS protocol, with many security
enhancements. It should be preferred over TLS1.2 whenever possible.

TLS1.3 is different enough that even though the OpenSSL APIs are
technically API/ABI compatible, that when TLS1.3 is negotiated, the
timing of protocol records and of callbacks broke assumptions hard-coded
into the 'tls' module.

This change introduces no API incompatibilities when TLS1.2 is
negotiated. It is the intention that it be backported to current and LTS
release lines with the default maximum TLS protocol reset to 'TLSv1.2'.
This will allow users of those lines to explicitly enable TLS1.3 if they
want.

API incompatibilities between TLS1.2 and TLS1.3 are:

- Renegotiation is not supported by TLS1.3 protocol, attempts to call
`.renegotiate()` will always fail.

- Compiling against a system OpenSSL lower than 1.1.1 is no longer
supported (OpenSSL-1.1.0 used to be supported with configure flags).

- Variations of `conn.write('data'); conn.destroy()` have undefined
behaviour according to the streams API. They may or may not send the
'data', and may or may not cause a ERR_STREAM_DESTROYED error to be
emitted. This has always been true, but conditions under which the write
suceeds is slightly but observably different when TLS1.3 is negotiated
vs when TLS1.2 or below is negotiated.

- If TLS1.3 is negotiated, and a server calls `conn.end()` in its
'secureConnection' listener without any data being written, the client
will not receive session tickets (no 'session' events will be emitted,
and `conn.getSession()` will never return a resumable session).

- The return value of `conn.getSession()` API may not return a resumable
session if called right after the handshake. The effect will be that
clients using the legacy `getSession()` API will resume sessions if
TLS1.2 is negotiated, but will do full handshakes if TLS1.3 is
negotiated.  See https://github.com/nodejs/node/pull/25831 for more
information.

PR-URL: https://github.com/nodejs/node/pull/26209
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
2019-03-20 07:48:25 -07:00
Anatoli Papirovski
4306300b5e timers: fix refresh inside callback
When `timers.refresh()` is called inside a callback, the timer would
incorrectly end up unrefed and thus not keep the event loop alive.

PR-URL: https://github.com/nodejs/node/pull/26721
Fixes: https://github.com/nodejs/node/issues/26642
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
2019-03-20 07:21:58 +01:00
cjihrig
d933cc4b02 report: remove duplicate TIME_TYPE
PR-URL: https://github.com/nodejs/node/pull/26708
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-20 05:46:28 +01:00
Rich Trott
a7fdb42c1a doc: remove How Does LTS Work section from Collaborator Guide
The How Does LTS Work section duplicates material in the release plan,
to which there is already a link in the doc. Unfortunately, it has gone
out of sync with the release plan, resulting in incorrect material being
in the Collaborator Guide. (The Release WG needs to approve certain
changes, not LTS WG as the guide currently says. It used to be the LTS
WG, but that changed.)

Instead of duplicating material in the Collaborator Guide and risking
that the two documents contradict each other again, instruct the reader
to refer to the release plan as the canonical source of information.

PR-URL: https://github.com/nodejs/node/pull/26723
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2019-03-19 20:30:57 -07:00
Rich Trott
4265021085 doc: condense LTS material in Collaborator Guide
Edit and condense the "What is LTS?" section of the Collaboroator Guide.

PR-URL: https://github.com/nodejs/node/pull/26722
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2019-03-19 20:27:54 -07:00
Gerhard Stoebich
614a7474ab perf_hooks: reset prev_ before starting ELD timer
reset `ELDHistogram.prev_` before staring timer to ensure that start
timer doesn't leak across `disable()` `enable()` calls.

PR-URL: https://github.com/nodejs/node/pull/26693
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
2019-03-20 10:53:04 +08:00
Sergey Zelenov
78162ad570 doc: document error event is optionally emitted after .destroy()
`error` event on each kind of stream is optionally emitted when
`.destroy()` method is called. It depends on `._destroy()`
implementation. In default implementation this event will no be
fired unless `error` parameter has been provided.

It was already mentioned for `writable.destroy([error])`, so I
just copied same sentence for the other streams.

PR-URL: https://github.com/nodejs/node/pull/26589
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2019-03-19 21:33:52 +02:00
gengjiawen
4e08daabc8 benchmark: use gfm for clarity
PR-URL: https://github.com/nodejs/node/pull/26710
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2019-03-19 20:55:51 +02:00
Ruben Bridgewater
273398a3d0
tty: add NO_COLOR and FORCE_COLOR support
This adds support to enforce a specific color depth by checking the
`FORCE_COLOR` environment variable similar to `chalk`.

On top of that we also add support for the `NO_COLOR` environment
variable as suggested by https://no-color.org/.

PR-URL: https://github.com/nodejs/node/pull/26485
Refs: https://github.com/nodejs/node/pull/26248
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
2019-03-19 16:41:22 +01:00
gengjiawen
1f1914c9d4 http2: delete unused enum in node_http2.h
PR-URL: https://github.com/nodejs/node/pull/26704
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
2019-03-19 21:36:12 +08:00
Joyee Cheung
197dbf60f1
process: check no handle or request is active after bootstrap
PR-URL: https://github.com/nodejs/node/pull/26593
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-19 21:00:48 +08:00
Joyee Cheung
9868d54411
worker: create per-Environment message port after bootstrap
PR-URL: https://github.com/nodejs/node/pull/26593
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-19 21:00:48 +08:00
Richard Lau
927f29d244 lib: lazy load v8 in error-serdes
Lazy loading `v8` in `lib/internal/error-serdes.js` reduces the number
of loaded modules by the bootstrap code for Worker threads by seven.

PR-URL: https://github.com/nodejs/node/pull/26689
Refs: https://github.com/nodejs/node/pull/26501#discussion_r264849750
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2019-03-19 07:59:47 +01:00
kohta ito
e08ac04a1a doc: add Note of options.stdio into child_process
PR-URL: https://github.com/nodejs/node/pull/26604
Refs: https://github.com/nodejs/node/pull/22892#issuecomment-469173273
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
2019-03-19 07:35:37 +01:00
cjihrig
cd9898a52a doc: add missing pr-url
PR-URL: https://github.com/nodejs/node/pull/26753
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
2019-03-19 05:57:44 +01:00
Anna Henningsen
81edd0a6c6 lib: run prepareMainThreadExecution for third_party_main
Treat `_third_party_main` like any other CJS entry point, as it
was done before 6967f91368.

PR-URL: https://github.com/nodejs/node/pull/26677
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2019-03-19 05:45:21 +01:00
Sam Roberts
ed2c6965d2 test: use EC cert property now that it exists
Remove XXX, there has been an EC specific cert property since
https://github.com/nodejs/node/pull/24358

PR-URL: https://github.com/nodejs/node/pull/26598
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
2019-03-18 15:05:03 -07:00
Joyee Cheung
97a919b12d
inspector: patch C++ debug options instead of process._breakFirstLine
Instead of patching process._breakFirstLine to inform the JS land
to wait for the debugger, check that the JS land has not yet
serialized the options and then patch the debug options from C++.
The changes will be carried into JS later during option serialization.

PR-URL: https://github.com/nodejs/node/pull/26602
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2019-03-19 05:45:40 +08:00
Joyee Cheung
a91d36fcc1
process: set the trace category update handler during bootstrap
Set the trace category update handler during bootstrap, but delay
the initial invocation of it until pre-execution. In addition, do
not serialize the `node.async_hooks` category state when loading
the trace_event binding during bootstrap, since it depends on
run time states (e.g. CLI flags). Instead, use the
`isTraceCategoryEnabled` v8 intrinsics to query that value during
pre-execution.

PR-URL: https://github.com/nodejs/node/pull/26605
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2019-03-19 05:37:20 +08:00
Joyee Cheung
e2a2f9398e
test: refactor trace event category tests
- Add descriptions
- Filter out the relevant traces for testing, ignore the irrelevant
  ones.

PR-URL: https://github.com/nodejs/node/pull/26605
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2019-03-19 05:37:20 +08:00
Anna Henningsen
d398e8988c
test: add fs.watchFile() + worker.terminate() test
Refs: https://github.com/nodejs/node/pull/21093#discussion_r193563156

PR-URL: https://github.com/nodejs/node/pull/21179
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Yuta Hiroto <hello@hiroppy.me>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-18 22:25:15 +01:00
Tobias Nießen
3a9592496c
crypto: add support for EdDSA key pair generation
PR-URL: https://github.com/nodejs/node/pull/26554
Refs: https://github.com/nodejs/node/pull/26319
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
2019-03-18 21:59:47 +01:00
Joyee Cheung
1a6fb71f71
timers: refactor timer callback initialization
This patch:

- Moves the timer callback initialization into bootstrap/node.js,
  documents when they will be called, and make the dependency on
  process._tickCallback explicit.
- Moves the initialization of tick callbacks and timer callbacks
  to the end of the bootstrap to make sure the operations
  done before those initializations are synchronous.
- Moves more internals into internal/timers.js from timers.js.

PR-URL: https://github.com/nodejs/node/pull/26583
Refs: https://github.com/nodejs/node/issues/26546
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2019-03-19 04:25:23 +08:00
Joyee Cheung
7866508482
timers: reduce usage of public util
Refs: https://github.com/nodejs/node/issues/26546

PR-URL: https://github.com/nodejs/node/pull/26583
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2019-03-19 04:25:21 +08:00
Joyee Cheung
4980cc7d9b
timers: refactor to use module.exports
PR-URL: https://github.com/nodejs/node/pull/26583
Refs: https://github.com/nodejs/node/issues/26546
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2019-03-19 04:25:20 +08:00
Joyee Cheung
84156cf10e
module: do not share the internal require function with public loaders
This patch removes `NativeModule.require` and
`NativeModule.requireWithFallbackInDeps`. The public loaders now
have to use a special method
`NativeModule.prototype.compileForPublicLoader()` to compile native
modules. In addition this patch moves the decisions of proxifying
exports and throwing unknown builtin errors entirely to public
loaders, and skip those during internal use - therefore `loaders.js`,
which is compiled during bootstrap, no longer needs to be aware of
the value of `--experimental-modules`.

PR-URL: https://github.com/nodejs/node/pull/26549
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-19 04:05:38 +08:00
Rich Trott
5fc6c1daed doc: update spawnSync() status value possibilities
The object returned by `child_process.spawnSync()` can have the `status`
property set to `null` if the process terminated due to a signal. We
even test for this in
test/parallel/test-child-process-spawnsync-kill-signal.js.

Update the documentation to reflect this.

PR-URL: https://github.com/nodejs/node/pull/26680
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
2019-03-18 12:20:22 -07:00
cjihrig
d6f6d7f854
deps: upgrade to libuv 1.27.0
Notable changes:
- `statx()` is used to retrieve file birth times on
  supported platforms.
- Improved support of running under Windows safe mode.
- Add support for UDP connected sockets. Several functions
  can now return `UV_EBADF` instead of `UV_EINVAL`.
- SunOS support is improved.

PR-URL: https://github.com/nodejs/node/pull/26707
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-18 14:42:24 -04:00
cjihrig
04f30e1a7a
test: update test for libuv update
Starting in libuv 1.27.0, test-dgram-address.js should expect
EBADF instead of EINVAL.

PR-URL: https://github.com/nodejs/node/pull/26707
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-18 14:42:06 -04:00
Joyee Cheung
ebcd50298e
src: replace heap_utils.createHeapSnapshot with v8.getHeapSnapshot
Remove the internal testing utility and use the public API instead.

PR-URL: https://github.com/nodejs/node/pull/26671
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2019-03-19 01:04:51 +08:00
Ruben Bridgewater
6d090124fd
test: fix intrinsics test
So far this test did not verify that the call did indeed fail since
the error case was not checked. This makes sure the error is indeed
thrown as expected.

PR-URL: https://github.com/nodejs/node/pull/26660
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2019-03-18 16:12:50 +01:00
Michaël Zasso
6e678b1b59 src,win: fix usage of deprecated v8::Object::Set
PR-URL: https://github.com/nodejs/node/pull/26735
Refs: https://github.com/nodejs/node/issues/26733
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2019-03-18 10:33:36 -04:00
gengjiawen
cf51ee4dcf src: elevate v8 namespaces for PropertyAttribute
PR-URL: https://github.com/nodejs/node/pull/26681
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
2019-03-18 20:22:13 +08:00
ZYSzys
174da74701 doc: add ZYSzys to collaborators
Fixes: https://github.com/nodejs/node/issues/26440

PR-URL: https://github.com/nodejs/node/pull/26730
Fixes: https://github.com/nodejs/node/issues/26440
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2019-03-18 19:18:53 +08:00
Matteo Collina
9d064439e5 async_hooks: remove deprecated emitBefore and emitAfter
AsyncResource.emitBefore and AsyncResource.emitAfter have been
deprecated in https://github.com/nodejs/node/pull/18632. This PR removes
it all.
This commit also updates some embedder tests to use internal APIs.
The conditions are still possible for Node.js core developers but not
for end users.

PR-URL: https://github.com/nodejs/node/pull/26530
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com>
Reviewed-By: Benedikt Meurer <benedikt.meurer@gmail.com>
Reviewed-By: Yang Guo <yangguo@chromium.org>
Reviewed-By: Andreas Madsen <amwebdk@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-18 11:36:48 +01:00
Matteo Collina
abafd38c8d fs: use proper .destroy() implementation for SyncWriteStream
PR-URL: https://github.com/nodejs/node/pull/26690
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-18 10:30:07 +01:00
Ben Noordhuis
36101558fd src: use EVPKeyPointer in more places
Rejoice, the code base is now free of manual EVP_PKEY_free() calls!

PR-URL: https://github.com/nodejs/node/pull/26632
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-03-18 08:35:20 +01:00
Sam Roberts
0f745bf9bd tls: return correct version from getCipher()
OpenSSL 1.0.0 returned incorrect version information. OpenSSL 1.1.0
fixed this, but returning the correct information broke our tests, so
was considered semver-major. Because of this, the version was hard-coded
to the OpenSSL 1.0.0 (incorrect) string in 5fe81c8aff.

This is ancient history, start returning the correct cipher version.

PR-URL: https://github.com/nodejs/node/pull/26625
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2019-03-18 07:34:16 +01:00
cjihrig
1ceb6d8e9b tools: update ESLint to 5.15.2
Update ESLint to 5.15.2

PR-URL: https://github.com/nodejs/node/pull/26687
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2019-03-18 07:25:31 +01:00
Rich Trott
bab5544476 doc: simplify force-push guidelines
Edit the guildelines for force-pushing in Collaborator Guide. There are
no policy changes, but the material is simplified a bit and the
sentences are now shorter.

PR-URL: https://github.com/nodejs/node/pull/26699
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2019-03-17 23:16:53 -07:00
Rich Trott
72f578327a tools: update lint-md.js to lint rfc name format
Update lint-md.js to lint for "RFC1234" and similar variants that should
be written as "RFC 1234".

PR-URL: https://github.com/nodejs/node/pull/26727
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2019-03-17 23:14:22 -07:00
Rich Trott
3e781c5177 doc: make RFC references consistent
Use "RFC 1234" instead of "rfc1234", "RFC1234" or similar variants.

PR-URL: https://github.com/nodejs/node/pull/26727
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2019-03-17 23:14:20 -07:00
gengjiawen
0a00933921 src: remove unused variable in class InspectorSocketServer
PR-URL: https://github.com/nodejs/node/pull/26633
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com>
2019-03-18 05:57:57 +01:00
Gireesh Punathil
daa97df343 child_process: ensure message sanity at source
Error messages coming out of de-serialization at the send target
is not consumable. So detect the scenario and fix it at the send source

Ref: https://github.com/nodejs/node/issues/20314

PR-URL: https://github.com/nodejs/node/pull/24787
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2019-03-18 10:23:08 +05:30
Richard Lau
993bdff9ff report: tidy up included headers
Remove inclusion of headers that are no longer required.

PR-URL: https://github.com/nodejs/node/pull/26697
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2019-03-17 23:42:00 -04:00
gengjiawen
dace489099 src: use deleted function instead of private function in class AsyncWrap
PR-URL: https://github.com/nodejs/node/pull/26634
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Refael Ackermann <refack@gmail.com>
2019-03-17 21:58:27 -04:00
gengjiawen
b215bf9dac src: inline macro DISALLOW_COPY_AND_ASSIGN
PR-URL: https://github.com/nodejs/node/pull/26634
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Refael Ackermann <refack@gmail.com>
2019-03-17 21:58:22 -04:00
Anna Henningsen
ed60e863e7 test: fix test-heapdump-worker
This test was broken by d35af56e5f.

Refs: https://github.com/nodejs/node/pull/21283
Fixes: https://github.com/nodejs/node/issues/26712

PR-URL: https://github.com/nodejs/node/pull/26713
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2019-03-17 21:19:41 -04:00
Thomas Hunter II
3b6344ce42 doc: note about DNS ANY queries / RFC 8482
PR-URL: https://github.com/nodejs/node/pull/26695
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Bryan English <bryan@bryanenglish.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2019-03-18 01:37:47 +02:00
Refael Ackermann
8e308e8b28 deps,v8: cherry-pick 385aa80
Original commit message:

    Correct removal of redundant moves

    The logic for removing while iterating is non-standard and
    a left over from a previous index based loop. This patch
    replaces it with a standard erase based version.

    This fixes a runtime crash with MSVC that invalidates the
    iterator and then asserts. This also makes the code safe
    in case the last move can be redundant.

    Change-Id: Ie6990e0d65a3b83a4b7da3e2e89ed4e60a6cd215
    Reviewed-on: https://chromium-review.googlesource.com/c/1488762
    Reviewed-by: Ben Titzer <titzer@chromium.org>
    Commit-Queue: Ben Titzer <titzer@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#59868}

Refs: 385aa80aff

PR-URL: https://github.com/nodejs/node/pull/26702
Fixes: https://github.com/nodejs/node/issues/26694
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2019-03-17 09:28:01 -04:00