Categories
Coding Fedora Java Linux

SSLHandshakeException: no cipher suites in common

Here’s a quick tip if you happen to have problems with the “javax.net.ssl.SSLHandshakeException: no cipher suites in common” exception. This may be caused because the java security settings is restricting the ciphers and algorithms that applications are allowed to use.

This may be defined either at a system level (as in the case of Fedora, for example) or in the JVM distribution you are using. Regardless, one way to work-around this problem is to override the default java security settings (defined in java.security or in /etc/crypto-policies/back-ends/java.config in Fedora) using something like this:

-Djava.security.properties==/path/to/custom.java.security

If you don’t know what to do, you can probably just copy an existing java.security file, adjust the parameter(s) you need (ie.: jdk.tls.disabledAlgorithms).

This way you can easily adjust the security settings and is very handy if you have some code or tools relying on old security standards that are not recommended anymore.

Obs.: apparently there may be other reasons why it the no cipher suits in common could be raised, so your mileage may vary.

By Otavio Piske

Just another nerd

Leave a Reply

Your email address will not be published.