pub struct NullRng;Expand description
Entropy-free RNG that refuses to produce bytes.
Useful for test paths that should never require randomness (e.g. pure
verdict evaluation with no receipt ID generation). Callers that need
to mint receipt IDs must supply a real RNG, typically via the
getrandom-backed adapter shim in chio-kernel.
Trait Implementations§
Source§impl Rng for NullRng
impl Rng for NullRng
Source§fn fill_bytes(&self, dest: &mut [u8])
fn fill_bytes(&self, dest: &mut [u8])
Fill
dest with cryptographically secure random bytes.impl Copy for NullRng
Auto Trait Implementations§
impl Freeze for NullRng
impl RefUnwindSafe for NullRng
impl Send for NullRng
impl Sync for NullRng
impl Unpin for NullRng
impl UnsafeUnpin for NullRng
impl UnwindSafe for NullRng
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more