Skip to content

Fix default argon2 params docs #982

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/argon2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,15 @@ export interface Options {
*
* Value is an integer in decimal (1 to 10 digits), between 1 and (2^32)-1.
*
* The default value is 4096, meaning a pool of 4 MiB per thread.
* The default value is 19456, meaning a pool of 19 MiB per thread.
*/
memoryCost?: number | undefined | null
/**
* The time cost is the amount of passes (iterations) used by the hash function. It increases hash strength at the cost of time required to compute.
*
* Value is an integer in decimal (1 to 10 digits), between 1 and (2^32)-1.
*
* The default value is 3.
* The default value is 2.
*/
timeCost?: number | undefined | null
/**
Expand Down
4 changes: 2 additions & 2 deletions packages/argon2/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@ export interface Options {
*
* Value is an integer in decimal (1 to 10 digits), between 1 and (2^32)-1.
*
* The default value is 4096, meaning a pool of 4 MiB per thread.
* The default value is 19456, meaning a pool of 19 MiB per thread.
*/
memoryCost?: number
/**
* The time cost is the amount of passes (iterations) used by the hash function. It increases hash strength at the cost of time required to compute.
*
* Value is an integer in decimal (1 to 10 digits), between 1 and (2^32)-1.
*
* The default value is 3.
* The default value is 2.
*/
timeCost?: number
/**
Expand Down
4 changes: 2 additions & 2 deletions packages/argon2/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,14 @@ pub struct Options {
///
/// Value is an integer in decimal (1 to 10 digits), between 1 and (2^32)-1.
///
/// The default value is 4096, meaning a pool of 4 MiB per thread.
/// The default value is 19456, meaning a pool of 19 MiB per thread.
pub memory_cost: Option<u32>,

/// The time cost is the amount of passes (iterations) used by the hash function. It increases hash strength at the cost of time required to compute.
///
/// Value is an integer in decimal (1 to 10 digits), between 1 and (2^32)-1.
///
/// The default value is 3.
/// The default value is 2.
pub time_cost: Option<u32>,

/// The hash length is the length of the hash function output in bytes. Note that the resulting hash is encoded with Base 64, so the digest will be ~1/3 longer.
Expand Down