javax.net.ssl.SSLException

Connection has been shutdown: javax.net.ssl.SSLHandshakeException: Received fatal alert: certificate_unknown

Samebug tips1

Import the server certificate into your truststore.


rprp

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Stack trace

  • javax.net.ssl.SSLException: Connection has been shutdown: javax.net.ssl.SSLHandshakeException: Received fatal alert: certificate_unknown at sun.security.ssl.SSLSocketImpl.checkEOF(SSLSocketImpl.java:1541) at sun.security.ssl.SSLSocketImpl.checkWrite(SSLSocketImpl.java:1553) at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:71) at sun.nio.cs.StreamEncoder.writeBytes(StreamEncoder.java:221) at sun.nio.cs.StreamEncoder.implFlushBuffer(StreamEncoder.java:291) at sun.nio.cs.StreamEncoder.implFlush(StreamEncoder.java:295) at sun.nio.cs.StreamEncoder.flush(StreamEncoder.java:141) at java.io.OutputStreamWriter.flush(OutputStreamWriter.java:229) at java.io.BufferedWriter.flush(BufferedWriter.java:254) at com.example.SSLReverseEchoer.main(SSLReverseEchoer.java:60) Caused by: javax.net.ssl.SSLHandshakeException: Received fatal alert: certificate_unknown at sun.security.ssl.Alerts.getSSLException(Alerts.java:192) at sun.security.ssl.Alerts.getSSLException(Alerts.java:154) at sun.security.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:2023) at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1125) at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1375) at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1403) at sun.security.ssl.SSLSocketImpl.getSession(SSLSocketImpl.java:2267) at com.example.SSLReverseEchoer.printSocketInfo(SSLReverseEchoer.java:94) at com.example.SSLReverseEchoer.main(SSLReverseEchoer.java:49)

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitor2 times, last one
Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitorOnce,
105 more bugmates