Mime |
public Task EncryptAsync( CryptographyContext ctx, CancellationToken cancellationToken = default )
Exception | Condition |
---|---|
ArgumentNullException | ctx is null. |
ArgumentException | An unknown type of cryptography context was used. |
InvalidOperationException | The Body has not been set. -or- No recipients have been specified. |
OperationCanceledException | The operation was canceled via the cancellation token. |
CertificateNotFoundException | A certificate could not be found for one or more of the recipients. |
PublicKeyNotFoundException | The public key could not be found for one or more of the recipients. |