rok::core::crypto::secret
Secret storage (2.21.5): a buffer in the large-object space, so the
collector never moves or copies it, zeroed by wipe, by using
release and by the collection that frees it (rok_gc_secret_new).
Secret is the public byte form; SecretWords holds the algorithms'
32-bit key schedules and polynomials.
Structs
Secret
pub struct SecretA fixed-length secret byte string. Copies share the bytes.
pub fn zeroed(len: usize) -> Secretlenzero bytes.pub fn new(bytes: Bytes) -> SecretA copy of
bytes.pub const fn len(self) -> usizepub const fn as_bytes(self) -> Slice<u8>The bytes where they are, not a copy: a view reads zeros once the secret is wiped.
pub fn wipe(self)Overwrite the bytes with zeros now; every copy and view sees it.
Trait implementations 6
impl !Sync for Secretimpl Index<usize> for Secretimpl IndexSet<usize> for Secretimpl Sliceable<Range<usize>> for Secretimpl Drop for Secretimpl Debug for Secret