第二次尝试时javax.net.ssl.SSLHandshakeException

时间:2018-04-20 21:04:08

标签: java web-services ssl soap weblogic

我将所需的证书添加到我的java / weblogic证书中,并解决了SSL Hand shake异常问题。但是,一旦我启动我的服务器,该应用程序在第一次尝试时工作正常,但当我发送第二个请求时,它再次抛出握手错误。是因为超时还是什么?

Caused by: javax.net.ssl.SSLException: Connection has been shutdown: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
    at sun.security.ssl.SSLSocketImpl.checkEOF(SSLSocketImpl.java:1496)
    at sun.security.ssl.SSLSocketImpl.checkWrite(SSLSocketImpl.java:1508)
    at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:70)
    at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
    at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
    at java.io.FilterOutputStream.flush(FilterOutputStream.java:140)

Caused by: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
    at sun.security.ssl.Alerts.getSSLException(Alerts.java:192)
    at sun.security.ssl.Alerts.getSSLException(Alerts`enter code here`.java:154)
    at sun.security.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1979)

1 个答案:

答案 0 :(得分:0)

在setDomainEnv.cmd中为JAVA_OPTIONS设置此项解决了这个问题!

-Dhttps.protocols = TLSv1.1,TLSv1.2工作