Enum pgp::types::StringToKey
source · pub enum StringToKey {
Simple {
hash_alg: HashAlgorithm,
},
Salted {
hash_alg: HashAlgorithm,
salt: [u8; 8],
},
Reserved {
unknown: Vec<u8>,
},
IteratedAndSalted {
hash_alg: HashAlgorithm,
salt: [u8; 8],
count: u8,
},
Argon2 {
salt: [u8; 16],
t: u8,
p: u8,
m_enc: u8,
},
Private {
typ: u8,
unknown: Vec<u8>,
},
Other {
typ: u8,
unknown: Vec<u8>,
},
}
Variants§
Implementations§
source§impl StringToKey
impl StringToKey
pub fn new_default<R: CryptoRng + Rng>(rng: &mut R) -> Self
pub fn new_iterated<R: CryptoRng + Rng>( rng: &mut R, hash_alg: HashAlgorithm, count: u8 ) -> Self
pub fn id(&self) -> u8
Trait Implementations§
source§impl Clone for StringToKey
impl Clone for StringToKey
source§fn clone(&self) -> StringToKey
fn clone(&self) -> StringToKey
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for StringToKey
impl Debug for StringToKey
source§impl PartialEq for StringToKey
impl PartialEq for StringToKey
source§fn eq(&self, other: &StringToKey) -> bool
fn eq(&self, other: &StringToKey) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for StringToKey
impl Serialize for StringToKey
impl Eq for StringToKey
impl StructuralPartialEq for StringToKey
Auto Trait Implementations§
impl Freeze for StringToKey
impl RefUnwindSafe for StringToKey
impl Send for StringToKey
impl Sync for StringToKey
impl Unpin for StringToKey
impl UnwindSafe for StringToKey
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