1、需要开启客户端授权码
授权码开启参考文章:《邮箱不可用 550 User has no permission》
https://blog.csdn.net/jinwufeiyang/article/details/76400708?locationNum=7&fps=1
如果没有授权码,后台会报错:
javax.mail.AuthenticationFailedException: 550 User has no permission
2、需要使用加密端口,465或587
参考文章:《关于javax.mail.MessagingException: Could not connect to SMTP host: smtp.qq.com, port: 25;》
https://blog.csdn.net/qq_21647977/article/details/77743808
如果使用25等端口,后台会报错:
javax.mail.MessagingException: Could not connect to SMTP host: smtp.qq.com, port: 25;
javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?
3、需要关闭防火墙。
网友评论