Caused by: javax.net.ssl.SSLException: Received fatal alert: protocol_version

Hi, I am working on simple spring boot config server application which is tring to load properties file from gitbug.I am getting below error. I am using jdk 1.8. I am launching spring boot application from eclipse oxygen.

Please suggest how to resolve this.

i have already tried setting below variables in eclipse .ini file.

-Dhttps.protocols=TLSv1.2

org.eclipse.jgit.api.errors.TransportException: https://github.com/cloudspring7/somecloud.git: cannot open git-upload-pack
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:252) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.eclipse.jgit.api.CloneCommand.fetch(CloneCommand.java:306) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.eclipse.jgit.api.CloneCommand.call(CloneCommand.java:200) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.cloneToBasedir(JGitEnvironmentRepository.java:574) [spring-cloud-config-server-2.0.2.RELEASE.jar:2.0.2.RELEASE]
at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.copyRepository(JGitEnvironmentRepository.java:549) [spring-cloud-config-server-2.0.2.RELEASE.jar:2.0.2.RELEASE]
at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.createGitClient(JGitEnvironmentRepository.java:532) [spring-cloud-config-server-2.0.2.RELEASE.jar:2.0.2.RELEASE]
at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.refresh(JGitEnvironmentRepository.java:261) [spring-cloud-config-server-2.0.2.RELEASE.jar:2.0.2.RELEASE]
at org.springframework.cloud.config.server.environment.JGitEnvironmentRepository.getLocations(JGitEnvironmentRepository.java:240) [spring-cloud-config-server-2.0.2.RELEASE.jar:2.0.2.RELEASE]
at org.springframework.cloud.config.server.environment.MultipleJGitEnvironmentRepository.getLocations(MultipleJGitEnvironmentRepository.java:150)
Caused by: org.eclipse.jgit.errors.TransportException: https://github.com/cloudspring7/somecloud.git: cannot open git-upload-pack
at org.eclipse.jgit.transport.TransportHttp.connect(TransportHttp.java:584) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.eclipse.jgit.transport.TransportHttp.openFetch(TransportHttp.java:345) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:137) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:123) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1269) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:241) ~[org.eclipse.jgit-4.11.0.201803080745-r.jar:4.11.0.201803080745-r]
… 79 common frames omitted
Caused by: javax.net.ssl.SSLException: Received fatal alert: protocol_version
at com.ibm.jsse2.j.a(j.java:35) ~[na:8.0 build_20160616]
at com.ibm.jsse2.j.a(j.java:31) ~[na:8.0 build_20160616]
at com.ibm.jsse2.as.b(as.java:806) ~[na:8.0 build_20160616]
at com.ibm.jsse2.as.a(as.java:102) ~[na:8.0 build_20160616]
at com.ibm.jsse2.as.i(as.java:969) ~[na:8.0 build_20160616]
at com.ibm.jsse2.as.a(as.java:680) ~[na:8.0 build_20160616]
at com.ibm.jsse2.as.startHandshake(as.java:859) ~[na:8.0 build_20160616]
at org.apache.http.conn.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:396) ~[httpclient-4.5.6.jar:4.5.6]
at org.apache.http.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:355) ~[httpclient-4.5.6.jar:4.5.6]
at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:142) ~[httpclient-4.5.6.jar:4.5.6]

Hi @springcloud963,

Thanks for being here! Could you try adding Dhttps.protocols=TLSv1.1,TLSv1.2 to your eclipse.ini file?

As you’ll notice, your topic is now here in the Project Development Help and Advice board. No action is needed on your part; you can continue the conversation as normal here.

Cheers!

Andrea

Hi AndreaGriffiths11,

The issue got resolved by using jdk 1.8. Previously i was using IBM jdk 1.8 and it was not working. I  am not sure how it will work with IBM jdk.

Thanks,