Module crypto

Module crypto 

Source
Expand description

Cryptographic utilities.

Functionsยง

constant_time_eq
Constant-time string comparison.
generate_random_bytes
Generate a secure random byte array.
generate_random_string
Generate a secure random string.
generate_token
Generate a secure token.
sha256
Compute SHA256 hash.
sha256_hex
Compute SHA256 hash and return as hex string.