Skip to main content

RandomSecretKey

Trait RandomSecretKey 

Source
pub trait RandomSecretKey {
    // Required method
    fn random_secret_key(csprng: &mut impl CryptoRng) -> Self;
}
Expand description

Curve implementation agnostic interface for generating random secret keys

Required Methods§

Source

fn random_secret_key(csprng: &mut impl CryptoRng) -> Self

Create a secret key from provided RNG.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl RandomSecretKey for StaticSecret

Source§

fn random_secret_key(csprng: &mut impl CryptoRng) -> Self

Source§

impl<C: CurveArithmetic> RandomSecretKey for SecretKey<C>

Source§

fn random_secret_key(csprng: &mut impl CryptoRng) -> Self

Implementors§

Source§

impl RandomSecretKey for ecdh_omr::dalek_ristretto255::StaticSecret