diff options
author | Ruslan Iusupov <rus0000@users.noreply.github.com> | 2017-07-25 10:16:01 +0300 |
---|---|---|
committer | Anna Henningsen <anna@addaleax.net> | 2017-07-28 00:48:57 +0300 |
commit | e9088f92d82776386c4880f6898ac4d83ebf3b29 (patch) | |
tree | 9087e84bbae1015a49cd9c53464f79c155c31b77 /doc/api/crypto.md | |
parent | 91b6ba1973fbf136843a0ed02964879af095ce74 (diff) |
doc: fix verify in crypto.md
PR-URL: https://github.com/nodejs/node/pull/14469
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Diffstat (limited to 'doc/api/crypto.md')
-rw-r--r-- | doc/api/crypto.md | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/doc/api/crypto.md b/doc/api/crypto.md index 659dc4e1bbb..07245e8cdc1 100644 --- a/doc/api/crypto.md +++ b/doc/api/crypto.md @@ -1074,7 +1074,7 @@ console.log(verify.verify(publicKey, signature)); // Prints: true or false ``` -### verifier.update(data[, inputEncoding]) +### verify.update(data[, inputEncoding]) <!-- YAML added: v0.1.92 changes: @@ -1093,7 +1093,7 @@ encoding of `'utf8'` is enforced. If `data` is a [`Buffer`][], `TypedArray`, or This can be called many times with new data as it is streamed. -### verifier.verify(object, signature[, signatureFormat]) +### verify.verify(object, signature[, signatureFormat]) <!-- YAML added: v0.1.92 changes: @@ -1110,7 +1110,7 @@ The `object` argument can be either a string containing a PEM encoded object, which can be an RSA public key, a DSA public key, or an X.509 certificate, or an object with one or more of the following properties: -* `key`: {string} - PEM encoded private key (required) +* `key`: {string} - PEM encoded public key (required) * `padding`: {integer} - Optional padding value for RSA, one of the following: * `crypto.constants.RSA_PKCS1_PADDING` (default) * `crypto.constants.RSA_PKCS1_PSS_PADDING` @@ -1132,7 +1132,7 @@ string; otherwise `signature` is expected to be a [`Buffer`][], Returns `true` or `false` depending on the validity of the signature for the data and public key. -The `verifier` object can not be used again after `verify.verify()` has been +The `verify` object can not be used again after `verify.verify()` has been called. Multiple calls to `verify.verify()` will result in an error being thrown. |