Method CreatePolicy
- Namespace
- MailFathom.Infrastructure.Mail
- Assembly
- MailFathom.Infrastructure.dll
CreatePolicy()
Builds the validated domain policy for this account.
public MailTransportSecurityPolicy CreatePolicy()
Returns
- MailTransportSecurityPolicy
The policy the mailbox adapter must obey.
Remarks
Startup validation rejects these settings long before this runs, so a failure here means an unsafe policy reached the runtime through some other path. It fails closed rather than connecting.
Exceptions
- MailTransportSecurityPolicyViolationException
Thrown when the configured combination is unsafe.
- ArgumentException
Thrown when no supported SASL mechanism is configured.