#[non_exhaustive]pub struct GpgMe {}
Expand description
Used when the user configures gpgme to be used as a pgp backend.
Trait Implementations§
source§impl Crypto for GpgMe
impl Crypto for GpgMe
source§fn decrypt_string(&self, ciphertext: &[u8]) -> Result<String>
fn decrypt_string(&self, ciphertext: &[u8]) -> Result<String>
Reads a file and decrypts it Read more
source§fn encrypt_string(
&self,
plaintext: &str,
recipients: &[Recipient]
) -> Result<Vec<u8>>
fn encrypt_string( &self, plaintext: &str, recipients: &[Recipient] ) -> Result<Vec<u8>>
Encrypts a string Read more
source§fn sign_string(
&self,
to_sign: &str,
valid_gpg_signing_keys: &[[u8; 20]],
strategy: &FindSigningFingerprintStrategy
) -> Result<String>
fn sign_string( &self, to_sign: &str, valid_gpg_signing_keys: &[[u8; 20]], strategy: &FindSigningFingerprintStrategy ) -> Result<String>
Returns a gpg signature for the supplied string. Suitable to add to a gpg commit. Read more
source§fn verify_sign(
&self,
data: &[u8],
sig: &[u8],
valid_signing_keys: &[[u8; 20]]
) -> Result<SignatureStatus, VerificationError>
fn verify_sign( &self, data: &[u8], sig: &[u8], valid_signing_keys: &[[u8; 20]] ) -> Result<SignatureStatus, VerificationError>
Verifies is a signature is valid Read more
source§fn pull_keys(
&mut self,
recipients: &[Recipient],
_config_path: &Path
) -> Result<String>
fn pull_keys( &mut self, recipients: &[Recipient], _config_path: &Path ) -> Result<String>
Pull keys from the keyserver for those recipients. Read more
source§fn import_key(&mut self, key: &str, _config_path: &Path) -> Result<String>
fn import_key(&mut self, key: &str, _config_path: &Path) -> Result<String>
Import a key from text. Read more
source§fn get_key(&self, key_id: &str) -> Result<Box<dyn Key>>
fn get_key(&self, key_id: &str) -> Result<Box<dyn Key>>
Return a key corresponding to the given key id. Read more
source§fn get_all_trust_items(&self) -> Result<HashMap<[u8; 20], OwnerTrustLevel>>
fn get_all_trust_items(&self) -> Result<HashMap<[u8; 20], OwnerTrustLevel>>
Returns a map from key fingerprints to OwnerTrustLevel’s Read more
source§fn implementation(&self) -> CryptoImpl
fn implementation(&self) -> CryptoImpl
Returns the type of this
CryptoImpl
, useful for serializing the store configAuto Trait Implementations§
impl RefUnwindSafe for GpgMe
impl Send for GpgMe
impl Sync for GpgMe
impl Unpin for GpgMe
impl UnwindSafe for GpgMe
Blanket Implementations§
§impl<Src, Scheme> ApproxFrom<Src, Scheme> for Srcwhere
Scheme: ApproxScheme,
impl<Src, Scheme> ApproxFrom<Src, Scheme> for Srcwhere Scheme: ApproxScheme,
§fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
Convert the given value into an approximately equivalent representation.
§impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Srcwhere
Dst: ApproxFrom<Src, Scheme>,
Scheme: ApproxScheme,
impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Srcwhere Dst: ApproxFrom<Src, Scheme>, Scheme: ApproxScheme,
§fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
Convert the subject into an approximately equivalent representation.
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
§impl<T, Dst> ConvAsUtil<Dst> for T
impl<T, Dst> ConvAsUtil<Dst> for T
§impl<T> ConvUtil for T
impl<T> ConvUtil for T
§fn approx_as<Dst>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst, DefaultApprox>,
fn approx_as<Dst>(self) -> Result<Dst, Self::Err>where Self: Sized + ApproxInto<Dst, DefaultApprox>,
Approximate the subject to a given type with the default scheme.
§fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst, Scheme>,
Scheme: ApproxScheme,
fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err>where Self: Sized + ApproxInto<Dst, Scheme>, Scheme: ApproxScheme,
Approximate the subject to a given type with a specific scheme.
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<Src> TryFrom<Src> for Src
impl<Src> TryFrom<Src> for Src
§impl<Src, Dst> TryInto<Dst> for Srcwhere
Dst: TryFrom<Src>,
impl<Src, Dst> TryInto<Dst> for Srcwhere Dst: TryFrom<Src>,
§impl<Src> ValueFrom<Src> for Src
impl<Src> ValueFrom<Src> for Src
§fn value_from(src: Src) -> Result<Src, <Src as ValueFrom<Src>>::Err>
fn value_from(src: Src) -> Result<Src, <Src as ValueFrom<Src>>::Err>
Convert the given value into an exactly equivalent representation.
§impl<Src, Dst> ValueInto<Dst> for Srcwhere
Dst: ValueFrom<Src>,
impl<Src, Dst> ValueInto<Dst> for Srcwhere Dst: ValueFrom<Src>,
§fn value_into(self) -> Result<Dst, <Src as ValueInto<Dst>>::Err>
fn value_into(self) -> Result<Dst, <Src as ValueInto<Dst>>::Err>
Convert the subject into an exactly equivalent representation.