fix: 修复邮件配置smtps时的错误
This commit is contained in:
parent
5e22b003df
commit
e9d5c8b9d2
|
@ -43,8 +43,8 @@ public class MailService {
|
||||||
javaMailSender.setPassword(EncryptUtils.aesDecrypt(p.getParamValue()).toString());
|
javaMailSender.setPassword(EncryptUtils.aesDecrypt(p.getParamValue()).toString());
|
||||||
break;
|
break;
|
||||||
case "smtp.ssl":
|
case "smtp.ssl":
|
||||||
javaMailSender.setProtocol("smtps");
|
|
||||||
if (BooleanUtils.toBoolean(p.getParamValue())) {
|
if (BooleanUtils.toBoolean(p.getParamValue())) {
|
||||||
|
javaMailSender.setProtocol("smtps");
|
||||||
props.put("mail.smtp.socketFactory.class", "javax.net.ssl.SSLSocketFactory");
|
props.put("mail.smtp.socketFactory.class", "javax.net.ssl.SSLSocketFactory");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue