Skip to main content

Entropy

Trait Entropy 

Source
pub trait Entropy: Send + Sync {
    // Required method
    fn fill(&self, buf: &mut [u8]);
}
Expand description

Randomness, injected by the host (docs/PLAN.md §2: no ambient I/O). Encryption takes keys, salts and IVs from it; a deterministic source gives byte-identical output.

Required Methods§

Source

fn fill(&self, buf: &mut [u8])

Fills buf with random bytes.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§