Skip to content

Commit 9892b15

Browse files
avivkelleraduh95
authored andcommitted
doc: format safely for doc-kit
PR-URL: #59229 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
1 parent b7577d8 commit 9892b15

File tree

13 files changed

+190
-207
lines changed

13 files changed

+190
-207
lines changed

doc/api/crypto.md

Lines changed: 51 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -3586,18 +3586,18 @@ changes:
35863586
`ERR_INVALID_CALLBACK`.
35873587
-->
35883588

3589-
* `type`: {string} The intended use of the generated secret key. Currently
3589+
* `type` {string} The intended use of the generated secret key. Currently
35903590
accepted values are `'hmac'` and `'aes'`.
3591-
* `options`: {Object}
3592-
* `length`: {number} The bit length of the key to generate. This must be a
3591+
* `options` {Object}
3592+
* `length` {number} The bit length of the key to generate. This must be a
35933593
value greater than 0.
35943594
* If `type` is `'hmac'`, the minimum is 8, and the maximum length is
35953595
2<sup>31</sup>-1. If the value is not a multiple of 8, the generated
35963596
key will be truncated to `Math.floor(length / 8)`.
35973597
* If `type` is `'aes'`, the length must be one of `128`, `192`, or `256`.
3598-
* `callback`: {Function}
3599-
* `err`: {Error}
3600-
* `key`: {KeyObject}
3598+
* `callback` {Function}
3599+
* `err` {Error}
3600+
* `key` {KeyObject}
36013601

36023602
Asynchronously generates a new random secret key of the given `length`. The
36033603
`type` will determine which validations will be performed on the `length`.
@@ -3661,30 +3661,30 @@ changes:
36613661
produce key objects if no encoding was specified.
36623662
-->
36633663

3664-
* `type`: {string} Must be `'rsa'`, `'rsa-pss'`, `'dsa'`, `'ec'`, `'ed25519'`,
3664+
* `type` {string} Must be `'rsa'`, `'rsa-pss'`, `'dsa'`, `'ec'`, `'ed25519'`,
36653665
`'ed448'`, `'x25519'`, `'x448'`, or `'dh'`.
3666-
* `options`: {Object}
3667-
* `modulusLength`: {number} Key size in bits (RSA, DSA).
3668-
* `publicExponent`: {number} Public exponent (RSA). **Default:** `0x10001`.
3669-
* `hashAlgorithm`: {string} Name of the message digest (RSA-PSS).
3670-
* `mgf1HashAlgorithm`: {string} Name of the message digest used by
3666+
* `options` {Object}
3667+
* `modulusLength` {number} Key size in bits (RSA, DSA).
3668+
* `publicExponent` {number} Public exponent (RSA). **Default:** `0x10001`.
3669+
* `hashAlgorithm` {string} Name of the message digest (RSA-PSS).
3670+
* `mgf1HashAlgorithm` {string} Name of the message digest used by
36713671
MGF1 (RSA-PSS).
3672-
* `saltLength`: {number} Minimal salt length in bytes (RSA-PSS).
3673-
* `divisorLength`: {number} Size of `q` in bits (DSA).
3674-
* `namedCurve`: {string} Name of the curve to use (EC).
3675-
* `prime`: {Buffer} The prime parameter (DH).
3676-
* `primeLength`: {number} Prime length in bits (DH).
3677-
* `generator`: {number} Custom generator (DH). **Default:** `2`.
3678-
* `groupName`: {string} Diffie-Hellman group name (DH). See
3672+
* `saltLength` {number} Minimal salt length in bytes (RSA-PSS).
3673+
* `divisorLength` {number} Size of `q` in bits (DSA).
3674+
* `namedCurve` {string} Name of the curve to use (EC).
3675+
* `prime` {Buffer} The prime parameter (DH).
3676+
* `primeLength` {number} Prime length in bits (DH).
3677+
* `generator` {number} Custom generator (DH). **Default:** `2`.
3678+
* `groupName` {string} Diffie-Hellman group name (DH). See
36793679
[`crypto.getDiffieHellman()`][].
3680-
* `paramEncoding`: {string} Must be `'named'` or `'explicit'` (EC).
3680+
* `paramEncoding` {string} Must be `'named'` or `'explicit'` (EC).
36813681
**Default:** `'named'`.
3682-
* `publicKeyEncoding`: {Object} See [`keyObject.export()`][].
3683-
* `privateKeyEncoding`: {Object} See [`keyObject.export()`][].
3684-
* `callback`: {Function}
3685-
* `err`: {Error}
3686-
* `publicKey`: {string | Buffer | KeyObject}
3687-
* `privateKey`: {string | Buffer | KeyObject}
3682+
* `publicKeyEncoding` {Object} See [`keyObject.export()`][].
3683+
* `privateKeyEncoding` {Object} See [`keyObject.export()`][].
3684+
* `callback` {Function}
3685+
* `err` {Error}
3686+
* `publicKey` {string | Buffer | KeyObject}
3687+
* `privateKey` {string | Buffer | KeyObject}
36883688

36893689
Generates a new asymmetric key pair of the given `type`. RSA, RSA-PSS, DSA, EC,
36903690
Ed25519, Ed448, X25519, X448, and DH are currently supported.
@@ -3775,29 +3775,29 @@ changes:
37753775
produce key objects if no encoding was specified.
37763776
-->
37773777

3778-
* `type`: {string} Must be `'rsa'`, `'rsa-pss'`, `'dsa'`, `'ec'`, `'ed25519'`,
3778+
* `type` {string} Must be `'rsa'`, `'rsa-pss'`, `'dsa'`, `'ec'`, `'ed25519'`,
37793779
`'ed448'`, `'x25519'`, `'x448'`, or `'dh'`.
3780-
* `options`: {Object}
3781-
* `modulusLength`: {number} Key size in bits (RSA, DSA).
3782-
* `publicExponent`: {number} Public exponent (RSA). **Default:** `0x10001`.
3783-
* `hashAlgorithm`: {string} Name of the message digest (RSA-PSS).
3784-
* `mgf1HashAlgorithm`: {string} Name of the message digest used by
3780+
* `options` {Object}
3781+
* `modulusLength` {number} Key size in bits (RSA, DSA).
3782+
* `publicExponent` {number} Public exponent (RSA). **Default:** `0x10001`.
3783+
* `hashAlgorithm` {string} Name of the message digest (RSA-PSS).
3784+
* `mgf1HashAlgorithm` {string} Name of the message digest used by
37853785
MGF1 (RSA-PSS).
3786-
* `saltLength`: {number} Minimal salt length in bytes (RSA-PSS).
3787-
* `divisorLength`: {number} Size of `q` in bits (DSA).
3788-
* `namedCurve`: {string} Name of the curve to use (EC).
3789-
* `prime`: {Buffer} The prime parameter (DH).
3790-
* `primeLength`: {number} Prime length in bits (DH).
3791-
* `generator`: {number} Custom generator (DH). **Default:** `2`.
3792-
* `groupName`: {string} Diffie-Hellman group name (DH). See
3786+
* `saltLength` {number} Minimal salt length in bytes (RSA-PSS).
3787+
* `divisorLength` {number} Size of `q` in bits (DSA).
3788+
* `namedCurve` {string} Name of the curve to use (EC).
3789+
* `prime` {Buffer} The prime parameter (DH).
3790+
* `primeLength` {number} Prime length in bits (DH).
3791+
* `generator` {number} Custom generator (DH). **Default:** `2`.
3792+
* `groupName` {string} Diffie-Hellman group name (DH). See
37933793
[`crypto.getDiffieHellman()`][].
3794-
* `paramEncoding`: {string} Must be `'named'` or `'explicit'` (EC).
3794+
* `paramEncoding` {string} Must be `'named'` or `'explicit'` (EC).
37953795
**Default:** `'named'`.
3796-
* `publicKeyEncoding`: {Object} See [`keyObject.export()`][].
3797-
* `privateKeyEncoding`: {Object} See [`keyObject.export()`][].
3796+
* `publicKeyEncoding` {Object} See [`keyObject.export()`][].
3797+
* `privateKeyEncoding` {Object} See [`keyObject.export()`][].
37983798
* Returns: {Object}
3799-
* `publicKey`: {string | Buffer | KeyObject}
3800-
* `privateKey`: {string | Buffer | KeyObject}
3799+
* `publicKey` {string | Buffer | KeyObject}
3800+
* `privateKey` {string | Buffer | KeyObject}
38013801

38023802
Generates a new asymmetric key pair of the given `type`. RSA, RSA-PSS, DSA, EC,
38033803
Ed25519, Ed448, X25519, X448, and DH are currently supported.
@@ -3866,10 +3866,10 @@ it will be a buffer containing the data encoded as DER.
38663866
added: v15.0.0
38673867
-->
38683868

3869-
* `type`: {string} The intended use of the generated secret key. Currently
3869+
* `type` {string} The intended use of the generated secret key. Currently
38703870
accepted values are `'hmac'` and `'aes'`.
3871-
* `options`: {Object}
3872-
* `length`: {number} The bit length of the key to generate.
3871+
* `options` {Object}
3872+
* `length` {number} The bit length of the key to generate.
38733873
* If `type` is `'hmac'`, the minimum is 8, and the maximum length is
38743874
2<sup>31</sup>-1. If the value is not a multiple of 8, the generated
38753875
key will be truncated to `Math.floor(length / 8)`.
@@ -4010,10 +4010,10 @@ the process unresponsive.
40104010
added: v15.0.0
40114011
-->
40124012

4013-
* `nameOrNid`: {string|number} The name or nid of the cipher to query.
4014-
* `options`: {Object}
4015-
* `keyLength`: {number} A test key length.
4016-
* `ivLength`: {number} A test IV length.
4013+
* `nameOrNid` {string|number} The name or nid of the cipher to query.
4014+
* `options` {Object}
4015+
* `keyLength` {number} A test key length.
4016+
* `ivLength` {number} A test IV length.
40174017
* Returns: {Object}
40184018
* `name` {string} The name of the cipher
40194019
* `nid` {number} The nid of the cipher

0 commit comments

Comments
 (0)