Skip to main content

generate

Function generate 

Source
pub fn generate(prefix: &str) -> Result<String, String>
Expand description

Makes a secret: prefix followed by 256 random bits as 43 URL-safe base64 characters.

Random and that long, it needs no slow hash to be kept: keep hash of it.

ยงErrors

Returns an error when the operating system random source is unavailable.