BouncyCastleSecureMimeContextDecryptAsync Method

Asynchronously decrypt the specified encryptedData.

Definition

Namespace: MimeKit.Cryptography
Assembly: MimeKit.Cryptography (in MimeKit.Cryptography.dll) Version: 5.0.0
C#
public override Task<MimeEntity> DecryptAsync(
	Stream encryptedData,
	CancellationToken cancellationToken = default
)

Parameters

encryptedData  Stream
The encrypted data.
cancellationToken  CancellationToken  (Optional)
The cancellation token.

Return Value

TaskMimeEntity
The decrypted MimeEntity.

Implements

ICryptographyContextDecryptAsync(Stream, CancellationToken)

Remarks

Asynchronously decrypts the specified encryptedData.

Exceptions

ArgumentNullException encryptedData is .
OperationCanceledException The operation was canceled via the cancellation token.
CmsException An error occurred in the cryptographic message syntax subsystem.

See Also