Package de.nycode.bcrypt

Functions

hash
Link copied to clipboard
common
fun hash(input: String, cost: Int = 6): ByteArray
Hashes an input with bcrypt with the specified cost.
fun hash(input: String, cost: Int = 6): ByteArray
fun hash(input: String, cost: Int = 6): ByteArray
hashAsync
Link copied to clipboard
js
suspend fun hashAsync(input: String, cost: Int): ByteArray
Hashes an input asynchronously with the specified cost.
verify
Link copied to clipboard
common
fun verify(input: String, expected: ByteArray): Boolean
Verifies an input to match the expected hash with the bcrypt algorithm.
js
fun verify(input: String, expected: ByteArray): Boolean
Verifies an input to match the expected hash with the bcrypt algorithm.
fun verify(input: String, expected: ByteArray): Boolean
verifyAsync
Link copied to clipboard
js
suspend fun verifyAsync(input: String, expected: ByteArray): Boolean
Verifies an input asynchronously to match the expected hash with the bcrypt algorithm.