0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-29 15:06:33 +01:00
Commit Graph

216 Commits

Author SHA1 Message Date
Filip Skokan
71b00f0b5b doc: fix keyObject.symmetricSize to be keyObject.symmetricKeySize
PR-URL: https://github.com/nodejs/node/pull/25670
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com>
2019-01-26 03:09:18 +02:00
Ruben Bridgewater
d3f8f905b3
2019-01-17, Version 11.7.0 (Current), @BridgeAR
Notable Changes

* compression / zlib:
  * Added brotli support (Anna Henningsen and Zach Vacura)
    https://github.com/nodejs/node/pull/24938
* console:
  * Added `inspectOptions` option (Ruben Bridgewater)
    https://github.com/nodejs/node/pull/24978
* crypto:
  * Always accept private keys as public keys (Tobias Nießen)
    https://github.com/nodejs/node/pull/25217
* deps:
  * Upgrade npm to v6.5.0 (Jordan Harband)
    https://github.com/nodejs/node/pull/25234
* fs:
  * Use internalBinding('fs') internally instead of
    process.binding('fs') (Masashi Hirano)
    https://github.com/nodejs/node/pull/22478
* http(s):
  * Support overriding http\\s.globalAgent (Roy Sommer)
    https://github.com/nodejs/node/pull/25170
* util:
  * Inspect ArrayBuffers contents closely (Ruben Bridgewater)
    https://github.com/nodejs/node/pull/25006
* worker:
  * Expose workers by default and remove `--experimental-worker` flag
    (Anna Henningsen) https://github.com/nodejs/node/pull/25361

PR-URL: https://github.com/nodejs/node/pull/25537
2019-01-18 14:03:19 +01:00
Sam Roberts
273d7dd8b8 doc: improve Sign/Verify examples and docs
- Use complete examples that can be pasted and run as-is
- Move note about algorithm to the functions it applies to
- Uncapitalize inconsistence use of "Class"
- Use both EC and RSA keys in the examples
- Note that hash and digest are two names for the same algorithms

PR-URL: https://github.com/nodejs/node/pull/25452
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-01-14 15:32:57 -08:00
Matteo Collina
2d2f82c413 doc: make sure that calls to .read() are looped
The 'readable' event assumes that calls to readable.read() happens
within that event handler until readable.read() returns null.

Fixes: https://github.com/nodejs/node/issues/20503
PR-URL: https://github.com/nodejs/node/pull/25375
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2019-01-10 11:19:38 +01:00
Tobias Nießen
ae2d1f0e05
crypto: always accept private keys as public keys
Some APIs already accept private keys instead of public keys. This
changes all relevant crypto APIs to do so.

PR-URL: https://github.com/nodejs/node/pull/25217
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
2019-01-08 00:20:09 +01:00
Tobias Nießen
7afdfaec08 crypto: fix key object wrapping in sync keygen
PR-URL: https://github.com/nodejs/node/pull/25326
Fixes: https://github.com/nodejs/node/issues/25322
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2019-01-07 07:33:35 +01:00
Tobias Nießen
345d3f380b
doc: document key encryption options
PR-URL: https://github.com/nodejs/node/pull/23632
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
2019-01-05 17:54:43 +01:00
Myles Borins
e01999db14
2018-12-26, Version 11.6.0 (Current)
Notable Changes:

* cli:
  - add --max-http-header-size flag (cjihrig)
    https://github.com/nodejs/node/pull/24811
* crypto:
  - always accept certificates as public keys (Tobias Nießen)
    https://github.com/nodejs/node/pull/24234
  - add key object API (Tobias Nießen) [#24234](https://github.com/nodejs/node/pull/24234)
  - update root certificates (Sam Roberts)
    https://github.com/nodejs/node/pull/25113
* deps:
  - upgrade to libuv 1.24.1 (cjihrig)
    https://github.com/nodejs/node/pull/25078
  - upgrade npm to 6.5.0 (Audrey Eschright)
    https://github.com/nodejs/node/pull/24734
* http:
  - add maxHeaderSize property (cjihrig)
    https://github.com/nodejs/node/pull/24860

PR-URL: https://github.com/nodejs/node/pull/25175
2018-12-26 11:24:51 -05:00
Tobias Nießen
8f300bc8a7 crypto: always accept certificates as public keys
PR-URL: https://github.com/nodejs/node/pull/24234
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-12-24 14:50:25 +01:00
Tobias Nießen
823d86c47c crypto: add key object API
This commit makes multiple important changes:

1. A new key object API is introduced. The KeyObject class itself is
   not exposed to users, instead, several new APIs can be used to
   construct key objects: createSecretKey, createPrivateKey and
   createPublicKey. The new API also allows to convert between
   different key formats, and even though the API itself is not
   compatible to the WebCrypto standard in any way, it makes
   interoperability much simpler.

2. Key objects can be used instead of the raw key material in all
   relevant crypto APIs.

3. The handling of asymmetric keys has been unified and greatly
   improved. Node.js now fully supports both PEM-encoded and
   DER-encoded public and private keys.

4. Conversions between buffers and strings have been moved to native
   code for sensitive data such as symmetric keys due to security
   considerations such as zeroing temporary buffers.

5. For compatibility with older versions of the crypto API, this
   change allows to specify Buffers and strings as the "passphrase"
   option when reading or writing an encoded key. Note that this
   can result in unexpected behavior if the password contains a
   null byte.

PR-URL: https://github.com/nodejs/node/pull/24234
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-12-24 14:50:16 +01:00
Ruben Bridgewater
1f85ea979c
tools: capitalize sentences
This adds the `capitalized-comments` eslint rule to verify that
actual sentences use capital letters as starting letters. It ignores
special words and all lines below 62 characters.

PR-URL: https://github.com/nodejs/node/pull/24808
Reviewed-By: Sam Ruby <rubys@intertwingly.net>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
2018-12-10 17:07:18 +01:00
Thomas Watson
fa19ce9233
doc: fix added version of randomFill+randomFillSync
PR-URL: https://github.com/nodejs/node/pull/24812
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-12-03 20:58:14 +01:00
Sam Roberts
64cea5a1ac doc: sort bottom-of-file markdown links
Reapply https://github.com/nodejs/node/pull/12726

It would be nice to have the sort check applied as part of doc testing,
but this change doesn't implement that.

PR-URL: https://github.com/nodejs/node/pull/24679
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-11-28 13:09:31 -08:00
Mayank Asthana
97309030ef doc: update crypto examples to not use deprecated api
Updated Cipher and Decipher examples to not use deprecated
`crypto.createCipher` and `crypto.createDecipher` in examples and
instead use `createCipheriv` and `createDecipheriv`.

Fixes: https://github.com/nodejs/node/issues/24046

PR-URL: https://github.com/nodejs/node/pull/24107
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
2018-11-18 23:26:00 -08:00
Ruben Bridgewater
406d9caab5
2018-11-15, Version 11.2.0 (Current)
Notable changes:

* deps:
  * A new experimental HTTP parser (`llhttp`) is now supported.
    https://github.com/nodejs/node/pull/24059
* timers:
  * Fixed an issue that could cause setTimeout to stop working as
    expected. https://github.com/nodejs/node/pull/24322
* Windows
  * A crashing process will now show the names of stack frames if the
    node.pdb file is available.
    https://github.com/nodejs/node/pull/23822
  * Continued effort to improve the installer's new stage that installs
    native build tools.
    https://github.com/nodejs/node/pull/23987,
    https://github.com/nodejs/node/pull/24348
  * child_process:
    * On Windows the `windowsHide` option default was restored to
      `false`. This means `detached` child processes and GUI apps will
      once again start in a new window.
      https://github.com/nodejs/node/pull/24034
* Added new collaborators:
  * [oyyd](https://github.com/oyyd) - Ouyang Yadong.
    https://github.com/nodejs/node/pull/24300
  * [psmarshall](https://github.com/psmarshall) - Peter Marshall.
    https://github.com/nodejs/node/pull/24170
  * [shisama](https://github.com/shisama) - Masashi Hirano.
    https://github.com/nodejs/node/pull/24136

PR-URL: https://github.com/nodejs/node/pull/24350
2018-11-15 22:16:09 +01:00
Sam Roberts
426ca0837a doc: clarify allowed encoding parameter types
This fixes the incorrect enumerations of their possible values, which
weren't up to date with the values actually supported. Also renamed
two arguments that used "format" when they meant "encoding".

PR-URL: https://github.com/nodejs/node/pull/24230
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-11-09 15:57:17 -08:00
chux0519
5c59622243 crypto: add support for chacha20-poly1305 for AEAD
openSSL supports AEAD_CHACHA20_POLY1305(rfc7539) since 1.1.

PR-URL: https://github.com/nodejs/node/pull/24081
Fixes: https://github.com/nodejs/node/issues/24080
Refs: https://tools.ietf.org/html/rfc7539
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-11-07 18:43:41 -05:00
Ouyang Yadong
5689d55392 doc: add types and their corresponding return values
This commit supplements some types and their corresponding return
values in docs, including `AsyncResource`, `DiffieHellman`,
`ECDH`, `https.Server`, `repl.REPLServer`.

PR-URL: https://github.com/nodejs/node/pull/23998
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-11-02 00:36:40 +02:00
Denys Otrishko
f90cf19fdd
doc: remove notice of dashes in V8 options
Previously only V8 options supported both dashes in them (making them
equivalent), but now Node.js also supports both styles so the note can
be removed.

PR-URL: https://github.com/nodejs/node/pull/23903
Refs: https://github.com/nodejs/node/pull/18592
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: George Adams <george.adams@uk.ibm.com>
2018-10-29 21:24:08 +00:00
James M Snell
3516052bee
2018-10-23, Version 11.0.0 (Current)
Notable changes:

* Build
  * FreeBSD 10 is no longer supported.[#22617](https://github.com/nodejs/node/pull/22617)
* `child_process`
  * The default value of the `windowsHide` option has been changed
    to `true`. [#21316](https://github.com/nodejs/node/pull/21316)
* `console`
  * `console.countReset()` will emit a warning if the timer
    being reset does not exist. [#21649](https://github.com/nodejs/node/pull/21649)
  * `console.time()` will no longer reset a timer if it already
    exists. [#20442](https://github.com/nodejs/node/pull/20442)
* Dependencies
  * V8 has been updated to 7.0.
    [#22754](https://github.com/nodejs/node/pull/22754)
* `fs`
  * The `fs.read()` method now requires a callback.
    [#22146](https://github.com/nodejs/node/pull/22146)
  * The previously deprecated `fs.SyncWriteStream` utility has been
    removed.[#20735](https://github.com/nodejs/node/pull/20735)
* `http`
  * The `http`, `https`, and `tls` modules now use the WHATWG URL parser
    by default. [#20270](https://github.com/nodejs/node/pull/20270)
* General
  * Use of `process.binding()` has been deprecated. Userland code using
    `process.binding()` should re-evaluate that use and begin migrating. If
    there are no supported API alternatives, please open an issue in the
    Node.js GitHub repository so that a suitable alternative may be discussed.
  * An experimental implementation of `queueMicrotask()` has been added.
    [#22951](https://github.com/nodejs/node/pull/22951)
* Internal
  * Windows performance-counter support has been removed.
    [#22485](https://github.com/nodejs/node/pull/22485)
  * The `--expose-http2` command-line option has been removed.
    [#20887](https://github.com/nodejs/node/pull/20887)
* Timers
  * Interval timers will be rescheduled even if previous interval threw
    an error. [#20002](https://github.com/nodejs/node/pull/20002)
* `util`
  * The WHATWG `TextEncoder` and `TextDecoder` are now globals.
    [#22281](https://github.com/nodejs/node/pull/22281)
  * `util.inspect()` output size is limited to 128 MB by default.
    [#22756](https://github.com/nodejs/node/pull/22756)
  * A runtime warning will be emitted when `NODE_DEBUG` is set for
    either `http` or `http2`. [#21914](https://github.com/nodejs/node/pull/21914)
2018-10-23 11:03:02 -07:00
James M Snell
814f89db61
doc: add missing deprecation labels
Fixes: https://github.com/nodejs/node/issues/20841

PR-URL: https://github.com/nodejs/node/pull/23761
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Shelley Vohr <codebytere@gmail.com>
Reviewed-By: Matheus Marchini <mat@mmarchini.me>
2018-10-19 14:38:47 -07:00
Michaël Zasso
cd8ee2d033
2018-10-10, Version 10.12.0 (Current)
Notable changes:

* assert
  * The diff output is now a tiny bit improved by sorting object
    properties when inspecting the values that are compared with each
    other. https://github.com/nodejs/node/pull/22788
* cli
  * The options parser now normalizes `_` to `-` in all multi-word
    command-line flags, e.g. `--no_warnings` has the same effect as
    `--no-warnings`. https://github.com/nodejs/node/pull/23020
  * Added bash completion for the `node` binary. To generate a bash
    completion script, run `node --completion-bash`. The output can be
    saved to a file which can be sourced to enable completion.
    https://github.com/nodejs/node/pull/20713
* crypto
  * Added support for PEM-level encryption.
    https://github.com/nodejs/node/pull/23151
  * Added an API asymmetric key pair generation. The new methods
    `crypto.generateKeyPair` and `crypto.generateKeyPairSync` can be
    used to generate public and private key pairs. The API supports
    RSA, DSA and EC and a variety of key encodings (both PEM and DER).
    https://github.com/nodejs/node/pull/22660
* fs
  * Added a `recursive` option to `fs.mkdir` and `fs.mkdirSync`. If
    this option is set to true, non-existing parent folders will be
    automatically created. https://github.com/nodejs/node/pull/21875
* http2
  * Added a `'ping'` event to `Http2Session` that is emitted whenever a
    non-ack `PING` is received.
    https://github.com/nodejs/node/pull/23009
  * Added support for the `ORIGIN` frame.
    https://github.com/nodejs/node/pull/22956
  * Updated nghttp2 to 1.34.0. This adds RFC 8441 extended connect
    protocol support to allow use of WebSockets over HTTP/2.
    https://github.com/nodejs/node/pull/23284
* module
  * Added `module.createRequireFromPath(filename)`. This new method can
    be used to create a custom require function that will resolve
    modules relative to the filename path.
    https://github.com/nodejs/node/pull/19360
* process
  * Added a `'multipleResolves'` process event that is emitted whenever
    a `Promise` is attempted to be resolved multiple times, e.g. if the
    `resolve` and `reject` functions are both called in a `Promise`
    executor. https://github.com/nodejs/node/pull/22218
* url
  * Added `url.fileURLToPath(url)` and `url.pathToFileURL(path)`. These
    methods can be used to correctly convert between file: URLs and
    absolute paths. https://github.com/nodejs/node/pull/22506
* util
  * Added the `sorted` option to `util.inspect()`. If set to `true`,
    all properties of an object and Set and Map entries will be sorted
    in the returned string. If set to a function, it is used as a
    compare function. https://github.com/nodejs/node/pull/22788
  * The `util.instpect.custom` symbol is now defined in the global
    symbol registry as `Symbol.for('nodejs.util.inspect.custom')`.
    https://github.com/nodejs/node/pull/20857
  * Added support for `BigInt` numbers in `util.format()`.
    https://github.com/nodejs/node/pull/22097
* V8 API
  * A number of V8 C++ APIs have been marked as deprecated since they
    have been removed in the upstream repository. Replacement APIs
    are added where necessary. https://github.com/nodejs/node/pull/23159
* Windows
  * The Windows msi installer now provides an option to automatically
    install the tools required to build native modules.
    https://github.com/nodejs/node/pull/22645
* Workers
  * Debugging support for Workers using the DevTools protocol has been
    implemented. https://github.com/nodejs/node/pull/21364
  * The public `inspector` module is now enabled in Workers.
    https://github.com/nodejs/node/pull/22769
* Added new collaborators:
  * digitalinfinity - Hitesh Kanwathirtha

PR-URL: https://github.com/nodejs/node/pull/23313
2018-10-10 23:18:55 +02:00
Tobias Nießen
058c5b81cd
crypto: do not allow multiple calls to setAuthTag
Calling setAuthTag multiple times can result in hard to detect bugs
since to the user, it is unclear which invocation actually affected
OpenSSL.

PR-URL: https://github.com/nodejs/node/pull/22931
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
2018-09-21 11:40:35 +02:00
Tobias Nießen
085dcf0e59
crypto: allow promisifying generateKeyPair
PR-URL: https://github.com/nodejs/node/pull/22660
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-09-20 14:31:18 +02:00
Tobias Nießen
8c502f54ce
crypto: add API for key pair generation
This adds support for RSA, DSA and EC key pair generation with a
variety of possible output formats etc.

PR-URL: https://github.com/nodejs/node/pull/22660
Fixes: https://github.com/nodejs/node/issues/15116
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-09-20 14:31:14 +02:00
Tobias Nießen
19ad6b8f72
crypto: deprecate digest == null in PBKDF2
I assume that permitting digest === null was unintentional when
digest === undefined was deprecated since their behavior was
equivalent. The sha1 default for digest === null has somehow made it
through refactoring of the PBKDF2 module multiple times, even though
digest === undefined has been EOL for some time now.

This change deprecates setting digest to null so we can fix the
behavior in Node.js 12 or so.

PR-URL: https://github.com/nodejs/node/pull/22861
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-09-19 18:31:28 +02:00
MaleDong
ba0b4e43e4
lib,doc: remove unused parameter, improve docs
1) Remove 'callback' in 'check' function, because we don't check or use
that directly.

2) Make 'digest' clearer in the documentation.

PR-URL: https://github.com/nodejs/node/pull/22858
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-09-18 16:06:32 +02:00
Anna Henningsen
c33e27dc3c
doc: improve asymmetric crypto docs
Refs: https://github.com/nodejs/node/issues/22792

PR-URL: https://github.com/nodejs/node/pull/22820
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-09-17 17:15:14 +02:00
Mohit kumar Bajoria
cb3d6d5113
doc: add missing options for crypto sign.sign()
Fixes: https://github.com/nodejs/node/issues/22813

PR-URL: https://github.com/nodejs/node/pull/22824
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2018-09-17 14:49:20 +02:00
Michaël Zasso
ed976d76b0
2018-09-06, Version 10.10.0 (Current)
Notable changes:

* child_process:
  * `TypedArray` and `DataView` values are now accepted as input by
    `execFileSync` and `spawnSync`. https://github.com/nodejs/node/pull/22409
* coverage:
  * Native V8 code coverage information can now be output to disk by setting the
    environment variable `NODE_V8_COVERAGE` to a directory. https://github.com/nodejs/node/pull/22527
* deps:
  * The bundled npm was upgraded to version 6.4.1. https://github.com/nodejs/node/pull/22591
    * Changelogs:
      [6.3.0-next.0](https://github.com/npm/cli/releases/tag/v6.3.0-next.0)
      [6.3.0](https://github.com/npm/cli/releases/tag/v6.3.0)
      [6.4.0](https://github.com/npm/cli/releases/tag/v6.4.0)
      [6.4.1](https://github.com/npm/cli/releases/tag/v6.4.1)
* fs:
  * The methods `fs.read`, `fs.readSync`, `fs.write`, `fs.writeSync`,
    `fs.writeFile` and `fs.writeFileSync` now all accept `TypedArray` and
    `DataView` objects. https://github.com/nodejs/node/pull/22150
  * A new boolean option, `withFileTypes`, can be passed to to `fs.readdir` and
    `fs.readdirSync`. If set to true, the methods return an array of directory
    entries. These are objects that can be used to determine the type of each
    entry and filter them based on that without calling `fs.stat`. https://github.com/nodejs/node/pull/22020
* http2:
  * The `http2` module is no longer experimental. https://github.com/nodejs/node/pull/22466
* os:
  * Added two new methods: `os.getPriority` and `os.setPriority`, allowing to
    manipulate the scheduling priority of processes. https://github.com/nodejs/node/pull/22407
* process:
  * Added `process.allowedNodeEnvironmentFlags`. This object can be used to
    programmatically validate and list flags that are allowed in the
    `NODE_OPTIONS` environment variable. https://github.com/nodejs/node/pull/19335
* src:
  * Deprecated option variables in public C++ API. https://github.com/nodejs/node/pull/22515
  * Refactored options parsing. https://github.com/nodejs/node/pull/22392
* vm:
  * Added `vm.compileFunction`, a method to create new JavaScript functions from
    a source body, with options similar to those of the other `vm` methods. https://github.com/nodejs/node/pull/21571
* Added new collaborators:
  * [lundibundi](https://github.com/lundibundi) - Denys Otrishko

PR-URL: https://github.com/nodejs/node/pull/22716
2018-09-06 23:57:43 +02:00
Tobias Nießen
64cf96d684
doc: improve ECDH example
PR-URL: https://github.com/nodejs/node/pull/22607
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-09-03 10:51:13 +02:00
Vse Mozhet Byt
1a25f9639a doc: remove redundant 'Example:' and similar notes
Some nits were also fixed in passing.

PR-URL: https://github.com/nodejs/node/pull/22537
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-08-29 16:53:03 +03:00
Rod Vagg
97c1fa3d3b 2018-08-15, Version 10.9.0 (Current)
Notable changes:

* buffer:
  * Fix out-of-bounds (OOB) write in `Buffer.write()` for UCS-2 encoding
    (CVE-2018-12115)
  * Fix unintentional exposure of uninitialized memory in `Buffer.alloc()`
    (CVE-2018-7166)
* deps:
  * Upgrade to OpenSSL 1.1.0i, fixing:
    - Client DoS due to large DH parameter (CVE-2018-0732)
    - ECDSA key extraction via local side-channel (CVE not assigned)
  * Upgrade V8 from 6.7 to 6.8 (Michaël Zasso) #21079
    - Memory reduction and performance improvements, details at:
      https://v8project.blogspot.com/2018/06/v8-release-68.html
* http: `http.get()` and `http.request()` (and `https` variants) can now accept
  three arguments to allow for a `URL` _and_ an `options` object
  (Sam Ruby) #21616
* Added new collaborators
  * Sam Ruby (https://github.com/rubys)
  * George Adams (https://github.com/gdams)
2018-08-16 11:52:38 +10:00
Gerhard Stoebich
acc633c76e doc: correct crypto.randomFill() and randomFillSync()
Correct return type of `crypto.randomFillSync()` which is of same type as
passed as `buffer` argument.

Correct samples for `randomFill()` and `randomFillSync()` using a `TypeArray`
or `DataView` as these types don't support `.toString(encoding)`.

PR-URL: https://github.com/nodejs/node/pull/21550
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-08-05 10:55:07 -07:00
Anna Henningsen
e9b22e9569
crypto: add better scrypt option aliases
Make parameter names available in a human-readable way, for
more accessible/self-documenting usage of the `scrypt` functions.

This implements a review comment from the original PR that has
not been addressed.

Refs: https://github.com/nodejs/node/pull/20816#discussion_r189220776

PR-URL: https://github.com/nodejs/node/pull/21525
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
2018-07-18 14:18:01 +02:00
Tobias Nießen
b3f459e6cf
crypto: add support for OCB mode for AEAD
PR-URL: https://github.com/nodejs/node/pull/21447
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-07-18 13:10:10 +02:00
Sam Ruby
6a99e3e21c doc: make markdown input compliant
PR-URL: https://github.com/nodejs/node/pull/21780
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-07-16 00:04:56 +03:00
Sam Ruby
40c85ff063 doc: declare all parameter types
PR-URL: https://github.com/nodejs/node/pull/21782
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-07-15 23:57:35 +03:00
Vse Mozhet Byt
3ffbbd3eef doc: prevent some redirections
Replace some redirected URLs with the final ones.

PR-URL: https://github.com/nodejs/node/pull/21811
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-07-14 22:57:03 +03:00
Antoine du HAMEL
d2ee7d64aa crypto: remove deprecated legacy API
The `crypto.Credentials` legacy API has been Runtime deprecated since
v0.11.13 and users had been adviced to use `tls.SecureContext` instead.

PR-URL: https://github.com/nodejs/node/pull/21153
Fixes: https://github.com/nodejs/node/issues/20793
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-07-13 17:47:13 +03:00
Rich Trott
dd023df135 doc: add links to inline HTML table
Links in crypto.md table have been autolinking, but correct
Markdown processing will not autolink in block elements like tables.
Upcoming marked 0.4.0 will not autolink in this instance, so add the
links as anchor elements.

PR-URL: https://github.com/nodejs/node/pull/21678
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-07-06 08:39:40 -07:00
Gerhard Stoebich
4218573095 doc: add DataView to appropriate crypto methods
crypto.scrypt(), crypto.scryptSync(),
crypto.pbkdf2(), and crypto.pbkdf2Sync()
support also DataView like most other crypto APIs.

PR-URL: https://github.com/nodejs/node/pull/21549
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-06-28 21:33:42 +03:00
Victor Belozyorov
02fd93d91a doc: fix code example and formatting in crypto.md
PR-URL: https://github.com/nodejs/node/pull/21500
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-06-27 20:33:27 +03:00
Tobias Nießen
193d6d1bda
doc: update notes about GCM decryption
Given that https://github.com/nodejs/node/pull/17825 and
https://github.com/nodejs/node/pull/20039 have landed on master, this
statement is no longer true.

PR-URL: https://github.com/nodejs/node/pull/21445
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-06-24 15:43:22 +02:00
ZaneHannanAU
c041fd2dc7 doc: correct parameters, return types in crypto.md
PR-URL: https://github.com/nodejs/node/pull/21420
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-06-24 15:59:08 +03:00
Michaël Zasso
680aeb3467
2018-16-20, Version 10.5.0 (Current)
Notable changes:

* **crypto**:
  * Support for `crypto.scrypt()` has been added.
    [#20816](https://github.com/nodejs/node/pull/20816)
* **fs**:
  * BigInt support has been added to `fs.stat` and `fs.watchFile`.
    [#20220](https://github.com/nodejs/node/pull/20220)
  * APIs that take `mode` as arguments no longer throw on values larger
    than `0o777`. [#20636](https://github.com/nodejs/node/pull/20636)
    [#20975](https://github.com/nodejs/node/pull/20975)
    (Fixes: [#20498](https://github.com/nodejs/node/issues/20498))
  * Fix crashes in closed event watchers.
    [#20985](https://github.com/nodejs/node/pull/20985)
    (Fixes: [#20297](https://github.com/nodejs/node/issues/20297))
* **Worker Threads**:
  * Support for multi-threading has been added behind the
    `--experimental-worker` flag in the `worker_threads` module.
    This feature is *experimental* and may receive breaking changes at
    any time. [#20876](https://github.com/nodejs/node/pull/20876)

PR-URL: https://github.com/nodejs/node/pull/21400
2018-06-20 20:39:16 +02:00
Rich Trott
859a8d1907 doc: use Class Method label consistently
The Buffer doc has a helpful "Class Method" label before static methods
on the Buffer class. The only other class in the docs that I can find
with static methods is ECDH in crypto. Add the label to the one static
method on the ECDH class.

PR-URL: https://github.com/nodejs/node/pull/21357
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
2018-06-16 07:56:51 -07:00
Ben Noordhuis
371103dae8 crypto: add scrypt() and scryptSync() methods
Scrypt is a password-based key derivation function that is designed to
be expensive both computationally and memory-wise in order to make
brute-force attacks unrewarding.

OpenSSL has had support for the scrypt algorithm since v1.1.0.  Add a
Node.js API modeled after `crypto.pbkdf2()` and `crypto.pbkdf2Sync()`.

Changes:

* Introduce helpers for copying buffers, collecting openssl errors, etc.

* Add new infrastructure for offloading crypto to a worker thread.

* Add a `AsyncWrap` JS class to simplify pbkdf2(), randomBytes() and
  scrypt().

Fixes: https://github.com/nodejs/node/issues/8417
PR-URL: https://github.com/nodejs/node/pull/20816
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-06-13 15:58:45 +02:00
Rich Trott
85fe134026 doc: remove spaces around slashes
Remove spaces around slash characters in documentation. This change
sometimes rewords the content where the slash construction may not be
what is called for.

PR-URL: https://github.com/nodejs/node/pull/21140
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-06-06 21:23:00 -07:00
Rich Trott
1252907c6c doc: simplify deprecation language
Change instances of `foo has been deprecated` to `foo is deprecated` and
similar.

PR-URL: https://github.com/nodejs/node/pull/21136
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-06-06 21:06:13 -07:00
Diego Rodríguez Baquero
62c8fb33a6 doc: make constants enumeration consistent
Add missing prefix `crypto.constants.` to `RSA_PKCS1_PADDING`
in `crypto.privateEncrypt()`, `crypto.privateDecrypt()`,
`crypto.publicEncrypt()`, and `crypto.publicDecrypt()`.

PR-URL: https://github.com/nodejs/node/pull/20991
Reviewed-By: Weijia Wang <starkwang@126.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-05-30 01:22:55 +03:00
Anna Henningsen
82f18118ff
2018-05-23, Version 10.2.0 (Current)
* addons:
  - Fixed a memory leak for users of `AsyncResource` and N-API.
    (Michael Dawson)
    https://github.com/nodejs/node/pull/20668
* assert:
  - The `error` parameter of `assert.throws()` can be an object containing
    regular expressions now. (Ruben Bridgewater)
    https://github.com/nodejs/node/pull/20485
* crypto:
  - The `authTagLength` option has been made more flexible (Tobias Nießen)
    https://github.com/nodejs/node/pull/20235)
    https://github.com/nodejs/node/pull/20039
* esm:
  - Builtin modules (e.g. `fs`) now provide named exports in ES6 modules.
    (Gus Caplan)
    https://github.com/nodejs/node/pull/20403
* http:
  - Handling of `close` and `aborted` events has been made more consistent.
    (Robert Nagy)
    https://github.com/nodejs/node/pull/20075
    https://github.com/nodejs/node/pull/20611
* module:
  - add --preserve-symlinks-main (David Goldstein)
    https://github.com/nodejs/node/pull/19911
* timers:
  - `timeout.refresh()` has been added to the public API.
    (Jeremiah Senkpiel)
    https://github.com/nodejs/node/pull/20298
* Embedder support:
  - Functions for creating V8 `Isolate` and `Context` objects with
    Node.js-specific behaviour have been added to the API.
    (Allen Yonghuang Wang)
    https://github.com/nodejs/node/pull/20639
  - Node.js `Environment`s clean up resources before exiting now.
    (Anna Henningsen)
    https://github.com/nodejs/node/pull/19377
  - Support for multi-threaded embedding has been improved.
    (Anna Henningsen)
    https://github.com/nodejs/node/pull/20542
    https://github.com/nodejs/node/pull/20539
    https://github.com/nodejs/node/pull/20541

PR-URL: https://github.com/nodejs/node/pull/20724
2018-05-23 19:08:39 -04:00
Shobhit Chittora
5efbe4c1e8 doc: update one more command in crypto.md
PR-URL: https://github.com/nodejs/node/pull/20500
Refs: https://github.com/nodejs/node/pull/20400
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-05-07 04:09:28 +03:00
Shobhit Chittora
a1f342f054
doc: updates crypto doc with openssl list -cipher-algorithms
PR-URL: https://github.com/nodejs/node/pull/20502
Refs: https://github.com/nodejs/node/issues/20385
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Shigeki Ohtsu <ohtsu@ohtsu.org>
2018-05-06 21:09:33 +02:00
Shobhit Chittora
6a24c0c4d6 doc: update cli flag in crypto.md
PR-URL: https://github.com/nodejs/node/pull/20400
Fixes: https://github.com/nodejs/node/issues/20385
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Shigeki Ohtsu <ohtsu@ohtsu.org>
2018-05-03 17:46:31 +03:00
Vse Mozhet Byt
7588ceaf35 doc: add more missing backticks
Also, fix some other nits in passing
(formatting, punctuation, typos, redundancy, obsoleteness).

PR-URL: https://github.com/nodejs/node/pull/20438
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-05-03 02:12:07 +03:00
Vse Mozhet Byt
a3bd06a5e6 doc: remove redundant empty lines
PR-URL: https://github.com/nodejs/node/pull/20398
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-04-29 17:48:43 +03:00
Tobias Nießen
f9b9974f55
crypto: support authTagLength in GCM encryption
The authTagLength option can now be used to produce GCM authentication
tags with a specific length.

PR-URL: https://github.com/nodejs/node/pull/20235
Refs: https://github.com/nodejs/node/pull/20039
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Yihong Wang <yh.wang@ibm.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-04-26 20:56:24 +02:00
James M Snell
0cca27b3ff 2018-04-24, Version 10.0.0 (Current)
* Assert
  * Calling `assert.fail()` with more than one argument is deprecated. #70dcacd710
  * Calling `assert.ok()` with no arguments will now throw. #3cd7977a42
  * Calling `assert.ifError()` will now throw with any argument other than `undefined` or `null`. Previously the method would throw with any truthy value. #e65a6e81ef
  * The `assert.rejects()` and `assert.doesNotReject()` methods have been added for working with async functions. #599337f43e
* Async_hooks
  * Older experimental async_hooks APIs have been removed. #1cc6b993b9
* Buffer
  * Uses of `new Buffer()` and `Buffer()` outside of the `node_modules` directory will now emit a runtime deprecation warning. #9d4ab90117
  * `Buffer.isEncoding()` now returns `undefined` for falsy values, including an empty string. #452eed956e
  * `Buffer.fill()` will throw if an attempt is made to fill with an empty `Buffer`. #1e802539b2
* Child Process
  * Undefined properties of env are ignored. #38ee25e2e2, #85739b6c5b
* Console
  * The `console.table()` method has been added. #97ace04492
* Crypto
  * The `crypto.createCipher()` and `crypto.createDecipher()` methods have been deprecated. Please use `crypto.createCipheriv()` and `crypto.createDecipheriv()` instead. #81f88e30dd
  * The `decipher.finaltol()` method has been deprecated. #19f3927d92
  * The `crypto.DEFAULT_ENCODING` property has been deprecated. #6035beea93
  * The `ECDH.convertKey()` method has been added. #f2e02883e7
  * The `crypto.fips` property has been deprecated. #6e7992e8b8
* Dependencies
  * V8 has been updated to 6.6. #9daebb48d6
  * OpenSSL has been updated to 1.1.0h. #66cb29e646
* EventEmitter
  * The `EventEmitter.prototype.off()` method has been added as an alias for `EventEmitter.prototype.removeListener()`. #3bb6f07d52
* File System
  * The `fs.promises` API provides experimental promisified versions of the `fs` functions. #329fc78e49
  * Invalid path errors are now thrown synchronously. #d8f73385e2
  * The `fs.readFile()` method now partitions reads to avoid thread pool exhaustion. #67a4ce1c6e
* HTTP
  * Processing of HTTP Status codes `100`, `102-199` has been improved. #baf8495078
  * Multi-byte characters in URL paths are now forbidden. #b961d9fd83
* N-API
  * The n-api is no longer experimental. #cd7d7b15c1
* Net
  * The `'close'` event will be emitted after `'end'`. #9b7a6914a7
* Perf_hooks
  * The `PerformanceObserver` class is now an `AsyncResource` and can be monitored using `async_hooks`. #009e41826f
  * Trace events are now emitted for performance events. #9e509b622b
  * The `performance` API has been simplified. #2ec6995555
  * Performance milestone marks will be emitted as trace events. #96cb4fb795
* Process
  * Using non-string values for `process.env` is deprecated. #5826fe4e79
  * The `process.assert()` method is deprecated. #703e37cf3f
* REPL
  * REPL now experimentally supports top-level await when using the `--experimental-repl-await` flag. #eeab7bc068
  * The previously deprecated "magic mode" has been removed. #4893f70d12
  * The previously deprecated `NODE_REPL_HISTORY_FILE` environment variable has been removed. #60c9ad7979
  * Proxy objects are shown as Proxy objects when inspected. #90a43906ab
* Streams
  * The `'readable'` event is now always deferred with nextTick. #1e0f3315c7
  * A new `pipeline()` method has been provided for building end-to-data stream pipelines. #a5cf3feaf1
  * Experimental support for async for-await has been added to `stream.Readable`. #61b4d60c5d
* Timers
  * The `enroll()` and `unenroll()` methods have been deprecated. #68783ae0b8
* TLS
  * The `tls.convertNONProtocols()` method has been deprecated. #9204a0db6e
  * Support for NPN (next protocol negotiation) has been dropped. #5bfbe5ceae
  * The `ecdhCurve` default is now `'auto'`. #af78840b19
* Trace Events
  * A new `trace_events` top-level module allows trace event categories to be enabled/disabld at runtime. #da5d818a54
* URL
  * The WHATWG URL API is now a global. #312414662b
* Util
  * `util.types.is[…]` type checks have been added. #b20af8088a
  * Support for bigint formatting has been added to `util.inspect()`. #39dc947409
2018-04-24 12:02:31 -07:00
Tobias Nießen
358d8ffad6
crypto: allow to restrict valid GCM tag length
This change allows users to restrict accepted GCM authentication tag
lengths to a single value.

PR-URL: https://github.com/nodejs/node/pull/20039
Fixes: https://github.com/nodejs/node/issues/17523
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Yihong Wang <yh.wang@ibm.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2018-04-23 01:55:09 +02:00
Tobias Nießen
cf350856cf doc: note that setAuthTag throws on invalid length
PR-URL: https://github.com/nodejs/node/pull/17825
Refs: https://github.com/nodejs/node/issues/17523
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-04-14 10:50:52 -07:00
Tobias Nießen
04148b1121
doc: mention CCM along with GCM in crypto APIs
PR-URL: https://github.com/nodejs/node/pull/19945
Refs: https://github.com/nodejs/node/pull/18138
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-13 16:29:42 +02:00
Tobias Nießen
0aab8ff602 doc: remove superfluous word from crypto doc
PR-URL: https://github.com/nodejs/node/pull/19946
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.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: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-11 22:23:19 -07:00
Vse Mozhet Byt
df5d41bf93 doc: add and unify even more return values
PR-URL: https://github.com/nodejs/node/pull/19955
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-04-12 03:18:01 +03:00
Shigeki Ohtsu
ae096ba27c doc: fix API descriptions for OpenSSL-1.1.0
Fixes: https://github.com/nodejs/node/issues/4270
PR-URL: https://github.com/nodejs/node/pull/19794
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2018-04-10 06:45:45 +09:00
Tobias Nießen
99c77dc018
doc: improve CCM example
The nonce must be transmitted along with ciphertext and tag.

PR-URL: https://github.com/nodejs/node/pull/19851
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2018-04-09 16:32:12 +02:00
Vse Mozhet Byt
321c178faa doc: add missing quotes in default string values
PR-URL: https://github.com/nodejs/node/pull/19894
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2018-04-09 17:01:29 +03:00
Vse Mozhet Byt
0bd3da15a0 doc: add and unify return statements in crypto.md
Conform return statements to the style guide and tool parsers.

Also bring back a description fragment
that seems to be erroneously deleted in
1e07acd476

PR-URL: https://github.com/nodejs/node/pull/19853
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-04-09 01:20:33 +03:00
Ujjwal Sharma
0a679327be
doc: update language regarding key stretching
Update the docs to provide clearer instructions regarding the exact
scope of the use (and re-use) of an IV, stating the instructions
explicitly with greater clarity.

PR-URL: https://github.com/nodejs/node/pull/19810
Fixes: https://github.com/nodejs/node/issues/19748
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-04-08 13:32:09 +02:00
Tobias Nießen
1e07acd476
crypto: add support for AES-CCM
This commit adds support for another AEAD algorithm and introduces
required API changes and extensions. Due to the design of CCM itself and
the way OpenSSL implements it, there are some restrictions when using
this mode as outlined in the updated documentation.

PR-URL: https://github.com/nodejs/node/pull/18138
Fixes: https://github.com/nodejs/node/issues/2383
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Shigeki Ohtsu <ohtsu@ohtsu.org>
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
2018-04-06 13:02:43 +02:00
Vse Mozhet Byt
de0053cc32 doc: fix various nits
* Replace 2 hyphens (--) by spaced m-dashes (—) as per STYLE_GUIDE.md.
* Space infix operators.
* Unify quotes in inline code spans (use only single quotes).
* Unify `* Returns:` (eliminate deviations).
* Dedupe spaces.

PR-URL: https://github.com/nodejs/node/pull/19743
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-04 13:45:39 +03:00
Vse Mozhet Byt
237cbe10fb doc,tools: formalize, unify, codify default values
PR-URL: https://github.com/nodejs/node/pull/19737
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-04-04 12:30:36 +03:00
Ben Noordhuis
5bfbe5ceae tls: drop NPN (next protocol negotiation) support
NPN has been superseded by ALPN.  Chrome and Firefox removed support for
NPN in 2016 and 2017 respectively to no ill effect.

Fixes: https://github.com/nodejs/node/issues/14602
PR-URL: https://github.com/nodejs/node/pull/19403
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-03-27 16:22:37 +02:00
Wei-Wei Wu
f2e02883e7
crypto: add ECDH.convertKey to convert public keys
ECDH.convertKey is used to convert public keys between different
formats.

PR-URL: https://github.com/nodejs/node/pull/19080
Fixes: https://github.com/nodejs/node/issues/18977
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-03-23 19:56:59 +01:00
Myles Borins
0fc3592255
2018-03-21, Version 9.9.0 (Current)
Notable changes:

* assert:
  - From now on all error messages produced by `assert` in strict mode
    will produce a error diff. (Ruben Bridgewater)
    https://github.com/nodejs/node/pull/17615
  - From now on it is possible to use a validation object in throws
    instead of the other possibilities. (Ruben Bridgewater)
    https://github.com/nodejs/node/pull/17584
* crypto:
  - allow passing null as IV unless required (Tobias Nießen)
    https://github.com/nodejs/node/pull/18644
* fs:
  - support as and as+ flags in stringToFlags() (Sarat Addepalli)
    https://github.com/nodejs/node/pull/18801
* tls:
  - expose Finished messages in TLSSocket (Anton Salikhmetov)
    https://github.com/nodejs/node/pull/19102
* tty:
  - Add getColorDepth function to determine if terminal supports colors
    (Ruben Bridgewater) https://github.com/nodejs/node/pull/17615
* util:
  - add util.inspect compact option (Ruben Bridgewater)
    https://github.com/nodejs/node/pull/17576
* **Added new collaborators**
  - [watson](https://github.com/watson) Thomas Watson

PR-URL: https://github.com/nodejs/node/pull/19428
2018-03-21 15:47:12 +00:00
Tobias Nießen
81f88e30dd
crypto: doc-only deprecate createCipher/Decipher
createCipher and createDecipher are cryptographically weak, can cause
severe security issues when used improperly and are unsupported in FIPS
mode.

PR-URL: https://github.com/nodejs/node/pull/19343
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
2018-03-21 12:28:47 +01:00
estrada9166
a29089d7c8
doc: add new documentation lint rule
Add 80 characters limit to docs.
Change docs to fit 80 characters per row.

PR-URL: https://github.com/nodejs/node/pull/18726
Fixes: https://github.com/nodejs/node/issues/18703
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
2018-02-23 16:26:29 +00:00
Antoine AMARA
138bdf6114 doc: update crypo Certficate class.
Update the dead link to <keygen> documentation.
Add a link to mozilla developper documentation because
W3C deleted the reference to this element.

Add a note to inform <keygen> element is deprecated since HTML 5.2.

PR-URL: https://github.com/nodejs/node/pull/18721
Fixes: https://github.com/nodejs/node/issues/18662
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
2018-02-14 23:05:56 +02:00
Tobias Nießen
38bac4266a
crypto: allow passing null as IV unless required
PR-URL: https://github.com/nodejs/node/pull/18644
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-02-10 15:58:46 +01:00
Tobias Nießen
95a35bcf06
doc: add missing meta for createCipheriv
PR-URL: https://github.com/nodejs/node/pull/18651
Refs: https://github.com/nodejs/node/pull/8281
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
2018-02-09 01:26:39 +01:00
Tobias Nießen
4927d94f4d
doc: fix description of createDecipheriv
PR-URL: https://github.com/nodejs/node/pull/18651
Refs: https://github.com/nodejs/node/pull/12223
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
2018-02-09 01:26:35 +01:00
James M Snell
d3569b623c
doc: remove **Note:** tags
Remove the various **Note:** prefixes throughout the docs.

PR-URL: https://github.com/nodejs/node/pull/18592
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
2018-02-08 11:57:14 -05:00
James M Snell
6e7992e8b8 crypto: docs-only deprecate crypto.fips, replace
Docs-only deprecate the getter/setter crypto.fips and replace
with crypto.setFips() and crypto.getFips()

This is specifically in preparation for ESM module support

PR-URL: https://github.com/nodejs/node/pull/18335
Refs: https://github.com/nodejs/node/pull/18131
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-02-02 07:50:31 -08:00
James M Snell
6035beea93 crypto: runtime deprecate DEFAULT_ENCODING
Runtime deprecate the crypto.DEFAULT_ENCODING property.

This is specifically in preparation for eventual ESM support
Refs: https://github.com/nodejs/node/pull/18131

PR-URL: https://github.com/nodejs/node/pull/18333
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Minwoo Jung <minwoo@nodesource.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2018-01-31 17:33:41 -08:00
Tobias Nießen
a1781230cd
doc: warn about GCM authenticity
PR-URL: https://github.com/nodejs/node/pull/18376
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2018-01-30 16:37:53 +01:00
Tobias Nießen
a65b0b90c9
doc: use PBKDF2 in text
Use upper case variant in text in compliance with RFC 2898.

PR-URL: https://github.com/nodejs/node/pull/18279
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Vladimir Kurchatkin <vladimir.kurchatkin@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2018-01-22 12:53:50 +01:00
Tobias Nießen
fd724c5c63
doc: fix typo
PR-URL: https://github.com/nodejs/node/pull/17900
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-12-28 16:42:46 +01:00
Will Clark
560c18238b
doc: correct pbkdf2 salt length recommendation
According to the linked document: "The length of the randomly-generated
portion of the salt shall be at least 128 bits." [NIST SP 800-132]

PR-URL: https://github.com/nodejs/node/pull/17524
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-12-12 23:46:39 +01:00
Tobias Nießen
2c77cab440
doc: note that randomBytes throws when passed null
Fixes: https://github.com/nodejs/node/issues/16778

PR-URL: https://github.com/nodejs/node/pull/17594
Fixes: https://github.com/nodejs/node/issues/16778
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
2017-12-12 17:02:08 -02:00
Tobias Nießen
def6072f3a
doc: replace ArrayBufferView in crypto
PR-URL: https://github.com/nodejs/node/pull/17595
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2017-12-12 19:35:23 +01:00
Rich Trott
ff9a6bc1f3 doc: add missing serial commas
PR-URL: https://github.com/nodejs/node/pull/17384
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Alexey Orlenko <eaglexrlnk@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2017-12-01 14:46:36 -08:00
Jose M. Palacios Diaz
845633a7c6
crypto: better docs for cases where peer's public key is invalid
changes in c++ are in the computeSecret function, but the thrown
exception that was moved to JS land was in BufferToPoint
function, here i let the allocation error be thrown so the only value
returned is the nullptr that i use later to catch the error in
computeSecret, to then construct the exception in JS land.

an ERR_CRYPTO_ECDH_INVALID_PUBLIC_KEY error was added to errors.js
and with that, subsequent changes to docs and tests were made.

PR-URL: https://github.com/nodejs/node/pull/16849
Refs: https://www.iacr.org/archive/pkc2003/25670211/25670211.pdf
Fixes: https://github.com/nodejs/node/issues/16625
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-12-01 21:18:11 +01:00
Jamie Davis
16e87eddd6
doc: non-partitioned async crypto operations
Neither crypto.randomBytes nor crypto.randomFill
partitions the work submitted to the threadpool.

This change was suggested during the discussion of #17054.
See also #17154.

PR-URL: https://github.com/nodejs/node/pull/17250
Refs: https://github.com/nodejs/node/pull/17154
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2017-11-28 02:48:19 +01:00
Ronald Eddy Jr
7ab784000a
doc: update http URLs to https in doc/api
PR-URL: https://github.com/nodejs/node/pull/17263
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
2017-11-23 16:06:35 -05:00
Mithun Sasidharan
841e305e4c doc : mention constant-time in crypto doc
Included reference to 'constant time' in
crypto.timingSafeEqual description.

The Node website would score higher on a Google search
and the API would be more discoverable if it used the words
"constant time" in its description.

PR-URL: https://github.com/nodejs/node/pull/16604
Fixes: https://github.com/nodejs/node/issues/16504
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-11-02 18:38:17 +08:00
James M Snell
8cd940af13 2017-10-31, Version 9.0.0 (Current)
* Older experimental APIs have been removed.
    [[`d731369b1d`](https://github.com/nodejs/node/commit/d731369b1d)]
    [#14414](https://github.com/nodejs/node/pull/14414)

* **Errors**
  * Improvements have been made to `buffer` module error messages.
  * The assignment of static error codes to Node.js error continues:
    * `buffer`
    * `child_process`
    * `console`
    * `crypto`
    * `dns`
    * `events`
    * `fs`
    * `http`
    * `inspector`
    * `net`
    * `path`
    * `process`
    * `querystring`
    * `readline`
    * `repl`
    * `streams`
    * `string_decoder`
    * `timers`
    * `tls`
    * `url`
    * `util`
    * `v8`
    * `zlib`

* **Child Processes**
  * Errors are emitted on process nextTick.

* **Domains**
  * The long-deprecated `.dispose()` method has been removed.

* **fs**
  * The `fs.ReadStream` and `fs.WriteStream` classes now use `destroy()`.
  * `fs` module callbacks are now invoked with an undefined context.

* **HTTP/1**
  * A 400 Bad Request response will now be sent when parsing fails.
  * Socket timeout will be set when the socket connects.
  * A bug causing the request `'error'` event to fire twice was fixed.
  * HTTP clients may now use generic `Duplex` streams in addition to `net.Socket`.

* **Intl**
  * The deprecated `Intl.v8BreakIterator` has been removed.

* **Modules**
  * The `require.resolve()` method now supports using custom lookup paths.

* **OS**
  * The `os.EOL` property is now read-only.

* **Timers**
  * `setTimeout()` will emit a warning if the timeout is larger that the maximum
    32-bit unsigned integer.
2017-10-31 12:59:12 -07:00
James M Snell
7124b466d9 crypto: refactor argument validation for pbkdf2
Move input argument validation to js, using internal/errors.

Also update docs

* `password` and `salt` may be Buffers or any TypedArrays
* `crypto.DEFAULT_ENCODING` changes the returned derivedKey type

PR-URL: https://github.com/nodejs/node/pull/15746
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2017-10-23 15:52:11 -07:00
Ben Noordhuis
3469eb9553 doc: public keys don't accept passphrases
Since `crypto.publicDecrypt()` and `crypto.publicEncrypt()` accept both
public and private keys, make it clear that the `passphrase` option only
applies to private keys.

PR-URL: https://github.com/nodejs/node/pull/16087
Ref: https://github.com/nodejs/node/pull/16038
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Nikolai Vavilov <vvnicholas@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
2017-10-18 08:39:15 -07:00
Jeremy Huang
a3a106865a
doc: add return values in crypto documentation
Clarify return values for crypto.publicEncrypt and similar functions

PR-URL: https://github.com/nodejs/node/pull/16229
Fixes: https://github.com/nodejs/node/issues/12946
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
2017-10-16 16:31:18 -04:00
Lukas
b5c74d85fc doc: reduce keylen in pbkdf2 examples
PR-URL: https://github.com/nodejs/node/pull/16203
Refs: https://github.com/nodejs/node/issues/3415
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
2017-10-16 15:42:59 +02:00