Secure Mime ContextImport(Stream, Cancellation Token) Method
Import certificates (as from a certs-only application/pkcs-mime part)
from the specified stream.
Definition
Namespace: MimeKit.Cryptography
Assembly: MimeKit.Cryptography (in MimeKit.Cryptography.dll) Version: 5.0.0
ICryptographyContextImport(Stream, CancellationToken)
Assembly: MimeKit.Cryptography (in MimeKit.Cryptography.dll) Version: 5.0.0
C#
public override void Import(
Stream stream,
CancellationToken cancellationToken = default
)Parameters
- stream Stream
- The raw key data.
- cancellationToken CancellationToken (Optional)
- The cancellation token.
Implements
ICryptographyContextImport(Stream, CancellationToken)ICryptographyContextImport(Stream, CancellationToken)
Remarks
Imports certificates (as from a certs-only application/pkcs-mime part)
from the specified stream.
Exceptions
| ArgumentNullException | stream is . |
| OperationCanceledException | The operation was cancelled via the cancellation token. |
| CmsException | An error occurred in the cryptographic message syntax subsystem. |