Browse Source

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>
v9.x-staging
Pavel Pomerantsev 7 years ago
committed by Anna Henningsen
parent
commit
1b358f1fde
No known key found for this signature in database GPG Key ID: 9C63F3A6CD2AD8F9
  1. 8
      doc/api/crypto.md

8
doc/api/crypto.md

@ -1714,8 +1714,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`.
@ -1734,8 +1734,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`.

Loading…
Cancel
Save