Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPavel Pomerantsev <pomerantsevp@gmail.com>2017-10-06 22:09:52 +0300
committerMyles Borins <mylesborins@google.com>2017-10-11 09:05:45 +0300
commit74755415cc4f67054d30b92dfa4d8232b57a0f76 (patch)
tree5494f5771a5361287565d00bd583b501c8d04724 /doc/api/crypto.md
parent0ae84c2434dfbd87a0284ddd4659fbc30b12311f (diff)
doc: fix: correctly use `public key` instead of `private key`
Although, as docs mention, private keys can be used instead of public keys, I presume that these parameter explanations should be corrected. Fixes: https://github.com/nodejs/node/issues/13633 PR-URL: https://github.com/nodejs/node/pull/16038 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'doc/api/crypto.md')
-rw-r--r--doc/api/crypto.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/doc/api/crypto.md b/doc/api/crypto.md
index 4e5e54a29d4..5596e16e6b4 100644
--- a/doc/api/crypto.md
+++ b/doc/api/crypto.md
@@ -1661,8 +1661,8 @@ treated as the key with no passphrase and will use `RSA_PKCS1_PADDING`.
added: v1.1.0
-->
- `publicKey` {Object | string}
- - `key` {string} A PEM encoded private key.
- - `passphrase` {string} An optional passphrase for the private key.
+ - `key` {string} A PEM encoded public key.
+ - `passphrase` {string} An optional passphrase for the public key.
- `padding` {crypto.constants} An optional padding value defined in
`crypto.constants`, which may be: `crypto.constants.RSA_NO_PADDING` or
`RSA_PKCS1_PADDING`.
@@ -1681,8 +1681,8 @@ be passed instead of a public key.
added: v0.11.14
-->
- `publicKey` {Object | string}
- - `key` {string} A PEM encoded private key.
- - `passphrase` {string} An optional passphrase for the private key.
+ - `key` {string} A PEM encoded public key.
+ - `passphrase` {string} An optional passphrase for the public key.
- `padding` {crypto.constants} An optional padding value defined in
`crypto.constants`, which may be: `crypto.constants.RSA_NO_PADDING`,
`RSA_PKCS1_PADDING`, or `crypto.constants.RSA_PKCS1_OAEP_PADDING`.