Commits on Sep 17, 2014

  1. child_process: properly support optional args

    Currently, a TypeError is incorrectly thrown if the second argument is
    an object. This commit allows the args argument to be properly omitted.
    
    Fixes: #6068
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    cjihrig authored and trevnorris committed Sep 17, 2014

Commits on Sep 23, 2014

  1. doc: document _transform callback takes 2 args

    Expands the paragraph in the transform stream
    implementation docs about the callback that is passed
    to the _transform method to include details about how
    two arguments may be passed, error and data.  A code
    example is also included.
    
    Reviewed-By: Fedor Indutny <fedor@indutny.com>
    calvinmetcalf authored and indutny committed Sep 23, 2014

Commits on Sep 26, 2014

  1. hdr: always define NODE_WANT_INTERNALS

    Otherwise the warning could be printed on some systems.
    
    fix #8419
    indutny committed Sep 26, 2014

Commits on Oct 13, 2014

  1. doc: update design to match nodejs.org

    fitzage authored and tjfontaine committed Oct 13, 2014

Commits on Oct 15, 2014

  1. tls add secureOptions documentation

    PR-URL: #8553
    Reviewed-By: Fedor Indutny <fedor@indutny.com>
    Swaagie authored and indutny committed Oct 15, 2014
  2. configure: disable ssl2/ssl3 by default

    PR-URL: #8551
    Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
    indutny committed Oct 15, 2014
  3. doc: document why SSL2/SSL3 is disabled

    PR-URL: #8551
    Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
    indutny committed Oct 15, 2014
  4. deps: update openssl to 1.0.1j

    indutny authored and tjfontaine committed Oct 15, 2014
  5. test: fix test-crypto-stream

    Because of constant-timeness change made in openssl-1.0.1j the error is
    no longer returned from EVP_DecryptFinal_ex. Now it just return 0, and
    thus the error message does not contain proper error code. Adapt to this
    change, there is not much that we could do about it.
    indutny authored and tjfontaine committed Oct 15, 2014

Commits on Oct 16, 2014

  1. crypto: allow runtime opt in using SSLv2/SSLv3

    This change disables SSLv2/SSLv3 use by default, and introduces a
    command line flag to opt into using SSLv2/SSLv3.
    
    SSLv2 and SSLv3 are considered unsafe, and should only be used in
    situations where compatibility with other components is required and
    they cannot be upgrade to support newer forms of TLS.
    tjfontaine committed Oct 16, 2014
  2. test: crypto-domains avoid spurious failures

    The order of the callbacks is non-deterministic, so don't expect the
    error messages to come back in the same order every time, instead just
    verify they are expected messages.
    tjfontaine committed Oct 16, 2014
  3. test: fix test-net-listen-fd0 for pipes

    In the case of a pipe'd input, i.e. from the CI the fd will be a PIPE
    and when listen() is called it will return ENOTSOCK instead of EINVAL.
    
    Backport: cd2d3ae
    tjfontaine committed Oct 16, 2014
  4. crypto: extra caution in setting ssl options

    Always set ssl2/ssl3 disabled based on whether they are enabled in Node.
    In some corner-case scenario, node with OPENSSL_NO_SSL3 defined could
    be linked to openssl that has SSL3 enabled.
    orangemocha committed Oct 16, 2014

Commits on Oct 17, 2014

  1. docs: update api location

    tjfontaine committed Oct 17, 2014

Commits on Oct 20, 2014

  1. doc: add note about key derivation

    adds a note to the crypto docs passing along
    the advice that openssl gives about what
    key derivation function they recommend.
    
    PR-URL: #8580
    Reviewed-By: Fedor Indutny <fedor@indutny.com>
    Calvin Metcalf authored and indutny committed Oct 20, 2014
  2. crypto: allow forcing SSLv2/v3 via secureProtocol

    Force-enable SSLv2/v3 when `secureProtocol` is explicitly set
    to `SSLv2_method` or `SSLv3_method`.
    
    see discussion at #8551
    indutny authored and tjfontaine committed Oct 20, 2014
  3. uv: Update to v0.10.29

    tjfontaine committed Oct 20, 2014

Commits on Oct 21, 2014

  1. 2014.10.20, Version 0.10.33 (Stable)

    * openssl: Update to 1.0.1j (Addressing multiple CVEs)
    
    * uv: Update to v0.10.29
    
    * child_process: properly support optional args (cjihrig)
    
    * crypto: Disable autonegotiation for SSLv2/3 by default (Fedor Indutny,
    Timothy J Fontaine, Alexis Campailla)
    
    This is a behavior change, by default we will not allow the negotiation to
    SSLv2 or SSLv3. If you want this behavior, run Node.js with either
    `--enable-ssl2` or `--enable-ssl3` respectively.
    
    This does not change the behavior for users specifically requesting
    `SSLv2_method` or `SSLv3_method`. While this behavior is not advised, it is
    assumed you know what you're doing since you're specifically asking to use
    these methods.
    tjfontaine committed Oct 21, 2014

Commits on Oct 23, 2014

  1. tls: honorCipherOrder should not degrade defaults

    Specifying honorCipherOrder should not change the SSLv2/SSLv3 defaults
    for a TLS server.
    
    Use secureOptions logic in both lib/tls.js and lib/crypto.js
    tjfontaine committed Oct 23, 2014
  2. tls: enforce secureOptions on incoming clients

    Reuse the secureProtocol and secureOptions of the server when creating
    the secure context for incoming clients.
    tjfontaine committed Oct 23, 2014
  3. tests: add TLS tests matrix

    Add a test that goes through the whole matrix of:
    - command line options (--enable-ssl*)
    - secureOptions
    - secureProtocols
    
    and makes sure that compatible test setups actually work as expected.
    
    The test works by spawning two processes for each test case: one client
    and one server. The test passes if a SSL/TLS connection from the client
    to the server is successful and the test case was supposed to pass, or
    if the connection couldn't be established and the test case was supposed
    to fail.
    
    The test is currently located in the directory 'test/external' because
    it has external dependencies.
    Julien Gilli authored and tjfontaine committed Oct 23, 2014
  4. Now working on 0.10.34

    tjfontaine committed Oct 23, 2014

Commits on Oct 25, 2014

  1. repl: Private Buffer object in lib/* files

    Fixes usage of global object 'Buffer' in lib/* files by ensuring that
    each file does an explicit require('buffer').Buffer.  Previously, when
    running a repl, due to usage of global 'Buffer', any redefinition of
    Buffer would cause a crash eg var Buffer = {}.
    
    Fixes: #8588
    PR-URL: #8603
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    Emmanuel Odeke authored and trevnorris committed Oct 25, 2014

Commits on Nov 4, 2014

Commits on Nov 11, 2014

  1. doc: update openssl commands to use best practices

    This updates key size to 2048 and default hash function to sha256.
    
    Reviewed-By: Fedor Indutny <fedor@indutny.com>
    PR-URL: #8690
    konklone authored and indutny committed Nov 11, 2014

Commits on Nov 14, 2014

  1. doc: clarify dns.lookup vs dns.resolve

    Clarify and emphasize the differences between dns.lookup and the rest of
    the functions in the dns module.
    
    PR-URL: #8726
    Reviewed-by: Chris Dickinson <christopher.s.dickinson@gmail.com>
    Julien Gilli authored and chrisdickinson committed Nov 14, 2014

Commits on Nov 19, 2014

  1. doc: document the fds behind stdin/out/err

    Its common knowledge on unix, but node documentation depends on knowing
    this, as it exposes both streams named after stdio, and the fd numbers,
    so make this explicit.
    
    Fixes: #8624
    PR-URL: #8454
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    sam-github authored and trevnorris committed Nov 19, 2014
  2. test: use assert.throw to test exceptions

    The test wasn't checking directly that an assertion was thrown. Instead,
    it was checking that spawn did not sucessfully spawn a non-existent
    command.
    
    However, the command chosen, dir, exists in GNU coreutils, so it exists
    on Linux (though not on BSD derived OS X). The test as written passed on
    Linux, even with the TypeError it is supposed to be checking for deleted
    from spawn(). It would also pass on Windows if a ls.exe existed.
    
    The approach is unnecessarily obscure, assert.throw() is for asserting
    code throws, using it is more clear and works regardless of what
    commands do or do not exist.
    
    PR-URL: #8454
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    sam-github authored and trevnorris committed Nov 19, 2014
  3. child_process: check execFile args is an array

    execFile and spawn have same API signature with respect to optional arg
    array and optional options object, they should have same behaviour with
    respect to argument validation.
    
    PR-URL: #8454
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    sam-github authored and trevnorris committed Nov 19, 2014
  4. child_process: check fork args is an array

    Optional fork args should be type-checked with same behaviour as the
    equivalent argument to spawn.
    
    PR-URL: #8454
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    sam-github authored and trevnorris committed Nov 19, 2014
  5. test: test all spawn parameter positions

    PR-URL: #8454
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    sam-github authored and trevnorris committed Nov 19, 2014
  6. v8: add api for aborting on uncaught exception

    Add v8::Isolate::SetAbortOnUncaughtException() so the user can be
    notified when an uncaught exception has bubbled.
    
    PR-URL: #8666
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    trevnorris committed Nov 19, 2014
  7. domains: fix issues with abort on uncaught

    Do not abort the process if an error is thrown from within a domain, an
    error handler is setup for the domain and --abort-on-uncaught-exception
    was passed on the command line.
    
    However, if an error is thrown from within the top-level domain's error
    handler and --abort-on-uncaught-exception was passed on the command
    line, make the process abort.
    
    Fixes: #8631
    Fixes: #8630
    PR-URL: #8666
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    Julien Gilli authored and trevnorris committed Nov 19, 2014
  8. lint: fix lint issues

    Forgot to fix these before landing the patch.
    
    Fixes: e17c5a7
    trevnorris committed Nov 19, 2014
  9. doc: cover stdio option in child_process

    - Add hyperlinks from spawn options to subsections detailing what
    those options do.
    - Clarify some verbiage around ChildProcess.prototype.std{in,out,err}.
    - Remove second-person pronoun.
    
    PR-URL: #8639
    Reviewed-by: Chris Dickinson <christopher.s.dickinson@gmail.com>
    sam-github authored and chrisdickinson committed Nov 19, 2014

Commits on Nov 26, 2014

  1. timers: fix unref() memory leak

    The destructor isn't being called for timers that have been unref'd.
    
    Fixes: #8364
    Signed-off-by: Trevor Norris <trev.norris@gmail.com>
    trevnorris committed Nov 26, 2014

Commits on Dec 4, 2014

  1. tools: bundle mk-ca-bundle.pl from upstream curl

    This is a back-port of commit 5ab863d from the master branch.
    bnoordhuis authored and indutny committed Dec 4, 2014
  2. tools: customize mk-ca-bundle.pl

    Remove unneeded functionality and tweak the generated output so we
    can #include it in C++ source code.
    
    This is a back-port of commit e159073 from the master branch.
    bnoordhuis authored and indutny committed Dec 4, 2014
  3. crypto: update root certificates

    Update tools/certdata.txt to [0] (last updated on 2014-11-14) and
    rebuild src/node_root_certs.h.
    
    Refs #8679 and #8709.
    
    [0] https://hg.mozilla.org/mozilla-central/raw-file/64206634959a/security/nss/lib/ckfw/builtins/certdata.txt
    bnoordhuis authored and indutny committed Dec 4, 2014
  4. zlib: do not Unref() if wasn't Ref()ed

    In very unlikely case, where `deflateInit2()` may return error (right
    now happening only on exhausting all memory), the `ZCtx::Error()` will
    be called and will try to `Unref()` the handle. But the problem is that
    this handle was never `Ref()`ed, so it will trigger an assertion error
    and crash the program.
    
    Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
    PR-URL: #8687
    indutny committed Dec 4, 2014

Commits on Dec 5, 2014

  1. doc: fix grammar in tls and timers

    Replace 'a' with 'an' where appropriate.
    brendanashworth authored and Julien Gilli committed Dec 5, 2014

Commits on Dec 7, 2014

  1. docs: fix streams example for write() after end()

    Currently there's an example using http.ServerResponse stream, which
    has a known bug and will not throw an error while writing after end().
    Changed to a writable stream from fs which behaves as expected.
    
    fix #8814
    
    Signed-off-by: Julien Gilli <julien.gilli@joyent.com>
    a0viedo authored and Julien Gilli committed Dec 7, 2014

Commits on Dec 8, 2014

  1. doc: clearer log messages in net code samples

    Code examples in documentation for net.createServer and
    net.createConnection contained confusing log messages. This change makes
    them clearer.
    
    Signed-off-by: Julien Gilli <julien.gilli@joyent.com>
    pkcs authored and Julien Gilli committed Dec 8, 2014

Commits on Dec 9, 2014

  1. deps: update libuv to 0.10.30

    PR-URL: #8849
    Reviewed-by: Trevor Norris <trev.norris@gmail.com>
    saghul authored and trevnorris committed Dec 9, 2014