Skip to content

Commit 5f92b6d

Browse files
authored
doc: fix Argon2 parameter bounds
The bounds are supposed to be inclusive, not exclusive. PR-URL: #62868 Reviewed-By: Filip Skokan <[email protected]> Reviewed-By: Richard Lau <[email protected]>
1 parent 262dee5 commit 5f92b6d

1 file changed

Lines changed: 14 additions & 14 deletions

File tree

doc/api/crypto.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3319,14 +3319,14 @@ added: v24.7.0
33193319
* `nonce` {string|ArrayBuffer|Buffer|TypedArray|DataView} REQUIRED, must be at
33203320
least 8 bytes long. This is the salt for password hashing applications of Argon2.
33213321
* `parallelism` {number} REQUIRED, degree of parallelism determines how many computational chains (lanes)
3322-
can be run. Must be greater than 1 and less than `2**24-1`.
3323-
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be greater than 4 and
3324-
less than `2**32-1`.
3325-
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be greater than
3326-
`8 * parallelism` and less than `2**32-1`. The actual number of blocks is rounded
3322+
can be run. Must be at least `1` and at most `2**24-1`.
3323+
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be at least `4` and
3324+
at most `2**32-1`.
3325+
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be at least
3326+
`8 * parallelism` and at most `2**32-1`. The actual number of blocks is rounded
33273327
down to the nearest multiple of `4 * parallelism`.
3328-
* `passes` {number} REQUIRED, number of passes (iterations). Must be greater than 1 and less
3329-
than `2**32-1`.
3328+
* `passes` {number} REQUIRED, number of passes (iterations). Must be at least `1` and at most
3329+
`2**32-1`.
33303330
* `secret` {string|ArrayBuffer|Buffer|TypedArray|DataView|undefined} OPTIONAL, Random additional input,
33313331
similar to the salt, that should **NOT** be stored with the derived key. This is known as pepper in
33323332
password hashing applications. If used, must have a length not greater than `2**32-1` bytes.
@@ -3405,14 +3405,14 @@ added: v24.7.0
34053405
* `nonce` {string|ArrayBuffer|Buffer|TypedArray|DataView} REQUIRED, must be at
34063406
least 8 bytes long. This is the salt for password hashing applications of Argon2.
34073407
* `parallelism` {number} REQUIRED, degree of parallelism determines how many computational chains (lanes)
3408-
can be run. Must be greater than 1 and less than `2**24-1`.
3409-
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be greater than 4 and
3410-
less than `2**32-1`.
3411-
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be greater than
3412-
`8 * parallelism` and less than `2**32-1`. The actual number of blocks is rounded
3408+
can be run. Must be at least 1 and at most `2**24-1`.
3409+
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be at least `4` and
3410+
at most `2**32-1`.
3411+
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be at least
3412+
`8 * parallelism` and at most `2**32-1`. The actual number of blocks is rounded
34133413
down to the nearest multiple of `4 * parallelism`.
3414-
* `passes` {number} REQUIRED, number of passes (iterations). Must be greater than 1 and less
3415-
than `2**32-1`.
3414+
* `passes` {number} REQUIRED, number of passes (iterations). Must be at least `1` and at most
3415+
`2**32-1`.
34163416
* `secret` {string|ArrayBuffer|Buffer|TypedArray|DataView|undefined} OPTIONAL, Random additional input,
34173417
similar to the salt, that should **NOT** be stored with the derived key. This is known as pepper in
34183418
password hashing applications. If used, must have a length not greater than `2**32-1` bytes.

0 commit comments

Comments
 (0)