Fedor Indutny [Thu, 7 Nov 2013 21:22:02 +0000 (01:22 +0400)]
tls: prevent stalls by using read(0)
Do not `.push()` the same data as just passed to `.ondata()`, it
may be read by 'data' event listeners.
fix #6277
isaacs [Fri, 8 Nov 2013 21:41:21 +0000 (13:41 -0800)]
npm: Upgrade to 1.3.14
Fedor Indutny [Mon, 21 Oct 2013 12:26:29 +0000 (16:26 +0400)]
doc: encoding is ignored if input is a Buffer
NOTE: it wasn't in 0.8
fixes #6386
isaacs [Thu, 31 Oct 2013 20:35:54 +0000 (13:35 -0700)]
doc: Correct and add several items
Several names/urls were out of date, and some really
awesome stuff was missing.
Sam Roberts [Wed, 30 Oct 2013 23:19:17 +0000 (16:19 -0700)]
doc: document node signal handling
Partly lifted from uv.h, partly from observation of node.cc.
Timothy J Fontaine [Wed, 30 Oct 2013 16:09:04 +0000 (09:09 -0700)]
blog: Post for v0.11.8
Ben Noordhuis [Tue, 29 Oct 2013 09:31:14 +0000 (10:31 +0100)]
doc: dgram: reword dgram.Socket#send() docs
Make it clear that the address argument is not really optional and fix
some Engrish and long lines while we're here.
Fixes #6433.
isaacs [Mon, 28 Oct 2013 21:10:47 +0000 (14:10 -0700)]
npm@1.3.13
Phillip Alexander [Sat, 26 Oct 2013 20:13:56 +0000 (13:13 -0700)]
doc: fs: clarify fs.symlink Windows specific args
Ryan Graham [Sat, 26 Oct 2013 05:03:02 +0000 (22:03 -0700)]
doc: improve module documentation
Expands on when to use module.exports vs. exports. This is a recurring
question on mailing list and continues to confuse new devs.
Sam Roberts [Fri, 25 Oct 2013 20:16:50 +0000 (13:16 -0700)]
doc: fix missing backtick in 2e16037
Brian White [Thu, 24 Oct 2013 02:43:23 +0000 (22:43 -0400)]
doc: streams: document default objectMode setting
Maxim Bogushevich [Tue, 22 Oct 2013 07:27:02 +0000 (17:27 +1000)]
debugger: Fix bug in sb() with unnamed script
setBreakpoint() cause error when unnamed script is loaded
isaacs [Thu, 24 Oct 2013 16:21:59 +0000 (09:21 -0700)]
npm@1.3.12
Ben Noordhuis [Wed, 23 Oct 2013 11:42:53 +0000 (13:42 +0200)]
build: fix test-gc weakref build rule
Make the build rule depend on the build artifact (weakref.node) itself
rather than the directory it's built in. Depending on the directory
means that a build failure won't trigger a rebuild on the next
invocation because the directory's timestamp has been updated.
This is a back-port of commit 1189571 from the master branch that
hopefully fixes the following CI error:
executing: make test/gc/node_modules/weak/build/
make: *** No rule to make target `test/gc/node_modules/weak/build/'.
Command exited with non-zero: make test/gc/node_modules/weak/build/
Build step 'Execute NodeJS script' marked build as failure
Zarko Stankovic [Thu, 12 Sep 2013 18:13:32 +0000 (20:13 +0200)]
doc: add nodejs.rs to the community page
Ben Noordhuis [Wed, 23 Oct 2013 11:25:35 +0000 (13:25 +0200)]
src: IsInt64() should return bool, not int
isaacs [Tue, 22 Oct 2013 17:56:03 +0000 (10:56 -0700)]
blog: HTTP server DoS vulnerability details
CVE-2013-4450
Timothy J Fontaine [Fri, 18 Oct 2013 22:46:02 +0000 (15:46 -0700)]
blog: Post for v0.10.21
Timothy J Fontaine [Fri, 18 Oct 2013 22:43:55 +0000 (15:43 -0700)]
blog: Post for v0.8.26
Timothy J Fontaine [Fri, 18 Oct 2013 22:40:32 +0000 (15:40 -0700)]
Now working on 0.10.22
Timothy J Fontaine [Fri, 18 Oct 2013 22:39:56 +0000 (15:39 -0700)]
Merge branch 'v0.10.21-release' into v0.10
Timothy J Fontaine [Fri, 18 Oct 2013 21:26:27 +0000 (14:26 -0700)]
2013.10.18, Version 0.10.21 (Stable)
* uv: Upgrade to v0.10.18
* crypto: clear errors from verify failure (Timothy J Fontaine)
* dtrace: interpret two byte strings (Dave Pacheco)
* fs: fix fs.truncate() file content zeroing bug (Ben Noordhuis)
* http: provide backpressure for pipeline flood (isaacs)
* tls: fix premature connection termination (Ben Noordhuis)
Timothy J Fontaine [Fri, 18 Oct 2013 21:14:21 +0000 (14:14 -0700)]
crypto: clear errors from verify failure
OpenSSL will push errors onto the stack when a verify fails, which can
disrupt TLS and other routines if we don't clear the error stack
Fixes #6304
Timothy J Fontaine [Fri, 18 Oct 2013 20:52:15 +0000 (13:52 -0700)]
uv: Upgrade to v0.10.18
isaacs [Wed, 16 Oct 2013 19:57:46 +0000 (12:57 -0700)]
http: provide backpressure for pipeline flood
If a client sends a lot more pipelined requests than we can handle, then
we need to provide backpressure so that the client knows to back off.
Do this by pausing both the stream and the parser itself when the
responses are not being read by the downstream client.
Backport of 085dd30
Timothy J Fontaine [Mon, 14 Oct 2013 18:57:45 +0000 (11:57 -0700)]
http_parser: expose pause/resume method for parser
Sam Roberts [Fri, 26 Jul 2013 01:17:38 +0000 (18:17 -0700)]
doc: cluster documentation cleanup and corrections
- fixed some incomprehensible wording ("event assigned to..."?)
- removed undocumented and unnecessary process properties from example
- corrected the docs on the default for the exec setting
- described when workers are removed from cluster.workers
- described addressType, which was documented as existing, but not what
values it might have
- spell out more clearly the limitations of setupMaster
- describe disconnect in sufficient detail that why a child does or does
not exit can be understood
- clarify which cluster functions and events are available on process or
just on the worker, as well as which are not available in children,
- don't describe events as the same, when they have receive different
arguments
- fix misleading disconnect example: since disconnect already calls
close on all servers, doing it again in the example is a no-op, not
the "force close" it was claimed to be
- document the error event, not catching it will kill your node
- describe suicide better, it is important, and a bit unintuitive
(process.exit() is not suicide?)
- use worker consistently throughout, instead of child.
Sam Roberts [Fri, 26 Jul 2013 00:35:21 +0000 (17:35 -0700)]
doc: child_process corrections and cleanups
- Make explicit that .disconnected is set before the disconnect event,
and it is not allowed to send messages after calling .disconnect(),
even while waiting for a delayed disconect event.
- Remove obsolete claim that explicit exit is required
- Describe silent: in the options for fork()
- Describe .connected as the property it is, not just as an aside in
the disconnect() method
Ben Noordhuis [Wed, 16 Oct 2013 10:32:47 +0000 (12:32 +0200)]
doc: http: reword IncomingMessage 'close' event
The bit that says "before response.end() was called or able to flush"
doesn't apply to incoming streams.
Fixes #6359.
Ben Noordhuis [Wed, 16 Oct 2013 10:20:25 +0000 (12:20 +0200)]
doc: http: add cross-links for easier clicking
Make it a little easier to navigate the http module documentation by
turning class names and methods into links to the appropriate section.
Ben Noordhuis [Tue, 15 Oct 2013 08:01:50 +0000 (10:01 +0200)]
doc: expand os.loadavg() section
Add a short explanation of what the load average is and why it's
unavailable on Windows.
Also sneak in a fix for a typo that I introduced in commit 56c5806.
Ben Noordhuis [Mon, 14 Oct 2013 11:15:00 +0000 (12:15 +0100)]
doc: document os.loadavg() behavior on windows
The load average is a very UNIX-y concept. That's why os.loadavg()
always returns zeros on Windows. Mention that in the documentation.
Dave Pacheco [Thu, 10 Oct 2013 16:41:59 +0000 (09:41 -0700)]
test: use proper findjsobjects output format
Closes #6329
Ben Noordhuis [Thu, 10 Oct 2013 12:34:15 +0000 (14:34 +0200)]
doc: net: remove bad net.Server description
net.Server is not an instance of net.Socket so don't say it is.
Ben Noordhuis [Thu, 10 Oct 2013 12:09:38 +0000 (14:09 +0200)]
doc: addon: fix object instantiation examples
* Extend examples to show how to handle non-constructor invocation in
constructor callback functions.
* Fix up examples to initialize member variables at object construction.
* Fix up a few naming inconsistencies.
Fixes #5701.
isaacs [Mon, 9 Sep 2013 11:31:05 +0000 (12:31 +0100)]
blog: Remove wp-to-markdown script
Ben Noordhuis [Wed, 9 Oct 2013 15:46:17 +0000 (17:46 +0200)]
tls: fix premature connection termination
Destroying the TLS session implies destroying the underlying socket but
before this commit, that was done with net.Socket#destroy() rather than
net.Socket#destroySoon(). The former closes the connection right away,
even when there is still data to write. In other words, sometimes the
final TLS record got truncated.
Fixes #6107.
Dave Pacheco [Fri, 4 Oct 2013 22:02:42 +0000 (15:02 -0700)]
dtrace: backport two byte string fix
This is a partial backport of 5921158
Re #6309
Closes #6319
Ben Noordhuis [Tue, 8 Oct 2013 09:25:22 +0000 (11:25 +0200)]
fs: fix fs.truncate() file content zeroing bug
fs.truncate() and its synchronous sibling are implemented in terms of
open() + ftruncate(). Unfortunately, it opened the target file with
mode 'w' a.k.a. 'write-only and create or truncate at open'.
The subsequent call to ftruncate() then moved the end-of-file pointer
from zero to the requested offset with the net result of a file that's
neatly truncated at the right offset and filled with zero bytes only.
This bug was introduced in commit
168a5557 but in fairness, before that
commit fs.truncate() worked like fs.ftruncate() so it seems we've never
had a working fs.truncate() until now.
Fixes #6233.
Ben Noordhuis [Sat, 5 Oct 2013 12:45:10 +0000 (14:45 +0200)]
doc: add warning to fs.exists() documentation
Warn against the open-if-exists anti-pattern, it's susceptible to
race conditions.
Ben Noordhuis [Tue, 1 Oct 2013 06:35:24 +0000 (08:35 +0200)]
doc: link to pre-built binaries, add install note
lLnk to http://nodejs.org/download/ and add a short primer on how to
extract the tarballs.
Fixes #6292.
Timothy J Fontaine [Mon, 30 Sep 2013 22:06:14 +0000 (15:06 -0700)]
blog: Post for v0.10.20
Timothy J Fontaine [Mon, 30 Sep 2013 22:06:14 +0000 (15:06 -0700)]
Now working on 0.10.21
Timothy J Fontaine [Mon, 30 Sep 2013 22:06:02 +0000 (15:06 -0700)]
Merge branch 'v0.10.20-release' into v0.10
Timothy J Fontaine [Mon, 30 Sep 2013 20:52:48 +0000 (13:52 -0700)]
2013.09.30, Version 0.10.20 (Stable)
* tls: fix sporadic hang and partial reads (Fedor Indutny)
- fixes "npm ERR! cb() never called!"
Ben Noordhuis [Sat, 28 Sep 2013 08:27:11 +0000 (10:27 +0200)]
src: turn uv_pipe_open() failures into exceptions
uv_pipe_open() is unlikely to fail but when it does, the failure should
not be quietly ignored. Raise the error as an exception.
See joyent/libuv#941.
Fedor Indutny [Fri, 27 Sep 2013 19:47:13 +0000 (23:47 +0400)]
tls: fix sporadic hang and partial reads
Do not decrement size in read loop, its used later, when comparing to
`bytesRead`.
fix #6270
NOTE: Original patch contributed by @roadrunner2
Timothy J Fontaine [Tue, 24 Sep 2013 22:16:44 +0000 (15:16 -0700)]
blog: add missing shasums for v0.10.19 release
Timothy J Fontaine [Tue, 24 Sep 2013 22:10:22 +0000 (15:10 -0700)]
blog: Post for v0.10.19
Timothy J Fontaine [Tue, 24 Sep 2013 22:10:22 +0000 (15:10 -0700)]
Now working on 0.10.20
Timothy J Fontaine [Tue, 24 Sep 2013 22:10:10 +0000 (15:10 -0700)]
Merge branch 'v0.10.19-release' into v0.10
Timothy J Fontaine [Tue, 24 Sep 2013 21:10:33 +0000 (14:10 -0700)]
2013.09.24, Version 0.10.19 (Stable)
* uv: Upgrade to v0.10.17
* npm: upgrade to 1.3.11
* readline: handle input starting with control chars (Eric Schrock)
* configure: add mips-float-abi (soft, hard) option (Andrei Sedoi)
* stream: objectMode transforms allow falsey values (isaacs)
* tls: prevent duplicate values returned from read (Nathan Rajlich)
* tls: NPN protocols are now local to connections (Fedor Indutny)
Timothy J Fontaine [Tue, 24 Sep 2013 20:45:57 +0000 (13:45 -0700)]
uv: Upgrade to v0.10.17
Eric Schrock [Mon, 20 May 2013 18:44:26 +0000 (14:44 -0400)]
readline: handle input starting with control chars
Handle control characters only when there is a single byte in the
stream, otherwise fall through to the standard multibyte handling.
Ben Noordhuis [Thu, 19 Sep 2013 10:27:06 +0000 (12:27 +0200)]
doc: document reserved status of SIGUSR1
Fixes #1212.
Nathan Rajlich [Mon, 16 Sep 2013 20:57:34 +0000 (13:57 -0700)]
doc: fix typos in the tls `NPNProtocols` option
Nathan Rajlich [Mon, 16 Sep 2013 20:57:00 +0000 (13:57 -0700)]
doc: specify the format of the `ca` tls option
Nathan Rajlich [Thu, 12 Sep 2013 01:18:10 +0000 (18:18 -0700)]
tls: don't push() incoming data when ondata is set
Otherwise the data ends up "on the wire" twice, and
switching between consuming the stream using `ondata`
vs. `read()` would yield duplicate data, which was bad.
Ben Noordhuis [Fri, 13 Sep 2013 12:46:06 +0000 (14:46 +0200)]
doc: fix blog link in blog posts and README
Apparently Joyent decommissioned joyeur.com but at least they saved the
contents of the blog. Update the links in the README and the nodejs.org
blog posts.
Hat tip to Eugen Pirogoff (@eugenpirogoff) for pointing it out.
Fixes #6224.
Fedor Indutny [Mon, 9 Sep 2013 14:18:05 +0000 (18:18 +0400)]
tls: fix setting NPN protocols
The NPN protocols was set on `require('tls')` or `global` object instead
of being a local property. This fact lead to strange persistence of NPN
protocols, and sometimes incorrect protocol selection (when no NPN
protocols were passed in client options).
fix #6168
Andrei Sedoi [Wed, 19 Jun 2013 11:48:36 +0000 (14:48 +0300)]
configure: add mips-float-abi (soft, hard) option
isaacs [Sat, 7 Sep 2013 19:31:04 +0000 (14:31 -0500)]
npm: upgrade to 1.3.11
isaacs [Fri, 6 Sep 2013 00:13:50 +0000 (17:13 -0700)]
npm: upgrade to v1.3.10
isaacs [Thu, 5 Sep 2013 20:11:51 +0000 (13:11 -0700)]
stream: objectMode transforms allow falsey values
Closes #6183
Bert Belder [Thu, 5 Sep 2013 14:49:47 +0000 (16:49 +0200)]
uv: upgrade to v0.10.16
Timothy J Fontaine [Wed, 4 Sep 2013 22:27:06 +0000 (15:27 -0700)]
blog: Post for v0.11.7
Timothy J Fontaine [Wed, 4 Sep 2013 18:25:19 +0000 (11:25 -0700)]
blog: Post for v0.10.18
Timothy J Fontaine [Wed, 4 Sep 2013 18:25:19 +0000 (11:25 -0700)]
Now working on 0.10.19
Timothy J Fontaine [Wed, 4 Sep 2013 18:25:04 +0000 (11:25 -0700)]
Merge branch 'v0.10.18-release' into v0.10
Timothy J Fontaine [Wed, 4 Sep 2013 17:51:53 +0000 (10:51 -0700)]
2013.09.04, Version 0.10.18 (Stable)
* uv: Upgrade to v0.10.15
* stream: Don't crash on unset _events property (isaacs)
* stream: Pass 'buffer' encoding with decoded writable chunks (isaacs)
Kyle Robinson Young [Tue, 3 Sep 2013 22:00:45 +0000 (15:00 -0700)]
doc: fix writable.write link
isaacs [Sun, 1 Sep 2013 00:58:17 +0000 (17:58 -0700)]
benchmark: Fix execArgv handling
Bug in 01f3b46 causes the same benchmark to be run repeatedly.
Not so useful for the compare scripts.
isaacs [Sat, 31 Aug 2013 05:39:06 +0000 (22:39 -0700)]
benchmark: Support passing v8 flags to benchmarks
The better to test --use-strict effects on performance.
(Spoiler: it has no measurable effect on performance.)
isaacs [Wed, 28 Aug 2013 16:35:36 +0000 (09:35 -0700)]
stream: check _events before _events.error
This fixes the regression introduced by 5458079, which breaks the
net/net-pipe benchmark script.
Closes #6145
isaacs [Wed, 28 Aug 2013 02:52:09 +0000 (19:52 -0700)]
doc: Adjust util stability index to 'API Frozen'
Closes #6087
isaacs [Tue, 27 Aug 2013 21:53:06 +0000 (14:53 -0700)]
stream: Pass 'buffer' encoding to decoded writables
Since the encoding is no longer relevant once it is decoded to a Buffer,
it is confusing and incorrect to pass the encoding as 'utf8' or whatever
in those cases.
Closes #6119
Bert Belder [Fri, 23 Aug 2013 17:02:14 +0000 (19:02 +0200)]
uv: update to v0.10.15
Timothy J Fontaine [Wed, 21 Aug 2013 23:59:15 +0000 (16:59 -0700)]
tools: script release steps after jenkins build
Timothy J Fontaine [Wed, 21 Aug 2013 23:55:27 +0000 (16:55 -0700)]
tools: script to report [un]stable build
Timothy J Fontaine [Wed, 21 Aug 2013 23:38:30 +0000 (16:38 -0700)]
blog: Post for v0.10.17
Timothy J Fontaine [Wed, 21 Aug 2013 23:37:43 +0000 (16:37 -0700)]
Now working on 0.10.18
Timothy J Fontaine [Wed, 21 Aug 2013 23:37:31 +0000 (16:37 -0700)]
Merge branch 'v0.10.17-release' into v0.10
Timothy J Fontaine [Wed, 21 Aug 2013 22:00:56 +0000 (15:00 -0700)]
2013.08.21, Version 0.10.17 (Stable)
* uv: Upgrade v0.10.14
* http_parser: Do not accept PUN/GEM methods as PUT/GET (Chris Dickinson)
* tls: fix assertion when ssl is destroyed at read (Fedor Indutny)
* stream: Throw on 'error' if listeners removed (isaacs)
* dgram: fix assertion on bad send() arguments (Ben Noordhuis)
* readline: pause stdin before turning off terminal raw mode (Daniel Chatfield)
Timothy J Fontaine [Wed, 21 Aug 2013 21:44:20 +0000 (14:44 -0700)]
uv: Upgrade v0.10.14
Timothy J Fontaine [Wed, 21 Aug 2013 21:26:32 +0000 (14:26 -0700)]
blog: v0.11.6
isaacs [Wed, 21 Aug 2013 18:11:02 +0000 (11:11 -0700)]
doc: Mention python dep in downloads page
Closes #3604
Ben Noordhuis [Wed, 21 Aug 2013 01:33:20 +0000 (03:33 +0200)]
deps: upgrade http_parser to 303c4e4
Upgrade to joyent/http-parser@303c4e4. Changes:
* Do not accept PUN/GEM methods as PUT/GET.
* Further request method check strengthening.
Fedor Indutny [Wed, 21 Aug 2013 11:58:33 +0000 (15:58 +0400)]
tls: fix assertion when ssl is destroyed at read
`maybeInitFinished()` can emit the 'secure' event which
in turn destroys the connection in case of authentication
failure and sets `this.pair.ssl` to `null`.
If such condition appeared after non-empty read - loop will continue
and `clearOut` will be called on `null` object instead of
`crypto::Connection` instance. Resulting in the following assertion:
ERROR: Error: Hostname/IP doesn't match certificate's altnames
Assertion failed: handle->InternalFieldCount() > 0
fix #5756
Gil Pedersen [Tue, 20 Aug 2013 13:53:54 +0000 (15:53 +0200)]
fs: use correct self reference for autoClose test
isaacs [Tue, 20 Aug 2013 00:55:58 +0000 (17:55 -0700)]
doc: Minor typos in dgram doc
a/an usage. Thanks @KenanSulayman
Duan Yao [Tue, 4 Dec 2012 10:12:10 +0000 (18:12 +0800)]
doc: Add callback parameter to dgram socket.bind()
Also, describe more details of bind().
ChrisWren [Sun, 11 Aug 2013 19:30:03 +0000 (12:30 -0700)]
doc: fixed syntax error in stream.Transform
Edward Hutchins [Thu, 23 May 2013 01:04:36 +0000 (18:04 -0700)]
Added documentation for process.execArgv
Eivind Uggedal [Thu, 4 Jul 2013 16:52:14 +0000 (18:52 +0200)]
doc: add missing word in Transform stream intro
isaacs [Mon, 19 Aug 2013 14:59:39 +0000 (07:59 -0700)]
stream: Throw on 'error' if listeners removed
In this situation:
writable.on('error', handler);
readable.pipe(writable);
writable.removeListener('error', handler);
writable.emit('error', new Error('boom'));
there is actually no error handler, but it doesn't throw, because of the
fix for stream.once('error', handler), in 23d92ec.
Note that simply reverting that change is not valid either, because
otherwise this will emit twice, being handled the first time, and then
throwing the second:
writable.once('error', handler);
readable.pipe(writable);
writable.emit('error', new Error('boom'));
Fix this with a horrible hack to make the stream pipe onerror handler
added before any other userland handlers, so that our handler is not
affected by adding or removing any userland handlers.
Closes #6007.
Ben Noordhuis [Fri, 9 Aug 2013 00:33:40 +0000 (02:33 +0200)]
dgram: fix assertion on bad send() arguments
Add range checks for the offset, length and port arguments to
dgram.Socket#send(). Fixes the following assertion:
node: ../../src/udp_wrap.cc:264: static v8::Handle<v8::Value>
node::UDPWrap::DoSend(const v8::Arguments&, int): Assertion
`offset < Buffer::Length(buffer_obj)' failed.
And:
node: ../../src/udp_wrap.cc:265: static v8::Handle<v8::Value>
node::UDPWrap::DoSend(const v8::Arguments&, int): Assertion
`length <= Buffer::Length(buffer_obj) - offset' failed.
Interestingly enough, a negative port number was accepted until now but
silently ignored. (In other words, it would send the datagram to a
random port.)
This commit exposed a bug in the simple/test-dgram-close test which
has also been fixed.
This is a back-port of commit 41ec6d0 from the master branch.
Fixes #6025.
Daniel Chatfield [Tue, 30 Jul 2013 13:43:31 +0000 (14:43 +0100)]
readline: pause stdin before turning off terminal raw mode
On windows, libuv will immediately make a `ReadConsole` call (in the
thread pool) when a 'flowing' `uv_tty_t` handle is switched to
line-buffered mode. That causes an immediate issue for some users,
since libuv can't cancel the `ReadConsole` operation on Windows 8 /
Server 2012 and up if the program switches back to raw mode later.
But even if this will be fixed in libuv at some point, it's better to
avoid the overhead of starting work in the thread pool and immediately
cancelling it afther that.
See also f34f1e3, where the same change is made for the opposite
flow, e.g. move `resume()` after `_setRawMode(true)`.
Fixes #5927
This is a backport of dfb0461 (see #5930) to the v0.10 branch.
isaacs [Fri, 16 Aug 2013 19:47:54 +0000 (12:47 -0700)]
blog: v0.10.16
isaacs [Fri, 16 Aug 2013 19:47:29 +0000 (12:47 -0700)]
Now working on v0.10.17