我在尝试了许多选项后发布了这个问题。以下是我尝试过的选项。1. 添加属性到{JAVA_HOME}/jre/lib/security/java.security security.provider.1=org.bouncycastle.jce.provider.BouncyCastleProvider从下面的链接下载 jar 并添加到 {JAVA_HOME}/jre/lib/security http://www.oracle.com/technetwork/java/javase/downloads/jce-7-download-432124.html2.添加java -Dhttps.protocols=TLSv1.2,TLSv1.1,TLSv13.添加System.setProperty("https.protocols", "TLSv1.2,TLSv1.1,SSLv3"); 在连接之前。我仍然遇到这个问题,非常感谢任何帮助。14:37:28,040 INFO [STDOUT] SALM:login#TID:224#ST:2019-07-12 14:35:03.614, WRITE: TLSv1.2 Handshake, length = 22714:37:28,311 INFO [STDOUT] SALM:login#TID:224#ST:2019-07-12 14:35:03.614, READ: TLSv1.2 Alert, length = 214:37:28,314 INFO [STDOUT] SALM:login#TID:224#ST:2019-07-12 14:35:03.614, RECV TLSv1 ALERT: fatal, handshake_failure14:37:28,317 INFO [STDOUT] SALM:login#TID:224#ST:2019-07-12 14:35:03.614, called closeSocket()14:37:28,319 INFO [STDOUT] SALM:login#TID:224#ST:2019-07-12 14:35:03.614, handling exception: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure14:37:32,023 FATAL [com.de.teamdynamics.webhelper.TeamDynamicHelper] CurrentThreadID=224 TeamDynamicHelper:processTeamDynamicsDataJob:Error - javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure14:37:32,024 FATAL [com.de.base.util.general.WebUtil] CurrentThreadID=224 Exception===> Values ===>javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
2 回答
小唯快跑啊
TA贡献1863条经验 获得超2个赞
这最终对我有用:
SSLContext context = SSLContext.getInstance("TLSv1.2");
context.init(null,null,null);
SSLContext.setDefault(context);
繁华开满天机
TA贡献1816条经验 获得超4个赞
我多次遇到这个问题,对我来说,它通过更新 US_export_policy.jar 并在其中添加 ssl 证书来工作。$JAVA_HOME/jre/lib/security/cacerts
您可以参考此链接: https ://drissamri.be/blog/2017/02/22/trusting-lets-encrypt -java/
添加回答
举报
0/150
提交
取消