Myles Borins
5f93cf7e3a
2019-04-16, Version 8.16.0 'Carbon' (LTS)
...
Notable Changes:
* n-api:
- add API for asynchronous functions (Gabriel Schulhof)
https://github.com/nodejs/node/pull/17887
- mark thread-safe function as stable (Gabriel Schulhof)
https://github.com/nodejs/node/pull/25556
PR-URL: https://github.com/nodejs/node/pull/26933
2019-04-16 12:39:43 -04:00
Gabriel Schulhof
d6ffabc37f
n-api: mark thread-safe function as stable
...
Fixes: https://github.com/nodejs/node/issues/24249
PR-URL: https://github.com/nodejs/node/pull/25556
Backport-PR-URL: https://github.com/nodejs/node/pull/25648
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2019-03-19 23:56:33 +00:00
Kyle Farnung
44609d1274
n-api: restrict exports by version
...
* Move `napi_get_uv_event_loop` into the `NAPI_VERSION >= 2` section
* Move `napi_open_callback_scope`, `napi_close_callback_scope`,
`napi_fatal_exception`, `napi_add_env_cleanup_hook`, and
`napi_remove_env_cleanup_hook` into the `NAPI_VERSION >= 3` section
* Added a missing `added` property to `napi_get_uv_event_loop` in the
docs
* Added a `napiVersion` property to the docs and updated the parser and
generator to use it.
* Added usage documentation
PR-URL: https://github.com/nodejs/node/pull/19962
Backport-PR-URL: https://github.com/nodejs/node/pull/25648
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2019-03-19 23:54:39 +00:00
Anna Henningsen
ea5628e77a
process: allow reading from stdout/stderr sockets
...
Allow reading from stdio streams that are conventionally
associated with process output, since this is only convention.
This involves disabling the oddness around closing stdio
streams. Its purpose is to prevent the file descriptors
0 through 2 from being closed, since doing so can lead
to information leaks when new file descriptors are being
opened; instead, not doing anything seems like a more
reasonable choice.
Fixes: https://github.com/nodejs/node/issues/21203
Backport-PR-URL: https://github.com/nodejs/node/pull/25351
PR-URL: https://github.com/nodejs/node/pull/23053
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-03-19 22:55:13 +00:00
Lars-Magnus Skog
6b7cccc88a
doc: fix optional parameters in n-api.md
...
The thread_finalize_data and thread_finalize_cb parameters in
napi_create_threadsafe_function are optional.
Backport-PR-URL: https://github.com/nodejs/node/pull/25002
PR-URL: https://github.com/nodejs/node/pull/22998
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2019-02-28 23:40:10 +11:00
Gabriel Schulhof
759a0180b5
n-api: add API for asynchronous functions
...
Bundle a `uv_async_t`, a `uv_idle_t`, a `uv_mutex_t`, a `uv_cond_t`,
and a `v8::Persistent<v8::Function>` to make it possible to call into JS
from another thread. The API accepts a void data pointer and a callback
which will be invoked on the loop thread and which will receive the
`napi_value` representing the JavaScript function to call so as to
perform the call into JS. The callback is run inside a
`node::CallbackScope`.
A `std::queue<void*>` is used to store calls from the secondary
threads, and an idle loop is started by the `uv_async_t` callback on the
loop thread to drain the queue, calling into JS with each item.
Items can be added to the queue blockingly or non-blockingly.
The thread-safe function can be referenced or unreferenced, with the
same semantics as libuv handles.
Re: https://github.com/nodejs/help/issues/1035
Re: https://github.com/nodejs/node/issues/20964
Fixes: https://github.com/nodejs/node/issues/13512
Backport-PR-URL: https://github.com/nodejs/node/pull/25002
PR-URL: https://github.com/nodejs/node/pull/17887
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2019-02-28 23:40:10 +11:00
James Bunton
b17819db3d
doc: update the http.request.setTimeout docs to be accurate
...
Refs: https://github.com/nodejs/node/pull/8895
PR-URL: https://github.com/nodejs/node/pull/25123
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-02-28 23:40:10 +11:00
Myles Borins
6d1c367cf1
2018-12-26, Version 8.15.0 'Carbon' (LTS)
...
The 8.14.0 security release introduced some unexpected breakages on
the 8.x release line. This is a special release to fix a regression
in the HTTP binary upgrade response body and add a missing CLI flag
to adjust the max header size of the http parser.
Notable changes:
* cli:
- add --max-http-header-size flag (cjihrig)
https://github.com/nodejs/node/pull/24811
* http:
- add maxHeaderSize property (cjihrig)
https://github.com/nodejs/node/pull/24860
PR-URL: https://github.com/nodejs/node/pull/25177
2018-12-25 11:57:06 -05:00
cjihrig
446f8b54e5
http: add maxHeaderSize property
...
This commit exposes the value of --max-http-header-size
as a property of the http module.
Backport-PR-URL: https://github.com/nodejs/node/pull/25218
PR-URL: https://github.com/nodejs/node/pull/24860
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Shelley Vohr <codebytere@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-12-25 10:08:13 -05:00
cjihrig and Matteo Collina
693e362175
cli: add --max-http-header-size flag
...
Allow the maximum size of HTTP headers to be overridden from
the command line.
Backport-PR-URL: https://github.com/nodejs/node/pull/25171
co-authored-by: Matteo Collina <hello@matteocollina.com >
PR-URL: https://github.com/nodejs/node/pull/24811
Fixes: https://github.com/nodejs/node/issues/24692
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Myles Borins <myles.borins@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
2018-12-21 23:55:14 -05:00
Beth Griggs
187694e2fa
2018-12-18, Version 8.14.1 'Carbon' (LTS)
...
Notable changes:
* **assert**:
- revert breaking change (Ruben Bridgewater)
[#24786 ](https://github.com/nodejs/node/pull/24786 )
* **http2**:
- fix sequence of error/close events (Gerhard Stoebich)
[#24789 ](https://github.com/nodejs/node/pull/24789 )
PR-URL: https://github.com/nodejs/node/pull/24832
2018-12-18 00:42:55 -05:00
Benjamin Zaslavsky
74c1074d53
doc: add description for inspector-only console methods.
...
Description inspired by dev tools reference and inspector err messages
Added:
* intro
* console.debug()
* console.dirxml()
* console.markTimeline()
* console.profile()
* console.profileEnd()
* console.table()
* console.timeStamp()
* console.timeline()
* console.timelineEnd()
PR-URL: https://github.com/nodejs/node/pull/17004
Fixes: https://github.com/nodejs/node/issues/16755
Reviewed-By: Khaidi Chu <i@2333.moe >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-12-10 13:08:28 -05:00
Ari Autio
692223182c
doc: fix api documentation of http.createServer
...
Fixes: https://github.com/nodejs/node/issues/24105
PR-URL: https://github.com/nodejs/node/pull/24869
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-12-10 12:36:30 -05:00
willhayslett
6d8c65e574
doc: update to adding listens on SIGUSR1
...
Updated the doc/api/process.md documentation to reflect that
listening on SIGUSR1 could impact the debugger.
Fixes: https://github.com/nodejs/node/issues/19619
PR-URL: https://github.com/nodejs/node/pull/19709
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-12-04 17:47:30 +00:00
Rich Trott
33b7c50036
doc: remove "if provided" for optional arguments
...
Remove "if provided" when discussing arguments that are explicitly
indicated to be optional and have default values.
PR-URL: https://github.com/nodejs/node/pull/19690
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Shingo Inoue <leko.noor@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-12-04 15:43:38 +00:00
Rich Trott
216e7da8c5
doc: do not identify string as "JavaScript string"
...
A parameter that is explicitly identified as a string does not need to
be further specified in the text as a "JavaScript string". Remove the
type altogether as it is indicated in the argument description.
PR-URL: https://github.com/nodejs/node/pull/19689
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-12-04 15:43:07 +00:00
Kenji Okamoto
17e84217c7
doc: fix grammar error in process.md
...
PR-URL: https://github.com/nodejs/node/pull/19641
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Myles Borins <myles.borins@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-12-04 11:54:38 +00:00
Thomas Hunter II
06daf5276f
doc: remove use of "random port" re dgram send
...
PR-URL: https://github.com/nodejs/node/pull/19620
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2018-12-04 11:51:57 +00:00
Rich Trott
bf95392e86
doc: improve assert legacy text
...
This changes a sentence fragment into a full sentence and provides a few
other minor improvements.
PR-URL: https://github.com/nodejs/node/pull/19622
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Shingo Inoue <leko.noor@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-12-04 11:51:12 +00:00
Anna Henningsen
e48cc3c403
doc: remove confusing note about child process stdio
...
It’s not obvious what the paragraph is supposed to say.
In particular, whether and what kind of buffering mechanism
a process uses for its stdio streams does not affect that,
in general, no guarantees can be made about when it consumes data
that was sent to it.
PR-URL: https://github.com/nodejs/node/pull/19552
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-12-04 11:23:06 +00:00
Vse Mozhet Byt
63d8632611
doc: add types for some process properties
...
PR-URL: https://github.com/nodejs/node/pull/19571
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-12-03 21:42:30 +00:00
Steven R. Loomis
b2fc3b556c
doc: fix n-api example string
...
- using a length of 6 for `"hello"` includes a terminating null yielding
`"hello\u0000"`
- length of 5 would work,
but comparing to the N-API docs gives `NAPI_AUTO_LENGTH` instead
PR-URL: https://github.com/nodejs/node/pull/19205
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2018-12-03 21:37:59 +00:00
Rich Trott
d79e7d6e89
doc: minor improvements to buffer.md
...
PR-URL: https://github.com/nodejs/node/pull/19547
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-12-03 21:11:10 +00:00
Ari Leo Frankel
06491482f8
doc: update child_process.md
...
Add an explanation of the risk of exceeding platform pipe
capacity with uncaptured output in child_process.spawn
with stdio of pipe
PR-URL: https://github.com/nodejs/node/pull/19075
Fixes: https://github.com/nodejs/node/issues/4236
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-12-03 21:08:12 +00:00
Gerhard Stoebich
f5683a9a6d
doc: correct async_hooks resource names
...
Correct async hooks resource names to match the implementation:
`TCPSERVER` => `TCPSERVERWRAP`
Refs: #17157
PR-URL: https://github.com/nodejs/node/pull/24684
Refs: https://github.com/nodejs/node/pull/17157
Refs: https://github.com/nodejs/node/pull/24001
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
2018-12-03 16:31:53 +00:00
Sam Roberts
ffe1f8033c
doc: sort bottom-of-file markdown links
...
Backport of https://github.com/nodejs/node/pull/24679
PR-URL: https://github.com/nodejs/node/pull/24682
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
2018-12-01 19:59:48 +11:00
Rich Trott
8bb67a1fb9
doc: use Node.js instead of Node
...
Per branding guidelines from the Foundation, use Node.js and not Node.
PR-URL: https://github.com/nodejs/node/pull/23967
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Matheus Marchini <mat@mmarchini.me >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-11-28 11:26:49 +11:00
Denis McDonald
73e0bb1f52
doc: fix typographical issues
...
PR-URL: https://github.com/nodejs/node/pull/23970
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-11-28 11:26:49 +11:00
James M Snell
6d76f852a9
doc: add documentation for http.IncomingMessage$complete
...
Fixes: https://github.com/nodejs/node/issues/8102
PR-URL: https://github.com/nodejs/node/pull/23914
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-11-28 11:26:49 +11:00
Rich Trott
3025f351db
doc: remove mailing list
...
We removed the mailing list from the README and other places quite some
time ago. Core devs don't monitor it much. However, it is still linked
in a couple places in the docs directory. Remove those links.
PR-URL: https://github.com/nodejs/node/pull/23932
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-11-28 11:26:49 +11:00
ZYSzys
27b35833bd
doc: make example more clarified in cluster.md
...
PR-URL: https://github.com/nodejs/node/pull/23931
Refs: https://github.com/nodejs/node/issues/23930
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-11-28 11:26:48 +11:00
ZYSzys
9afdc09f98
doc: simplify path.basename() on POSIX and Windows
...
PR-URL: https://github.com/nodejs/node/pull/23864
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-11-28 11:26:48 +11:00
erickwendel
3f2a01688d
doc: add review suggestions to require()
...
PR-URL: https://github.com/nodejs/node/pull/23605
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-11-28 11:26:48 +11:00
James M Snell
e5f75cf82e
doc: add note about removeListener order
...
Fixes: https://github.com/nodejs/node/issues/21635
PR-URL: https://github.com/nodejs/node/pull/23762
Reviewed-By: Matheus Marchini <mat@mmarchini.me >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-11-28 11:26:48 +11:00
James M Snell
0ff88a3510
doc: document ACL limitation for fs.access on Windows
...
Fixes: https://github.com/nodejs/node/issues/19192
PR-URL: https://github.com/nodejs/node/pull/23772
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com >
2018-11-28 11:26:47 +11:00
James M Snell
32ae851710
doc: document that addMembership must be called once in a cluster
...
Fixes: https://github.com/nodejs/node/issues/12572
Refs: https://github.com/nodejs/node/pull/16240
PR-URL: https://github.com/nodejs/node/pull/23746
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-11-28 11:26:47 +11:00
James M Snell
e2d2ce6706
doc: remove reference to sslv3 in tls.md
...
PR-URL: https://github.com/nodejs/node/pull/23745
Fixes: https://github.com/nodejs/node/issues/9822
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2018-11-28 11:26:47 +11:00
Rod Vagg
39716a8835
2018-11-27, Version 8.14.0 'Carbon' (LTS)
...
This is a security release. All Node.js users should consult the security
release summary at:
https://nodejs.org/en/blog/vulnerability/november-2018-security-releases/
for details on patched vulnerabilities.
Fixes for the following CVEs are included in this release:
* Node.js: Denial of Service with large HTTP headers (CVE-2018-12121)
* Node.js: Slowloris HTTP Denial of Service (CVE-2018-12122 / Node.js)
* Node.js: Hostname spoofing in URL parser for javascript protocol
(CVE-2018-12123)
* Node.js: HTTP request splitting (CVE-2018-12116)
* OpenSSL: Timing vulnerability in DSA signature generation (CVE-2018-0734)
* OpenSSL: Microarchitecture timing vulnerability in ECC scalar multiplication
(CVE-2018-5407)
Notable Changes:
* deps: Upgrade to OpenSSL 1.0.2q, fixing CVE-2018-0734 and CVE-2018-5407
* http:
* Headers received by HTTP servers must not exceed 8192 bytes in total to
prevent possible Denial of Service attacks. Reported by Trevor Norris.
(CVE-2018-12121 / Matteo Collina)
* A timeout of 40 seconds now applies to servers receiving HTTP headers. This
value can be adjusted with `server.headersTimeout`. Where headers are not
completely received within this period, the socket is destroyed on the next
received chunk. In conjunction with `server.setTimeout()`, this aids in
protecting against excessive resource retention and possible Denial of
Service. Reported by Jan Maybach (liebdich.com).
* Two-byte characters are now strictly disallowed for the `path` option in
HTTP client requests. Paths containing characters outside of the range
`\u0021` - `\u00ff` will now be rejected with a `TypeError`. This behavior
can be reverted if necessary by supplying the
`--security-revert=CVE-2018-12116` command line argument (this is not
recommended). Reported as security concern for Node.js 6 and 8 by
Arkadiy Tetelman (lob.com), fixed by backporting a change by Benno
Fünfstück applied to Node.js 10 and later.
(CVE-2018-12116 / Matteo Collina)
* url: Fix a bug that would allow a hostname being spoofed when parsing URLs
with `url.parse()` with the `'javascript:'` protocol. Reported by
Martin Bajanik (kenticocloud.com). (CVE-2018-12123 / Matteo Collina)
PR-URL: https://github.com/nodejs-private/node-private/pull/154
2018-11-27 15:26:29 +11:00
Matteo Collina
696f063c5e
http,https: protect against slow headers attack
...
CVE-2018-12122
An attacker can send a char/s within headers and exahust the resources
(file descriptors) of a system even with a tight max header length
protection. This PR destroys a socket if it has not received the headers
in 40s.
PR-URL: https://github.com/nodejs-private/node-private/pull/151
Ref: https://github.com/nodejs-private/node-private/pull/144
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-11-27 15:07:09 +11:00
Beth Griggs
90c7bfa579
2018-11-20, Version 8.13.0 'Carbon' (LTS)
...
Notable changes:
* **assert**:
- backport some assert commits (Ruben Bridgewater)
[#23223 ](https://github.com/nodejs/node/pull/23223 )
* **deps**:
- upgrade to libuv 1.23.2 (cjihrig)
[#23336 ](https://github.com/nodejs/node/pull/23336 )
- V8: cherry-pick 64-bit hash seed commits (Yang Guo)
[#23274 ](https://github.com/nodejs/node/pull/23274 )
* **http**:
- added aborted property to request (Robert Nagy)
[#20094 ](https://github.com/nodejs/node/pull/20094 )
* **http2**:
- graduate from experimental (James M Snell)
[#22466 ](https://github.com/nodejs/node/pull/22466 )
PR-URL: https://github.com/nodejs/node/pull/23974
2018-11-20 10:28:37 -05:00
feugy
3babc5bb53
assert: add rejects() and doesNotReject()
...
Implement asynchronous equivalent for assert.throws() and
assert.doesNotThrow().
Backport-PR-URL: https://github.com/nodejs/node/pull/24019
PR-URL: https://github.com/nodejs/node/pull/18023
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Shingo Inoue <leko.noor@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-11-04 12:30:51 +00:00
Ruben Bridgewater
f2af930ebb
assert: .throws accept objects
...
From now on it is possible to use a validation object in throws
instead of the other possibilites.
Backport-PR-URL: https://github.com/nodejs/node/pull/23223
PR-URL: https://github.com/nodejs/node/pull/17584
Refs: https://github.com/nodejs/node/pull/17557
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Ron Korving <ron@ronkorving.nl >
Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com >
2018-10-31 13:45:06 -04:00
Ruben Bridgewater
147aeedc8d
assert: improve assert.throws
...
Throw a TypeError in case a error message is provided in the second
argument and a third argument is present as well.
This is clearly a mistake and should not be done.
Backport-PR-URL: https://github.com/nodejs/node/pull/23223
PR-URL: https://github.com/nodejs/node/pull/17585
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Evan Lucas <evanlucas@me.com >
2018-10-31 13:45:04 -04:00
Ruben Bridgewater
c6d94f8fa5
assert: add strict functionality export
...
Requireing the strict version will allow to use `assert.equal`,
`assert.deepEqual` and there negated counterparts to be used with
strict comparison instead of using e.g. `assert.strictEqual`.
The API is identical to the regular assert export and only differs
in the way that all functions use strict compairson.
Backport-PR-URL: https://github.com/nodejs/node/pull/23223
PR-URL: https://github.com/nodejs/node/pull/17002
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2018-10-31 13:44:47 -04:00
Rich Trott
9446bb68ea
doc: fix minor issues in async_hooks.md
...
* easily -> easy
* was -> is
* add a missing comma
PR-URL: https://github.com/nodejs/node/pull/19313
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-10-17 23:57:31 +01:00
James M Snell
18a2b3dc8e
http2: graduate from experimental
...
Backport-PR-URL: https://github.com/nodejs/node/pull/22850
PR-URL: https://github.com/nodejs/node/pull/22466
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Yuta Hiroto <hello@hiroppy.me >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2018-10-17 00:07:24 +01:00
James M Snell
10576d6e77
http2: add ping event
...
Add a `Http2Session` event whenever a non-ack `PING` is received.
Fixes: https://github.com/nodejs/node/issues/18514
Backport-PR-URL: https://github.com/nodejs/node/pull/22850
PR-URL: https://github.com/nodejs/node/pull/23009
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
2018-10-17 00:07:24 +01:00
James M Snell
49f44f3b44
http2: add origin frame support
...
v8.x Backport Note -- as V8 doesn't expose an overload of String::WriteOneByte
in Node 8 that accepts an isolate argument, the Origins constructor has been
changed to not accept an isolate.
Backport-PR-URL: https://github.com/nodejs/node/pull/22850
PR-URL: https://github.com/nodejs/node/pull/22956
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-10-17 00:07:24 +01:00
James M Snell
2de17ead89
http2: add http2stream.endAfterHeaders property
...
Indicates is the END_STREAM flag was set on the received HEADERS frame
Backport-PR-URL: https://github.com/nodejs/node/pull/22850
PR-URL: https://github.com/nodejs/node/pull/22843
Fixes: https://github.com/nodejs/node/issues/22497
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-10-17 00:07:24 +01:00
Sagi Tsofan
bae7c608e2
doc: document http2 timeouts
...
New default timeout values of "2 minutes" were added into documentation
inside 2 classes under "Event: 'timeout'":
1) Class: Http2SecureServer
2) Class: Http2Server
New sections for `.setTimeout()` method were added inside
`Http2SecureServer` & `Http2Server` docs.
Backport-PR-URL: https://github.com/nodejs/node/pull/22850
PR-URL: https://github.com/nodejs/node/pull/22798
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-10-17 00:07:24 +01:00