SmtpClient config: UseSsl => EnableSsl

master
Tudor Stanciu 2023-01-19 18:21:35 +02:00
parent c3b0fb60df
commit dc5ce5e96a
3 changed files with 3 additions and 3 deletions

View File

@ -4,7 +4,7 @@
{
public string Server { get; init; }
public int Port { get; init; }
public bool UseSsl { get; init; }
public bool EnableSsl { get; init; }
public bool UseAuthentication { get; init; }
public bool TrustServer { get; init; }
public AuthenticationOptions Authentication { get; init; }

View File

@ -23,7 +23,7 @@ namespace Correo.SmtpClient
var options = _optionsAccessor.Value;
_smtpClient = new System.Net.Mail.SmtpClient { Host = options.Server, Port = options.Port, EnableSsl = options.UseSsl };
_smtpClient = new System.Net.Mail.SmtpClient { Host = options.Server, Port = options.Port, EnableSsl = options.EnableSsl };
if (options.UseAuthentication)
{
if (string.IsNullOrEmpty(options.Authentication.Domain))

View File

@ -38,7 +38,7 @@
"Password": "********"
},
"UseAuthentication": true,
"UseSsl": true,
"EnableSsl": true,
"TrustServer": false
}
}