pub struct Secret<'a>(/* private fields */);Expand description
A secret that mixes with a password (and a salt) to create a hash. This is sometimes referred to as a “pepper.”
A 32-byte key is recommended. Do not use an alphanumeric password or passphrase; the entrophy of a 32-character password is much lower than the entrophy of a 32-byte key. This key should be generated with a cryptographically-secure random number generator and stored securely.
Implementations§
Trait Implementations§
impl<'a> Copy for Secret<'a>
Auto Trait Implementations§
impl<'a> Freeze for Secret<'a>
impl<'a> RefUnwindSafe for Secret<'a>
impl<'a> Send for Secret<'a>
impl<'a> Sync for Secret<'a>
impl<'a> Unpin for Secret<'a>
impl<'a> UnwindSafe for Secret<'a>
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