summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2014-05-012014.05.01, Version 0.10.27 (Stable)Timothy J Fontaine
* npm: upgrade to v1.4.8 * openssl: upgrade to 1.0.1g * uv: update to v0.10.27 * dns: fix certain txt entries (Fedor Indutny) * assert: Ensure reflexivity of deepEqual (Mike Pennisi) * child_process: fix deadlock when sending handles (Fedor Indutny) * child_process: fix sending handle twice (Fedor Indutny) * crypto: do not lowercase cipher/hash names (Fedor Indutny) * dtrace: workaround linker bug on FreeBSD (Fedor Indutny) * http: do not emit EOF non-readable socket (Fedor Indutny) * http: invoke createConnection when no agent (Nathan Rajlich) * stream: remove useless check (Brian White) * timer: don't reschedule timer bucket in a domain (Greg Brail) * url: treat the same as / (isaacs) * util: format as Error if instanceof Error (Rod Vagg)
2014-04-10src: use monotonic time for process.uptime()Timothy J Fontaine
`process.uptime()` interface will return the amount of time the current process has been running. To achieve this it was caching the `uv_uptime` value at program start, and then on the call to `process.uptime()` returning the delta between the two values. `uv_uptime` is defined as the number of seconds the operating system has been up since last boot. On sunos this interface uses `kstat`s which can be a significantly expensive operation as it requires exclusive access, but because of the design of `process.uptime()` node *had* to always call this on start. As a result if you had many node processes all starting at the same time you would suffer lock contention as they all tried to read kstats. Instead of using `uv_uptime` to achieve this, the libuv loop already has a concept of current loop time in the form of `uv_now()` which is in fact monotonically increasing, and already stored directly on the loop. By using this value at start every platform performs at least one fewer syscall during initialization. Since the interface to `uv_uptime` is defined as seconds, in the call to `process.uptime()` we now `uv_update_time` get our delta, divide by 1000 to get seconds, and then convert to an `Integer`. In 0.12 we can move back to `Number::New` instead and not lose precision. Caveat: For some platforms `uv_uptime` reports time monotonically increasing regardless of system hibernation, `uv_now` interface is also monotonically increasing but may not reflect time spent in hibernation.
2014-03-26src: ensure that openssl's PRNG is fully seededBen Noordhuis
Ensure that OpenSSL has enough entropy (at least 256 bits) for its PRNG. The entropy pool starts out empty and needs to fill up before the PRNG can be used securely. OpenSSL normally fills the pool automatically but not when someone starts generating random numbers before the pool is full: in that case OpenSSL keeps lowering the entropy estimate to thwart attackers trying to guess the initial state of the PRNG. When that happens, we wait until enough entropy is available, something that normally should never take longer than a few milliseconds. Fixes #7338.
2014-03-26src: seed V8's random number generator at startupBen Noordhuis
The default entropy source is /dev/urandom on UNIX platforms, which is okay but we can do better by seeding it from OpenSSL's entropy pool. On Windows we can certainly do better; on that platform, V8 seeds the random number generator using only the current system time. Fixes #6250. NB: This is a back-port of commit 7ac2391 from the master branch that for some reason never got back-ported to the v0.10 branch. The default on UNIX platforms in v0.10 is different and arguably worse than it is with master: if no entropy source is provided, V8 3.14 calls srandom() with a xor of the PID and the current time in microseconds. That means that on systems with a coarse system clock, the initial state of the PRNG may be easily guessable. The situation on Windows is even more dire because there the PRNG is seeded with only the current time... in milliseconds.
2014-03-05src: add default visibility to NODE_MODULEBen Noordhuis
It's currently not really possible to compile native add-ons with -fvisibility=hidden because that also hides the struct containing the module definition. The NODE_MODULE() and NODE_MODULE_DECL() macros are structured in a way that makes it impossible to add a visibility attribute manually so there is no escape hatch there. That's why this commit adds an explicit visibility attribute to the module definition. It doesn't help with node.js releases that are already out there but at least it improves the situation going forward.
2014-03-03src: domain should not replace nextTick functionTimothy J Fontaine
Previously if you cached process.nextTick and then require('domain') subsequent nextTick() calls would not be caught because enqueued functions were taking the wrong path. This keeps nextTick to a single function reference and changes the implementation details after domain has been required.
2014-02-21dtrace: workaround linker bug on FreeBSDFedor Indutny
2014-02-18Now working on v0.10.27Timothy J Fontaine
2014-02-182014.02.18, Version 0.10.26 (Stable)Timothy J Fontaine
* uv: Upgrade to v0.10.25 (Timothy J Fontaine) * npm: upgrade to 1.4.3 (isaacs) * v8: support compiling with VS2013 (Fedor Indutny) * cares: backport TXT parsing fix (Fedor Indutny) * crypto: throw on SignFinal failure (Fedor Indutny) * crypto: update root certificates (Ben Noordhuis) * debugger: Fix breakpoint not showing after restart (Farid Neshat) * fs: make unwatchFile() insensitive to path (iamdoron) * net: do not re-emit stream errors (Fedor Indutny) * net: make Socket destroy() re-entrance safe (Jun Ma) * net: reset `endEmitted` on reconnect (Fedor Indutny) * node: do not close stdio implicitly (Fedor Indutny) * zlib: avoid assertion in close (Fedor Indutny)
2014-02-18zlib: introduce pending close stateFedor Indutny
zlib should not crash in `close()` if the write is still in progress. fix #7101
2014-02-08src: refactor buffer bounds checkingTimothy J Fontaine
Consolidate buffer bounds checking logic into Buffer namespace and use it consistently throughout the source.
2014-02-04crypto: update root certificatesBen Noordhuis
Update the list of root certificates in src/node_root_certs.h with tools/mk-ca-bundle.pl and update src/node_crypto.cc to make use of the new format. Fixes #6013.
2014-02-01dtrace: fix arguments warningFedor Indutny
Add enough arguments to `NODE_NET_SOCKET_READ()` and `NODE_NET_SOCKET_WRITE()` stubs.
2014-01-30node: do not ever close stdioFedor Indutny
Even if stdio streams are opened as file streams, we should not ever try to close them. This could be accomplished by passing `autoClose: false` in options on their creation.
2014-01-26crypto: throw on SignFinal failureFedor Indutny
fix #6963
2014-01-23Now working on 0.10.26Timothy J Fontaine
2014-01-222014.01.23, Version 0.10.25 (Stable)Timothy J Fontaine
* 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-12src: return empty set on ENOSYS for interfacesTimothy J Fontaine
If node was compiled with --no-ifaddrs to support older operating systems, don't throw instead simply return an empty object Fixes #6846
2014-01-09src: OnFatalError handler must abort()Timothy J Fontaine
We are in an unrecoverable state if v8 throws a FatalError, actually ask the operating system to dump core in this case. Fixes #6836
2013-12-19Now working on 0.10.25Timothy J Fontaine
2013-12-182013.12.18, Version 0.10.24 (Stable)Timothy J Fontaine
* uv: Upgrade to v0.10.21 * npm: upgrade to 1.3.21 * v8: backport fix for CVE-2013-{6639|6640} * build: unix install node and dep library headers (Timothy J Fontaine) * cluster, v8: fix --logfile=%p.log (Ben Noordhuis) * module: only cache package main (Wyatt Preul)
2013-12-11Now working on 0.10.24Timothy J Fontaine
2013-12-112013.12.12, Version 0.10.23 (Stable)Timothy J Fontaine
* uv: Upgrade to v0.10.20 (Timothy J Fontaine) * npm: Upgrade to 1.3.17 (isaacs) * gyp: update to 78b26f7 (Timothy J Fontaine) * build: include postmortem symbols on linux (Timothy J Fontaine) * crypto: Make Decipher._flush() emit errors. (Kai Groner) * dgram: fix abort when getting `fd` of closed dgram (Fedor Indutny) * events: do not accept NaN in setMaxListeners (Fedor Indutny) * events: avoid calling `once` functions twice (Tim Wood) * events: fix TypeError in removeAllListeners (Jeremy Martin) * fs: report correct path when EEXIST (Fedor Indutny) * process: enforce allowed signals for kill (Sam Roberts) * tls: emit 'end' on .receivedShutdown (Fedor Indutny) * tls: fix potential data corruption (Fedor Indutny) * tls: handle `ssl.start()` errors appropriately (Fedor Indutny) * tls: reset NPN callbacks after SNI (Fedor Indutny)
2013-12-10fs: report correct path when EEXISTFedor Indutny
When `symlink`, `link` or `rename` report EEXIST, ENOTEMPTY or EPERM - the destination file name should be included in the error message, instead of source file name. fix #6510
2013-12-10tls: emit 'end' on .receivedShutdownFedor Indutny
NOTE: Also removed `.receivedShutdown` method of `Connection` it wasn't documented anywhere, and was rewritten with `true` after receiving `close_notify`. fix #6638
2013-12-02process: document kill(0), disallow kill(O_RDWR)Sam Roberts
The null signal test existed, but only tested the case where the target process existed, not when it did not exist. Also clarified that SIGUSR1 is reserved by Node.js only for receiveing, its not at all reserved when sending a signal with kill(). kill(pid, 'O_RDWR'), or any other node constant, "worked". I fixed this by also checking for 'SIG'. The same as done in the isSignal() function. Now the signal names supported by process.kill() are the same as those supported by process.on().
2013-12-02tls: reset NPN callbacks after SNIFedor Indutny
SNI callback selects a new SSL_CTX for the connection, which doesn't have NPN callbacks set up.
2013-11-27stream_wrap: don't call Number::New()Ben Noordhuis
Replace call to Number::New() with a call to Integer::NewFromUnsigned(). Profiling a Real World(TM) application with perf(1) suggests that the conversion of its argument from integer to double is disproportionally costly: over 60% of CPU cycles accountable to WriteStringImpl() are attributable to the conversion. After changing it to Integer::NewFromUnsigned(), WriteStringImpl() has dropped from the 'most costly functions' top ten altogether.
2013-11-19dgram: fix abort when getting `fd` of closed dgramFedor Indutny
v8's `messages.js` file's `CallSiteGetMethodName` is running through all object properties and getter to figure out method name of function that appears in stack trace. This run-through will also read `fd` property of `UDPWrap` instance's javascript object, making `UNWRAP()` fail. As a simple alternative to the test case above, one could just keep reference to the dgram handle and try accessing `handle.fd` after it has been fully closed. fix #6536
2013-11-12Now working on 0.10.23Timothy J Fontaine
2013-11-122013.11.12, Version 0.10.22 (Stable)Timothy J Fontaine
* npm: Upgrade to 1.3.14 * uv: Upgrade to v0.10.19 * child_process: don't assert on stale file descriptor events (Fedor Indutny) * darwin: Fix "Not Responding" in Mavericks activity monitor (Fedor Indutny) * debugger: Fix bug in sb() with unnamed script (Maxim Bogushevich) * repl: do not insert duplicates into completions (Maciej Małecki) * src: Fix memory leak on closed handles (Timothy J Fontaine) * tls: prevent stalls by using read(0) (Fedor Indutny) * v8: use correct timezone information on Solaris (Maciej Małecki)
2013-11-12src: add HandleScope in HandleWrap::OnCloseTimothy J Fontaine
Fixes a 4 byte leak on handles closing. AKA The Walmart leak. MakeCallback doesn't have a HandleScope. That means the callers scope will retain ownership of created handles from MakeCallback and related. There is by default a wrapping HandleScope before uv_run, if the caller doesn't have a HandleScope on the stack the global will take ownership which won't be reaped until the uv loop exits. If a uv callback is fired, and there is no enclosing HandleScope in the cb, you will appear to leak 4-bytes for every invocation. Take heed. cc @hueniverse
2013-10-23src: IsInt64() should return bool, not intBen Noordhuis
2013-10-18Now working on 0.10.22Timothy J Fontaine
2013-10-182013.10.18, Version 0.10.21 (Stable)Timothy J Fontaine
* 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)
2013-10-18crypto: clear errors from verify failureTimothy J Fontaine
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
2013-10-16http_parser: expose pause/resume method for parserTimothy J Fontaine
2013-10-09dtrace: backport two byte string fixDave Pacheco
This is a partial backport of 5921158 Re #6309 Closes #6319
2013-09-30Now working on 0.10.21Timothy J Fontaine
2013-09-302013.09.30, Version 0.10.20 (Stable)Timothy J Fontaine
* tls: fix sporadic hang and partial reads (Fedor Indutny) - fixes "npm ERR! cb() never called!"
2013-09-28src: turn uv_pipe_open() failures into exceptionsBen Noordhuis
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.
2013-09-24Now working on 0.10.20Timothy J Fontaine
2013-09-242013.09.24, Version 0.10.19 (Stable)Timothy J Fontaine
* 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)
2013-09-04Now working on 0.10.19Timothy J Fontaine
2013-09-042013.09.04, Version 0.10.18 (Stable)Timothy J Fontaine
* uv: Upgrade to v0.10.15 * stream: Don't crash on unset _events property (isaacs) * stream: Pass 'buffer' encoding with decoded writable chunks (isaacs)
2013-08-21Now working on 0.10.18Timothy J Fontaine
2013-08-212013.08.21, Version 0.10.17 (Stable)Timothy J Fontaine
* 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)
2013-08-16Now working on v0.10.17isaacs
2013-08-162013.08.16, Version 0.10.16 (Stable)isaacs
* v8: back-port fix for CVE-2013-2882 * npm: Upgrade to 1.3.8 * crypto: fix assert() on malformed hex input (Ben Noordhuis) * crypto: fix memory leak in randomBytes() error path (Ben Noordhuis) * events: fix memory leak, don't leak event names (Ben Noordhuis) * http: Handle hex/base64 encodings properly (isaacs) * http: improve chunked res.write(buf) performance (Ben Noordhuis) * stream: Fix double pipe error emit (Eran Hammer)
2013-08-16crypto: fix memory leak in randomBytes() error pathBen Noordhuis
This is the conceptual back-port of commit ec54873 from the master branch.