Skip to main content

Decoy

Trait Decoy 

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

Generate legitimate looking instances of data structures without user input.

Required Methods§

Source

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

Create a decoy instance from provided RNG.

§Security

Implementers must ensure this function generates valid cryptographic values, as invalid values may make an honest actor using ECDH-OMR believe the entity relaying Hints is acting dishonestly. In other words: decoys must be valid values and be indistinguishable from real values to passive observers.

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 Decoy for PublicKey

Source§

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

Source§

impl<C: CurveArithmetic> Decoy for PublicKey<C>

Source§

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

Implementors§

Source§

impl Decoy for ecdh_omr::dalek_ristretto255::PublicKey

Source§

impl<K: KeyPair, L: ArraySize> Decoy for HintSeed<K, L>