Click or drag to resize
MimeKit

GnuPGContext Class

An OpenPgpContext that uses the GnuPG keyrings.
Inheritance Hierarchy

Namespace: MimeKit.Cryptography
Assembly: MimeKit (in MimeKit.dll) Version: 4.7.1
Syntax
C#
public abstract class GnuPGContext : OpenPgpContext

The GnuPGContext type exposes the following members.

Constructors
 NameDescription
Protected methodGnuPGContext Initialize a new instance of the GnuPGContext class.
Protected methodGnuPGContext(String) Initialize a new instance of the GnuPGContext class.
Top
Properties
 NameDescription
Public propertyAutoKeyRetrieve Get or set whether unknown PGP keys should automtically be retrieved.
(Inherited from OpenPgpContext)
Public propertyDefaultEncryptionAlgorithm Get or set the default encryption algorithm.
(Inherited from OpenPgpContext)
Protected propertyDigestAlgorithmRank Get the preferred rank order for the digest algorithms; from the most preferred to the least.
(Inherited from CryptographyContext)
Public propertyEnabledDigestAlgorithms Get the enabled digest algorithms in ranked order.
(Inherited from CryptographyContext)
Public propertyEnabledEncryptionAlgorithms Get the enabled encryption algorithms in ranked order.
(Inherited from CryptographyContext)
Protected propertyEncryptionAlgorithmRank Get the preferred rank order for the encryption algorithms; from the most preferred to the least.
(Inherited from CryptographyContext)
Public propertyEncryptionProtocol Get the encryption protocol.
(Inherited from OpenPgpContext)
Public propertyKeyExchangeProtocol Get the key exchange protocol.
(Inherited from OpenPgpContext)
Public propertyKeyServer Get or set the key server to use when automatically retrieving keys.
(Inherited from OpenPgpContext)
Public propertyPrepareBeforeSigning Get or set whether a MimeEntity should be prepared before signing.
(Inherited from CryptographyContext)
Public propertyPublicKeyRingBundle Get the public keyring bundle.
Protected propertyPublicKeyRingPath Get the public keyring path.
Public propertySecretKeyRingBundle Get the secret keyring bundle.
Protected propertySecretKeyRingPath Get the secret keyring path.
Public propertySignatureProtocol Get the signature protocol.
(Inherited from OpenPgpContext)
Top
Methods
 NameDescription
Public methodCanEncrypt Check whether or not the cryptography context can encrypt to a particular recipient.
(Overrides CryptographyContextCanEncrypt(MailboxAddress, CancellationToken))
Public methodCanEncryptAsync Asynchronously check whether or not the cryptography context can encrypt to a particular recipient.
(Inherited from CryptographyContext)
Public methodCanSign Check whether or not a particular mailbox address can be used for signing.
(Overrides CryptographyContextCanSign(MailboxAddress, CancellationToken))
Public methodCanSignAsync Asynchronously check whether or not a particular mailbox address can be used for signing.
(Inherited from CryptographyContext)
Public methodDecrypt(Stream, CancellationToken) Decrypt the specified encryptedData.
(Inherited from OpenPgpContext)
Public methodDecrypt(Stream, DigitalSignatureCollection, CancellationToken) Decrypt the specified encryptedData and extracts the digital signers if the content was also signed.
(Inherited from OpenPgpContext)
Public methodDecryptAsync Asynchronously decrypt the specified encryptedData.
(Inherited from OpenPgpContext)
Public methodDecryptTo Decrypt an encrypted stream and extract the digital signers if the content was also signed.
(Inherited from OpenPgpContext)
Public methodDecryptToAsync Asynchronously decrypt an encrypted stream and extract the digital signers if the content was also signed.
(Inherited from OpenPgpContext)
Public methodDelete(PgpPublicKeyRing) Delete a public pgp keyring.
Public methodDelete(PgpSecretKeyRing) Delete a secret pgp keyring.
Public methodDisable(DigestAlgorithm) Disable the digest algorithm.
(Inherited from CryptographyContext)
Public methodDisable(EncryptionAlgorithm) Disable the encryption algorithm.
(Inherited from CryptographyContext)
Public methodDispose Releases all resources used by the CryptographyContext object.
(Inherited from CryptographyContext)
Protected methodDispose(Boolean) Releases all resources used by the OpenPgpContext object.
(Inherited from OpenPgpContext)
Public methodEnable(DigestAlgorithm) Enable the digest algorithm.
(Inherited from CryptographyContext)
Public methodEnable(EncryptionAlgorithm) Enable the encryption algorithm.
(Inherited from CryptographyContext)
Public methodEncrypt(IEnumerableMailboxAddress, Stream, CancellationToken) Encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEncrypt(IEnumerablePgpPublicKey, Stream, CancellationToken) Encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEncrypt(EncryptionAlgorithm, IEnumerableMailboxAddress, Stream, CancellationToken) Encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEncrypt(EncryptionAlgorithm, IEnumerablePgpPublicKey, Stream, CancellationToken) Encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEncryptAsync(IEnumerableMailboxAddress, Stream, CancellationToken) Asynchronously encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEncryptAsync(IEnumerablePgpPublicKey, Stream, CancellationToken) Asynchronously encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEncryptAsync(EncryptionAlgorithm, IEnumerableMailboxAddress, Stream, CancellationToken) Asynchronously encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEncryptAsync(EncryptionAlgorithm, IEnumerablePgpPublicKey, Stream, CancellationToken) Asynchronously encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodEnumeratePublicKeyRings Enumerate all public keyrings.
Public methodEnumeratePublicKeyRings(MailboxAddress) Enumerate the public keyrings for a particular mailbox.
Public methodEnumeratePublicKeys Enumerate all public keys.
Public methodEnumeratePublicKeys(MailboxAddress) Enumerate the public keys for a particular mailbox.
Public methodEnumerateSecretKeyRings Enumerate all secret keyrings.
Public methodEnumerateSecretKeyRings(MailboxAddress) Enumerate the secret keyrings for a particular mailbox.
Public methodEnumerateSecretKeys Enumerate all secret keys.
Public methodEnumerateSecretKeys(MailboxAddress) Enumerate the secret keys for a particular mailbox.
Public methodEquals
(Inherited from Object)
Public methodExport(IEnumerableMailboxAddress, CancellationToken) Export the public keys for the specified mailboxes.
(Overrides CryptographyContextExport(IEnumerableMailboxAddress, CancellationToken))
Public methodExport(IEnumerablePgpPublicKey, CancellationToken) Export the specified public keys.
(Inherited from OpenPgpContext)
Public methodExport(PgpPublicKeyRingBundle, CancellationToken) Export the specified public keys.
(Inherited from OpenPgpContext)
Public methodExport(IEnumerableMailboxAddress, Stream, Boolean, CancellationToken) Export the public keyrings for the specified mailboxes.
(Overrides OpenPgpContextExport(IEnumerableMailboxAddress, Stream, Boolean, CancellationToken))
Public methodExport(IEnumerablePgpPublicKey, Stream, Boolean, CancellationToken) Export the specified public keys.
(Inherited from OpenPgpContext)
Public methodExport(PgpPublicKeyRingBundle, Stream, Boolean, CancellationToken) Export the public keyring bundle.
(Inherited from OpenPgpContext)
Public methodExportAsync(IEnumerableMailboxAddress, CancellationToken) Asynchronously export the public keys for the specified mailboxes.
(Overrides CryptographyContextExportAsync(IEnumerableMailboxAddress, CancellationToken))
Public methodExportAsync(IEnumerablePgpPublicKey, CancellationToken) Asynchronously export the specified public keys.
(Inherited from OpenPgpContext)
Public methodExportAsync(PgpPublicKeyRingBundle, CancellationToken) Asynchronously export the specified public keys.
(Inherited from OpenPgpContext)
Public methodExportAsync(IEnumerableMailboxAddress, Stream, Boolean, CancellationToken) Asynchronously export the public keyrings for the specified mailboxes.
(Overrides OpenPgpContextExportAsync(IEnumerableMailboxAddress, Stream, Boolean, CancellationToken))
Public methodExportAsync(IEnumerablePgpPublicKey, Stream, Boolean, CancellationToken) Asynchronously export the specified public keys.
(Inherited from OpenPgpContext)
Public methodExportAsync(PgpPublicKeyRingBundle, Stream, Boolean, CancellationToken) Asynchronously export the public keyring bundle.
(Inherited from OpenPgpContext)
Protected methodFinalize
(Inherited from Object)
Public methodGenerateKeyPair Generate a new key pair.
Public methodGetDigestAlgorithm(String) Get the digest algorithm from the micalg parameter value in a multipart/signed part.
(Inherited from OpenPgpContext)
Public methodGetDigestAlgorithmName Get the string name of the digest algorithm for use with the micalg parameter of a multipart/signed part.
(Inherited from OpenPgpContext)
Public methodGetHashCode
(Inherited from Object)
Protected methodGetPasswordForKey Get the password for a secret key.
(Inherited from OpenPgpContext)
Protected methodGetPrivateKey Gets the private key from the specified secret key.
(Inherited from OpenPgpContext)
Protected methodGetPublicKey Get the public key associated with the mailbox address.
Protected methodGetPublicKeyRing Get the public keyring that contains the specified key.
(Overrides OpenPgpContextGetPublicKeyRing(Int64, CancellationToken))
Protected methodGetPublicKeyRingAsync Asynchronously get the public keyring that contains the specified key.
(Overrides OpenPgpContextGetPublicKeyRingAsync(Int64, CancellationToken))
Public methodGetPublicKeys Get the public keys for the specified mailbox addresses.
(Overrides OpenPgpContextGetPublicKeys(IEnumerableMailboxAddress, CancellationToken))
Public methodGetPublicKeysAsync Asynchronously get the public keys for the specified mailbox addresses.
(Inherited from OpenPgpContext)
Protected methodGetSecretKey Get the secret key for a specified key identifier.
(Overrides OpenPgpContextGetSecretKey(Int64, CancellationToken))
Protected methodGetSecretKeyAsync Asynchronously get the secret key for a specified key identifier.
(Inherited from OpenPgpContext)
Public methodGetSigningKey Get the signing key associated with the mailbox address.
(Overrides OpenPgpContextGetSigningKey(MailboxAddress, CancellationToken))
Public methodGetSigningKeyAsync Asynchronously get the signing key associated with the mailbox address.
(Inherited from OpenPgpContext)
Public methodGetType
(Inherited from Object)
Public methodImport(PgpPublicKeyRing, CancellationToken) Import a public pgp keyring.
(Overrides OpenPgpContextImport(PgpPublicKeyRing, CancellationToken))
Public methodImport(PgpPublicKeyRingBundle, CancellationToken) Import the specified public keyring bundle.
(Overrides OpenPgpContextImport(PgpPublicKeyRingBundle, CancellationToken))
Public methodImport(PgpSecretKeyRing, CancellationToken) Import a secret pgp keyring.
(Overrides OpenPgpContextImport(PgpSecretKeyRing, CancellationToken))
Public methodImport(PgpSecretKeyRingBundle, CancellationToken) Import a secret pgp keyring bundle.
(Overrides OpenPgpContextImport(PgpSecretKeyRingBundle, CancellationToken))
Public methodImport(Stream, CancellationToken) Import public pgp keys from the specified stream.
(Inherited from OpenPgpContext)
Public methodImportAsync Asynchronously import public pgp keys from the specified stream.
(Inherited from OpenPgpContext)
Public methodIsEnabled(DigestAlgorithm) Check whether the specified digest algorithm is enabled.
(Inherited from CryptographyContext)
Public methodIsEnabled(EncryptionAlgorithm) Check whether the specified encryption algorithm is enabled.
(Inherited from CryptographyContext)
Protected methodMemberwiseClone
(Inherited from Object)
Protected methodRetrievePublicKeyRing Retrieve the public keyring using the configured key server.
(Inherited from OpenPgpContext)
Protected methodRetrievePublicKeyRingAsync Asynchronously retrieve the public keyring using the configured key server.
(Inherited from OpenPgpContext)
Protected methodSavePublicKeyRingBundle Saves the public key-ring bundle.
Protected methodSaveSecretKeyRingBundle Saves the secret key-ring bundle.
Public methodSign(MailboxAddress, DigestAlgorithm, Stream, CancellationToken) Sign the content using the specified signer and digest algorithm.
(Inherited from OpenPgpContext)
Public methodSign(PgpSecretKey, DigestAlgorithm, Stream, CancellationToken) Sign the content using the specified signer and digest algorithm.
(Inherited from OpenPgpContext)
Public methodSignAndEncrypt(MailboxAddress, DigestAlgorithm, IEnumerableMailboxAddress, Stream, CancellationToken) Sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAndEncrypt(PgpSecretKey, DigestAlgorithm, IEnumerablePgpPublicKey, Stream, CancellationToken) Sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAndEncrypt(MailboxAddress, DigestAlgorithm, EncryptionAlgorithm, IEnumerableMailboxAddress, Stream, CancellationToken) Sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAndEncrypt(PgpSecretKey, DigestAlgorithm, EncryptionAlgorithm, IEnumerablePgpPublicKey, Stream, CancellationToken) Sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAndEncryptAsync(MailboxAddress, DigestAlgorithm, IEnumerableMailboxAddress, Stream, CancellationToken) Asynchronously sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAndEncryptAsync(PgpSecretKey, DigestAlgorithm, IEnumerablePgpPublicKey, Stream, CancellationToken) Asynchronously sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAndEncryptAsync(MailboxAddress, DigestAlgorithm, EncryptionAlgorithm, IEnumerableMailboxAddress, Stream, CancellationToken) Asynchronously sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAndEncryptAsync(PgpSecretKey, DigestAlgorithm, EncryptionAlgorithm, IEnumerablePgpPublicKey, Stream, CancellationToken) Asynchronously sign and encrypt the specified content for the specified recipients.
(Inherited from OpenPgpContext)
Public methodSignAsync(MailboxAddress, DigestAlgorithm, Stream, CancellationToken) Asynchronously sign the content using the specified signer and digest algorithm.
(Inherited from OpenPgpContext)
Public methodSignAsync(PgpSecretKey, DigestAlgorithm, Stream, CancellationToken) Asynchronously sign the content using the specified signer and digest algorithm.
(Inherited from OpenPgpContext)
Public methodSignKey Sign a public key.
Public methodSupports Check whether or not the specified protocol is supported.
(Inherited from OpenPgpContext)
Public methodToString
(Inherited from Object)
Public methodVerify Verify the specified content using the detached signatureData.
(Inherited from OpenPgpContext)
Public methodVerifyAsync Asynchronously verify the specified content using the detached signatureData.
(Inherited from OpenPgpContext)
Top
Remarks
An OpenPgpContext that uses the GnuPG keyrings.
See Also