Merge pull request #2083 from deltachat/smtp-plain

smtp: do not use STARTTLS when PLAIN connection is requested
This commit is contained in:
link2xt
2020-11-15 23:37:41 +03:00
committed by GitHub

View File

@@ -192,7 +192,8 @@ impl Smtp {
}; };
let security = match lp.security { let security = match lp.security {
Socket::STARTTLS | Socket::Plain => smtp::ClientSecurity::Opportunistic(tls_parameters), Socket::Plain => smtp::ClientSecurity::None,
Socket::STARTTLS => smtp::ClientSecurity::Required(tls_parameters),
_ => smtp::ClientSecurity::Wrapper(tls_parameters), _ => smtp::ClientSecurity::Wrapper(tls_parameters),
}; };