Click or drag to resize
MimeKit

SecureMimeContextGetPreferredEncryptionAlgorithm Method

Get the preferred encryption algorithm to use for encrypting to the specified recipients.

Namespace:  MimeKit.Cryptography
Assembly:  MimeKit (in MimeKit.dll) Version: 3.0.0
Syntax
C#
protected virtual EncryptionAlgorithm GetPreferredEncryptionAlgorithm(
	CmsRecipientCollection recipients
)

Parameters

recipients
Type: MimeKit.CryptographyCmsRecipientCollection
The recipients.

Return Value

Type: EncryptionAlgorithm
The 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.

See Also