IApplicationPkcs7MimeVerify(SecureMimeContext, MimeEntity, CancellationToken) Method

Verify the signed-data and return the unencapsulated MimeEntity.

Definition

Namespace: MimeKit.Cryptography
Assembly: MimeKit.Cryptography (in MimeKit.Cryptography.dll) Version: 5.0.0
C#
DigitalSignatureCollection Verify(
	SecureMimeContext ctx,
	out MimeEntity entity,
	CancellationToken cancellationToken = default
)

Parameters

ctx  SecureMimeContext
The S/MIME context to use for verifying the signature.
entity  MimeEntity
The unencapsulated entity.
cancellationToken  CancellationToken  (Optional)
The cancellation token.

Return Value

DigitalSignatureCollection
The list of digital signatures.

Remarks

Verifies the signed-data and returns the unencapsulated MimeEntity.

Exceptions

ArgumentNullException ctx is .
InvalidOperationException The "smime-type" parameter on the Content-Type header is not "signed-data".
FormatException The extracted content could not be parsed as a MIME entity.
ObjectDisposedException The IApplicationPkcs7Mime has been disposed.
OperationCanceledException The operation was canceled via the cancellation token.
CmsException An error occurred in the cryptographic message syntax subsystem.

See Also