Click or drag to resize
MimeKit

SecureMimeContext Class

A Secure MIME (S/MIME) cryptography context.
Inheritance Hierarchy

Namespace:  MimeKit.Cryptography
Assembly:  MimeKit (in MimeKit.dll) Version: 2.0.6.0
Syntax
C#
public abstract class SecureMimeContext : CryptographyContext

The SecureMimeContext type exposes the following members.

Constructors
  NameDescription
Protected methodSecureMimeContext
Initializes a new instance of the SecureMimeContext class.
Top
Properties
  NameDescription
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.
(Overrides CryptographyContextEncryptionProtocol.)
Public propertyKeyExchangeProtocol
Get the key exchange protocol.
(Overrides CryptographyContextKeyExchangeProtocol.)
Public propertySignatureProtocol
Get the signature protocol.
(Overrides CryptographyContextSignatureProtocol.)
Top
Methods
  NameDescription
Public methodCanEncrypt
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.
(Inherited from CryptographyContext.)
Public methodCompress
Compresses the specified stream.
Public methodDecompress
Decompress the specified stream.
Public methodDecompressTo
Decompress the specified stream to an output stream.
Public methodDecrypt
Decrypt the specified encryptedData.
(Inherited from CryptographyContext.)
Public methodDecryptTo
Decrypts the specified encryptedData to an output stream.
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 the unmanaged resources used by the CryptographyContext and optionally releases the managed resources.
(Inherited from CryptographyContext.)
Public methodEnable(DigestAlgorithm)
Enable the digest algorithm.
(Inherited from CryptographyContext.)
Public methodEnable(EncryptionAlgorithm)
Enable the encryption algorithm.
(Inherited from CryptographyContext.)
Public methodEncapsulatedSign(CmsSigner, Stream)
Cryptographically signs and encapsulates the content using the specified signer.
Public methodEncapsulatedSign(MailboxAddress, DigestAlgorithm, Stream)
Cryptographically signs and encapsulates the content using the specified signer and digest algorithm.
Public methodEncrypt(CmsRecipientCollection, Stream)
Encrypts the specified content for the specified recipients.
Public methodEncrypt(IEnumerableMailboxAddress, Stream)
Encrypt the specified content for the specified recipients.
(Inherited from CryptographyContext.)
Public methodEquals (Inherited from Object.)
Public methodExport
Exports the keys for the specified mailboxes.
(Inherited from CryptographyContext.)
Protected methodFinalize (Inherited from Object.)
Public methodGetDigestAlgorithm
Get the digest algorithm from the micalg parameter value in a multipart/signed part.
(Overrides CryptographyContextGetDigestAlgorithm(String).)
Public methodGetDigestAlgorithmName
Get the string name of the digest algorithm for use with the micalg parameter of a multipart/signed part.
(Overrides CryptographyContextGetDigestAlgorithmName(DigestAlgorithm).)
Protected methodStatic memberGetDigestOid
Get the OID for the digest algorithm.
Public methodGetHashCode (Inherited from Object.)
Protected methodGetPreferredEncryptionAlgorithm
Get the preferred encryption algorithm to use for encrypting to the specified recipients.
Public methodGetType (Inherited from Object.)
Public methodImport(X509Certificate)
Imports the specified certificate.
Public methodImport(X509Crl)
Imports the specified certificate revocation list.
Public methodImport(Stream)
Imports certificates (as from a certs-only application/pkcs-mime part) from the specified stream.
(Overrides CryptographyContextImport(Stream).)
Public methodImport(Stream, String)
Imports certificates and keys from a pkcs12-encoded stream.
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.)
Public methodSign(CmsSigner, Stream)
Cryptographically signs the content using the specified signer.
Public methodSign(MailboxAddress, DigestAlgorithm, Stream)
Cryptographically sign the content.
(Inherited from CryptographyContext.)
Public methodSupports
Check whether or not the specified protocol is supported by the CryptographyContext.
(Overrides CryptographyContextSupports(String).)
Public methodToString (Inherited from Object.)
Public methodVerify(Stream, Stream, CancellationToken)
Verify the specified content using the detached signatureData.
(Inherited from CryptographyContext.)
Public methodVerify(Stream, DigitalSignatureCollection, CancellationToken)
Verify the digital signatures of the specified signed data and extract the original content.
Public methodVerify(Stream, MimeEntity, CancellationToken)
Verify the digital signatures of the specified signed data and extract the original content.
Public methodVerifyAsync
Asynchronously verify the specified content using the detached signatureData.
(Inherited from CryptographyContext.)
Top
Remarks
Generally speaking, applications should not use a SecureMimeContext directly, but rather via higher level APIs such as MultipartSigned and ApplicationPkcs7Mime.
See Also