pub trait Zeroize {
fn zeroize(&mut self);
}
Expand description
Trait for securely erasing types from memory
Zero out this object from memory using Rust intrinsics which ensure the
zeroization operation is not “optimized away” by the compiler.
impl Zeroize for __m128
This is supported on x86 and target feature sse
only.
impl Zeroize for __m128d
This is supported on x86 and target feature sse2
only.
impl Zeroize for __m128i
This is supported on x86 and target feature sse2
only.
impl<Z> Zeroize for Vec<Z> where
Z: Zeroize,
This is supported on crate feature alloc
only.
“Best effort” zeroization for Vec
.
Ensures the entire capacity of the Vec
is zeroed. Cannot ensure that
previous reallocations did not leave values on the heap.
impl<Z> Zeroize for Box<[Z]> where
Z: Zeroize,
This is supported on crate feature alloc
only.
Unlike Vec
, Box<[Z]>
cannot reallocate, so we can be sure that we are not leaving
values on the heap.
impl Zeroize for String
This is supported on crate feature alloc
only.