Commit Graph

9791 Commits (d0ff900a65e4250ad49dcf02e07262af1fa5de25)

Author SHA1 Message Date
isaacs 485fcf9c63 npm: Upgrade to v1.3.25 2014-01-23 13:04:49 -08:00
Trevor Norris 74656ca189 lint: use reinterpret_cast, not C-style casts 2014-01-23 13:01:53 -08:00
Alexis Campailla 42cd468901 test: fix http-incoming-pipelined-socket-destroy
The test was calling server.close() after write on the socket
had completed. However the fact that the write had completed was
not valid indication that the server had received the data.

This would result in a premutaure closing of the server and
an ECONNRESET event on the client.
2014-01-23 12:42:56 -08:00
Alexis Campailla 5d4f4ee310 test: fix http-many-ended-pipelines server close
The test was calling server.close() without waiting for the server
to have received all the requests. This would cause an ECONNRESET.
2014-01-23 12:42:36 -08:00
Trevor Norris f78e5df854 v8: upgrade to 3.22.24.17 2014-01-23 12:26:51 -08:00
Timothy J Fontaine 5aebc73525 blog: Post for v0.10.25 2014-01-23 11:44:32 -08:00
Timothy J Fontaine eb7c7be7da Now working on 0.10.26 2014-01-23 11:44:32 -08:00
Timothy J Fontaine 24d05f21be Merge branch 'v0.10.25-release' into v0.10 2014-01-23 11:44:14 -08:00
Fedor Indutny c79c304ead tls: process accumulated input
When creating TLSSocket on top of the regular socket that already
contains some received data, `_tls_wrap.js` should try to write all that
data to the internal `SSL*` instance.

fix #6940
2014-01-23 20:39:32 +04:00
Timothy J Fontaine b0e5f195df src: lint lib/net.js 2014-01-22 21:05:51 -08:00
Timothy J Fontaine bc2f31ae1d 2014.01.23, Version 0.10.25 (Stable)
* uv: Upgrade to v0.10.23

* npm: Upgrade to v1.3.24

* v8: Fix enumeration for objects with lots of properties

* child_process: fix spawn() optional arguments (Sam Roberts)

* cluster: report more errors to workers (Fedor Indutny)

* domains: exit() only affects active domains (Ryan Graham)

* src: OnFatalError handler must abort() (Timothy J Fontaine)

* stream: writes may return false but forget to emit drain (Yang Tianyang)
2014-01-22 21:03:08 -08:00
Timothy J Fontaine 8b7ec73331 uv: Upgrade to v0.10.23 2014-01-22 20:47:12 -08:00
Trevor Norris 56ebf308dc node: clear nextTickQueue when using domains
When the domain specific code was reintroduced in 828f145 the
conditional to check and clear the nextTickQueue if many items had run
was not introduced. This allows for the application to run out of memory
if domains are being used in an infinite recursive loop.
2014-01-22 13:33:16 -08:00
Vladimir Kurchatkin 103b89673e doc: skip type parsing inside code blocks
Since types are denoted with curly braces it can cause erroneous
replaces in code blocks.

Signed-off-by: Trevor Norris <trev.norris@gmail.com>
2014-01-22 12:27:58 -08:00
Yorkie c7f5c98ee9 crypto: remove duplicate ERR_load_crypto_strings()
ERR_load_crypto_strings() registers the error strings for
all libcrypto functions, SSL_load_error_strings() does the
same, but also registers the libssl error strings.
2014-01-22 22:55:52 +04:00
Ben Noordhuis 6514a4128c test: fix array sorting bug
`a === a.sort()` is always true because Array#sort() does an in-place
sort.  Make a copy of the array first.
2014-01-22 15:58:07 +04:00
Ben Noordhuis 74d9aa49d5 crypto: support custom pbkdf2 digest methods
Make the HMAC digest method configurable.  Update crypto.pbkdf2() and
crypto.pbkdf2Sync() to take an extra, optional digest argument.

Before this commit, SHA-1 (admittedly the most common method) was used
exclusively.

Fixes #6553.
2014-01-22 15:58:07 +04:00
Trevor Norris e6016dae34 node: remove asyncStack
Now that the context stores the active execution stack, and because
removeAsyncListener() always removed the AsyncListener from the queue
and the stack, there's no need to keep a stack around anymore. Instead
the active asyncQueue and the currentContext is able to handle it all.

Signed-off-by: Forrest L Norvell <ogd@aoaioxxysz.net>
2014-01-21 17:12:40 -08:00
Trevor Norris f32c1ffe56 node: only run same AL once on error
Should have been included with 60fcc11 as it is the same type of fix.

Signed-off-by: Forrest L Norvell <ogd@aoaioxxysz.net>
2014-01-21 17:11:48 -08:00
Jo Liss b9bec2031e path: improve POSIX path.join() performance
Performance gains are ~4x (~1.5us), but still much slower than a naive
approach. There is some duplicate work done between join(), normalize()
and normalizeArray() so additional optimizations are possible.

Note that this only improves the POSIX implementation.

Thanks to @isaacs and @othiym23 for helping with this optimization.

Signed-off-by: Trevor Norris <trev.norris@gmail.com>
2014-01-21 17:00:56 -08:00
Fedor Indutny cdde9a386a crypto: add newline to cert and key if not present
After one of OpenSSL updates we have stopped accepting PEM private keys
and certificates that doesn't end with a newline (`\n`) character.
Handle this regression in `crypto.js` to make less trouble to our users.

fix #6892
2014-01-22 02:42:04 +04:00
Fedor Indutny 661190af13 crypto: throw only in direct C++ methods
Do not throw in internal C++ methods, that clobbers logic and may lead
to the situations, where both exception was thrown and the value was
returned (via `args.GetReturnValue().Set()`). That doesn't play nicely
with v8.

fix #6912
2014-01-22 02:25:14 +04:00
Fedor Indutny e57ab7ba06 node: `EmitExit` should not call `exit()`
Before this commit `RunAtExit` and `env->Dispose()` were never reached,
because `EmitExit` was always colling `exit`.
2014-01-22 00:39:13 +04:00
Fedor Indutny 1442c1c6de addons: build and test examples
fix #6910
2014-01-22 00:39:13 +04:00
Alexis Campailla 2a0b619f7b text: give more time to test-next-tick-error-spin
The previous timeout was too short for certain execution conditions
(Windows, debug build, first execution).
2014-01-21 10:23:16 -08:00
Alexis Campailla 22879e749e test: give test-net-GH-5504 more time to run
On Windows debug builds, the test was failing because the timeout
was too short.
2014-01-21 10:21:50 -08:00
Trevor Norris bf08ac462e node: compare AsyncListener instances, not uid's
Now that process.createAsyncListener() returns a unique object instance
it is no longer necessary to compare the uid's of the objects.

Signed-off-by: Timothy J Fontaine <tjfontaine@gmail.com>
2014-01-21 10:20:22 -08:00
Trevor Norris 60fcc11be2 node: ensure same AL inst only runs once
It was possible that the same AL instance was run twice if it were both
attached to the currentContext then again added to the new asyncQueue
generated for the new stack.

Signed-off-by: Timothy J Fontaine <tjfontaine@gmail.com>
2014-01-21 10:20:14 -08:00
Trevor Norris 63ccfc3536 async_wrap/timers: remove Add/RemoveAsyncListener
The ability to add/remove an AsyncListener to an object after its
creation was an artifact of trying to get AL working with the domain
module. Now that is no longer necessary and other features are going to
be implemented that would be affected by this functionality. So the code
will be removed for now to simplify the implementation process.

In the future this code will likely be reintroduced, but after some
other more important matters have been addressed.

None of this functionality was documented, as is was meant specifically
for domain specific implementation work arounds.

Signed-off-by: Timothy J Fontaine <tjfontaine@gmail.com>
2014-01-21 10:20:07 -08:00
Fedor Indutny 159da758e4 crypto: remove most of the `node_isolate` uses
All C++ code should be using `args.GetIsolate()` or `env->isolate()`.
Using static `node_isolate` var limits possible future functionality
(like multi-isolate support).
2014-01-20 23:29:58 +04:00
Alexis Campailla 5393d02c0c test: relax timing in test-http-exit-delay
This test was originally intended to guard against regressions for
commit 16b59cbc74.

As such, it only needs to ensure that process exit has not been held up
by the date cache timer, which would fire on the next second.
2014-01-20 09:14:42 -08:00
Alexis Campailla edfc0d9ffe test: debug-signal-cluster increase timeouts
The test needs a little more time to run so that it passes for all
builds (eg: Windows, debug)
2014-01-20 09:00:14 -08:00
Alexis Campailla e12e72eb58 debug client: connect after child is ready
We now wait to connect to the debuggee until we know that
its error stream has data, to ensure that the output message
"connecting..... ok" appears after "Debugger listening on port xyz"

I also increased the test timeout to let the more complex
tests finish in time on Windows

This change fixes the following unit tests on Windows:
 test-debugger-repl.js
 test-debugger-repl-term.js
 test-debugger-repl-utf8.js
 test-debugger-repl-restart.js
2014-01-20 09:00:14 -08:00
Timothy J Fontaine 574f71444c test: move debugger repl into own section 2014-01-20 09:00:13 -08:00
Timothy J Fontaine 6cc95b06ea test: refactor to use common testcfg 2014-01-20 09:00:13 -08:00
Fedor Indutny 442d2d0cde test: ignore tests when built without OpenSSL CLI
fix #6880
2014-01-20 20:55:54 +04:00
Fedor Indutny 7f9b01509f lib: introduce `.setMaxSendFragment(size)`
fix #6889
2014-01-20 20:39:57 +04:00
Ben Noordhuis 023f0a3122 doc: tls: note that SSLv2 is disabled by default
As of commit 39aa894, SSLv2 support is disabled by default.  Update
the documentation to reflect that.
2014-01-20 19:33:18 +04:00
Ben Noordhuis 8c303115f5 doc: tls: clarify server cipher list
* Make it clear that ECDHE-RSA-AES128-SHA256 and AES128-GCM-SHA256 are
  TLS v1.2 ciphers.

* Note that RC4 is under suspicion.
2014-01-20 19:33:18 +04:00
Fedor Indutny 25f9e92813 gyp: fix non-ninja build 2014-01-20 18:39:05 +04:00
isaacs f645c40fcd npm: Upgrade to v1.3.24 2014-01-19 21:13:20 -08:00
Ben Noordhuis cda41f8775 src: don't mark addon_register_func as dllimport
addon_register_func and its cousin addon_context_register_func are type
definitions, dllimport and dllexport are name mangling directives, i.e.
they're quite unrelated concepts.  MinGW complains about mixing them
when cross-compiling native add-ons.

Signed-off-by: Trevor Norris <trev.norris@gmail.com>
Signed-off-by: Bert Belder <bertbelder@gmail.com>
2014-01-17 15:37:20 -08:00
Ben Noordhuis db5abd726f tls: make cert/pfx optional in tls.createServer()
Not all ciphers require the presence of a certificate.  Remove the
check in lib/_tls_wrap.js.

Fixes #6887.
2014-01-17 18:55:33 +00:00
Ben Noordhuis 262a752c29 tls: show human-readable error messages
Before this commit, verification exceptions had err.message set to the
OpenSSL error code (e.g. 'UNABLE_TO_VERIFY_LEAF_SIGNATURE').

This commit moves the error code to err.code and replaces err.message
with a human-readable error.  Example:

    // before
    {
      message: 'UNABLE_TO_VERIFY_LEAF_SIGNATURE'
    }

    // after
    {
      code: 'UNABLE_TO_VERIFY_LEAF_SIGNATURE',
      message: 'unable to verify the first certificate'
    }

UNABLE_TO_VERIFY_LEAF_SIGNATURE is a good example of why you want this:
the error code suggests that it's the last certificate that fails to
validate while it's actually the first certificate in the chain.

Going by the number of mailing list posts and StackOverflow questions,
it's a source of confusion to many people.
2014-01-17 18:51:25 +00:00
Timothy J Fontaine 1d57a5caa4 blog: nodejs v0.12 roadmap update 2014-01-16 14:43:29 -08:00
Fedor Indutny 61c0d571bf gyp: fix `ninja` build on linux
fix #6679
2014-01-16 17:11:04 +00:00
Sam Roberts abe02553f2 doc: clarify Windows signal sending emulation 2014-01-16 08:41:04 -08:00
Sam Roberts 67e9298fb6 child_process: fix spawn() optional arguments
Spawn's arguments were documented to be optional, as they are for the
other similar child_process APIs, but the code was missing. Result was
`child_process.spawn('node', {})` errored when calling slice() on an
Object, now it behaves as the documentation said it would.
2014-01-16 07:35:12 -08:00
Sam Roberts 198ed0bd0d doc: describe child_process.fork() silent option 2014-01-16 07:35:12 -08:00
Sam Roberts 549be1caa8 doc: child_process.execFile arguments are optional 2014-01-16 07:35:12 -08:00