Module askar_crypto::random
source · [−]Expand description
Support for random number generation
Structs
A generator for deterministic random bytes
Constants
The expected length of a seed for fill_random_deterministic
Traits
A trait for generating raw key material, generally cryptographically random bytes
Combined trait for CryptoRng and RngCore
Functions
default_rng
getrandom
Obtain an instance of the default random number generator
Fill a mutable slice with random data using the system random number generator.
Written to be compatible with randombytes_deterministic in libsodium, used to generate a deterministic symmetric encryption key
random_secret
alloc
Create a new SecretBytes
instance with random data.