关于向foxmail发送报错的问题
-2023-06-07 14:17:39.729 [TID: N/A] ERROR 28772 --- [ XNIO-1 task-1] c.s.s.a.s.impl.SysEmailSendServiceImpl : Mail server connection failed; nested exception is javax.mail.MessagingException: Could not convert socket to TLS;
nested exception is:
javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target. Failed messages: javax.mail.MessagingException: Could not convert socket to TLS;
nested exception is:
javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
说白了就是TLS没有关闭,网上说是在配置文件修改
我当时就懵逼了,我们这个系统这些配置是在数据库配置的,有SSL的关闭和开启,没有TLS啊,最后只能顺着代码找,在一个犄角旮旯的工具类里面找到了TLS的配置
我也是服了