Skip to content

Commit acd7e18

Browse files
tniessenaduh95
authored andcommitted
doc: fix Argon2 parameter bounds
The bounds are supposed to be inclusive, not exclusive. PR-URL: #62868 Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: Richard Lau <richard.lau@ibm.com>
1 parent a6e9987 commit acd7e18

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
@@ -3315,14 +3315,14 @@ added: v24.7.0
33153315
* `nonce` {string|ArrayBuffer|Buffer|TypedArray|DataView} REQUIRED, must be at
33163316
least 8 bytes long. This is the salt for password hashing applications of Argon2.
33173317
* `parallelism` {number} REQUIRED, degree of parallelism determines how many computational chains (lanes)
3318-
can be run. Must be greater than 1 and less than `2**24-1`.
3319-
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be greater than 4 and
3320-
less than `2**32-1`.
3321-
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be greater than
3322-
`8 * parallelism` and less than `2**32-1`. The actual number of blocks is rounded
3318+
can be run. Must be at least `1` and at most `2**24-1`.
3319+
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be at least `4` and
3320+
at most `2**32-1`.
3321+
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be at least
3322+
`8 * parallelism` and at most `2**32-1`. The actual number of blocks is rounded
33233323
down to the nearest multiple of `4 * parallelism`.
3324-
* `passes` {number} REQUIRED, number of passes (iterations). Must be greater than 1 and less
3325-
than `2**32-1`.
3324+
* `passes` {number} REQUIRED, number of passes (iterations). Must be at least `1` and at most
3325+
`2**32-1`.
33263326
* `secret` {string|ArrayBuffer|Buffer|TypedArray|DataView|undefined} OPTIONAL, Random additional input,
33273327
similar to the salt, that should **NOT** be stored with the derived key. This is known as pepper in
33283328
password hashing applications. If used, must have a length not greater than `2**32-1` bytes.
@@ -3401,14 +3401,14 @@ added: v24.7.0
34013401
* `nonce` {string|ArrayBuffer|Buffer|TypedArray|DataView} REQUIRED, must be at
34023402
least 8 bytes long. This is the salt for password hashing applications of Argon2.
34033403
* `parallelism` {number} REQUIRED, degree of parallelism determines how many computational chains (lanes)
3404-
can be run. Must be greater than 1 and less than `2**24-1`.
3405-
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be greater than 4 and
3406-
less than `2**32-1`.
3407-
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be greater than
3408-
`8 * parallelism` and less than `2**32-1`. The actual number of blocks is rounded
3404+
can be run. Must be at least 1 and at most `2**24-1`.
3405+
* `tagLength` {number} REQUIRED, the length of the key to generate. Must be at least `4` and
3406+
at most `2**32-1`.
3407+
* `memory` {number} REQUIRED, memory cost in 1KiB blocks. Must be at least
3408+
`8 * parallelism` and at most `2**32-1`. The actual number of blocks is rounded
34093409
down to the nearest multiple of `4 * parallelism`.
3410-
* `passes` {number} REQUIRED, number of passes (iterations). Must be greater than 1 and less
3411-
than `2**32-1`.
3410+
* `passes` {number} REQUIRED, number of passes (iterations). Must be at least `1` and at most
3411+
`2**32-1`.
34123412
* `secret` {string|ArrayBuffer|Buffer|TypedArray|DataView|undefined} OPTIONAL, Random additional input,
34133413
similar to the salt, that should **NOT** be stored with the derived key. This is known as pepper in
34143414
password hashing applications. If used, must have a length not greater than `2**32-1` bytes.

0 commit comments

Comments
 (0)