Secure Mime ContextGet Preferred Encryption Algorithm Method
Get the preferred encryption algorithm to use for encrypting to the specified recipients.
Definition
Namespace: MimeKit.Cryptography
Assembly: MimeKit.Cryptography (in MimeKit.Cryptography.dll) Version: 5.0.0
The preferred encryption algorithm.
Assembly: MimeKit.Cryptography (in MimeKit.Cryptography.dll) Version: 5.0.0
C#
protected virtual EncryptionAlgorithm GetPreferredEncryptionAlgorithm(
CmsRecipientCollection recipients
)Parameters
- recipients CmsRecipientCollection
- The recipients.
Return Value
EncryptionAlgorithmThe preferred encryption algorithm.
Remarks
Gets the preferred encryption algorithm to use for encrypting to the specified recipients based on the encryption algorithms supported by each of the recipients, the EnabledEncryptionAlgorithms, and the EncryptionAlgorithmRank.
If the supported encryption algorithms are unknown for any recipient, it is assumed that the recipient supports at least the Triple-DES encryption algorithm.