tuweni / org.apache.tuweni.crypto.sodium / PasswordHash / hashInteractive

hashInteractive

static fun hashInteractive(password: String!, length: Int, salt: Salt!): Bytes! (source)

Compute a key from a password, using the currently recommended algorithm and limits on operations and memory that are suitable for interactive use-cases.

Parameters

password - String!: The password to hash.

length - Int: The key length to generate.

salt - Salt!: A salt.

Return
Bytes!: The derived key.

static fun hashInteractive(password: Bytes!, length: Int, salt: Salt!): Bytes! (source)

Compute a key from a password, using the currently recommended algorithm and limits on operations and memory that are suitable for interactive use-cases.

Parameters

password - Bytes!: The password to hash.

length - Int: The key length to generate.

salt - Salt!: A salt.

Return
Bytes!: The derived key.

static fun hashInteractive(password: ByteArray!, length: Int, salt: Salt!): ByteArray! (source)

Compute a key from a password, using the currently recommended algorithm and limits on operations and memory that are suitable for interactive use-cases.

Parameters

password - ByteArray!: The password to hash.

length - Int: The key length to generate.

salt - Salt!: A salt.

Return
ByteArray!: The derived key.

static fun hashInteractive(password: String!, length: Int, salt: Salt!, algorithm: Algorithm!): Bytes! (source)

Compute a key from a password, using limits on operations and memory that are suitable for interactive use-cases.

Parameters

password - String!: The password to hash.

length - Int: The key length to generate.

salt - Salt!: A salt.

algorithm - Algorithm!: The algorithm to use.

Return
Bytes!: The derived key.

static fun hashInteractive(password: Bytes!, length: Int, salt: Salt!, algorithm: Algorithm!): Bytes! (source)

Compute a key from a password, using limits on operations and memory that are suitable for interactive use-cases.

Parameters

password - Bytes!: The password to hash.

length - Int: The key length to generate.

salt - Salt!: A salt.

algorithm - Algorithm!: The algorithm to use.

Return
Bytes!: The derived key.

static fun hashInteractive(password: ByteArray!, length: Int, salt: Salt!, algorithm: Algorithm!): ByteArray! (source)

Compute a key from a password, using limits on operations and memory that are suitable for interactive use-cases.

Parameters

password - ByteArray!: The password to hash.

length - Int: The key length to generate.

salt - Salt!: A salt.

algorithm - Algorithm!: The algorithm to use.

Return
ByteArray!: The derived key.

static fun hashInteractive(password: String!): String! (source)

Compute a hash from a password, using limits on operations and memory that are suitable for interactive use-cases.

Equivalent to hash(password, sensitiveOpsLimit(), sensitiveMemLimit()).

Parameters

password - String!: The password to hash.

Return
String!: The hash string.