javax.net.ssl.SSLHandshakeException: Received fatal alert: bad_certificate

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

,
via Stack Overflow by Strelok

Import the server certificate into your truststore.

Solutions on the web

via GitHub by yschimke
, 10 months ago
Received fatal alert: bad_certificate
via Stack Overflow by wFateem
, 1 month ago
via jetbrains.com by Unknown author, 7 months ago
via Stack Overflow by Unknown author, 2 years ago
via GitHub by gregw
, 1 year ago
Received fatal alert: no_application_protocol
javax.net.ssl.SSLHandshakeException: Received fatal alert: bad_certificate
at sun.security.ssl.Alerts.getSSLException(Alerts.java:192)
at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1917)
at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:301)
at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:291)
at sun.security.ssl.ServerHandshaker.clientCertificate(ServerHandshaker.java:1797)
at sun.security.ssl.ServerHandshaker.processMessage(ServerHandshaker.java:222)
at sun.security.ssl.Handshaker.processLoop(Handshaker.java:925)
at sun.security.ssl.Handshaker.process_record(Handshaker.java:860)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1043)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1343)
at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1371)
at undefined.SSLSocketFailedClientTest.doServerSide(SSLSocketFailedClientTest.java:139)
at undefined.SSLSocketFailedClientTest$1.run(SSLSocketFailedClientTest.java:345)

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 2 years ago
Samebug visitor profile picture
Unknown user
Once, 2 years ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.