| SaslMechanismCreate(String, NetworkCredential) Method |
Create an instance of the specified SASL mechanism using the supplied credentials.
Namespace: MailKit.SecurityAssembly: MailKit (in MailKit.dll) Version: 4.7.1
Syntax public static SaslMechanism Create(
string mechanism,
NetworkCredential credentials
)
Parameters
- mechanism String
- The name of the SASL mechanism.
- credentials NetworkCredential
- The user's credentials.
Return Value
SaslMechanismAn instance of the requested SASL mechanism if supported; otherwise
null.
Exceptions Remarks
If unsure that a particular SASL mechanism is supported, you should first call
IsSupported(String).
See Also