Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to find what SSL/TLS version is used in Java

Tags:

java

ssl

I have a java based client (using java 1.6.30) that opens an SSL connection to my server deployed on Tomcat 7.0.26. Tomcat is using Java 6 and in the server.xml I configured the connector to use sslProtocol="TLS".

I wonder what is the SSL version being used? Is it TLS1.0? TLS1.1? Something else?

like image 576
Guy Avatar asked May 08 '12 14:05

Guy


People also ask

How do you check which TLS version is used in Java?

Show activity on this post. Get the SSLSession from your SSLSocket on your client and use its getProtocol() method. Oracle JRE/OpenJDK 6 supports SSLv3 and TLS 1.0. You would need at least the IBM JRE 6/7 or Oracle JRE/OpenJDK 7 to get support for TLS 1.1 and TLS 1.2.

What version of TLS does Java 11 use?

The JDK 11 release includes an implementation of the Transport Layer Security (TLS) 1.3 specification (RFC 8446). For more details including a list of the features that are supported, refer to the Java Secure Socket Extension (JSSE) Reference Guide documentation and JEP 332.

What version of TLS does Java 7 use?

And while Java 7 supports TLSv1. 2, the default is TLS v1.


1 Answers

Get the SSLSession from your SSLSocket on your client and use its getProtocol() method.

Oracle JRE/OpenJDK 6 supports SSLv3 and TLS 1.0. You would need at least the IBM JRE 6/7 or Oracle JRE/OpenJDK 7 to get support for TLS 1.1 and TLS 1.2. (This is also related to the available cipher suites, as mentioned in this question.)

like image 128
Bruno Avatar answered Sep 30 '22 13:09

Bruno