Enum pgp::types::plain_secret::PlainSecretParams
source · pub enum PlainSecretParams {
RSA {
d: Mpi,
p: Mpi,
q: Mpi,
u: Mpi,
},
DSA(Mpi),
ECDSA(Mpi),
ECDH(Mpi),
Elgamal(Mpi),
EdDSA(Mpi),
}
Variants§
Implementations§
source§impl PlainSecretParams
impl PlainSecretParams
pub fn from_slice( data: &[u8], alg: PublicKeyAlgorithm, _params: &PublicParams ) -> Result<Self>
pub fn string_to_key_id(&self) -> u8
pub fn checksum_simple(&self) -> Vec<u8> ⓘ
pub fn checksum_sha1(&self) -> Vec<u8> ⓘ
pub fn as_ref(&self) -> PlainSecretParamsRef<'_>
pub fn encrypt<R: CryptoRng + Rng>( self, rng: &mut R, passphrase: &str, alg: SymmetricKeyAlgorithm, s2k: StringToKey, version: KeyVersion, id: u8 ) -> Result<EncryptedSecretParams>
Trait Implementations§
source§impl Clone for PlainSecretParams
impl Clone for PlainSecretParams
source§fn clone(&self) -> PlainSecretParams
fn clone(&self) -> PlainSecretParams
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 PlainSecretParams
impl Debug for PlainSecretParams
source§impl Drop for PlainSecretParams
impl Drop for PlainSecretParams
source§impl PartialEq for PlainSecretParams
impl PartialEq for PlainSecretParams
source§fn eq(&self, other: &PlainSecretParams) -> bool
fn eq(&self, other: &PlainSecretParams) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for PlainSecretParams
impl Serialize for PlainSecretParams
source§impl Zeroize for PlainSecretParams
impl Zeroize for PlainSecretParams
impl Eq for PlainSecretParams
impl StructuralPartialEq for PlainSecretParams
Auto Trait Implementations§
impl Freeze for PlainSecretParams
impl RefUnwindSafe for PlainSecretParams
impl Send for PlainSecretParams
impl Sync for PlainSecretParams
impl Unpin for PlainSecretParams
impl UnwindSafe for PlainSecretParams
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