Security

How to connect the splunk server using java-sdk? i got the "ssl error" when i connect the server like the example that the api gave.

yizezhong
New Member

Exception in thread "main" java.lang.RuntimeException: No appropriate protocol (protocol is disabled or cipher suites are inappropriate)
at com.splunk.HttpService.send(HttpService.java:371)
at com.splunk.Service.send(Service.java:1280)
at com.splunk.HttpService.post(HttpService.java:272)
at com.splunk.Service.login(Service.java:1111)
at com.splunk.Service.login(Service.java:1091)
at com.splunk.Service.connect(Service.java:185)
at com.chinamoney.splunk.test.SplunkLinkDemo.main(SplunkLinkDemo.java:29)
Caused by: javax.net.ssl.SSLHandshakeException: No appropriate protocol (protocol is disabled or cipher suites are inappropriate)
at sun.security.ssl.Handshaker.activate(Unknown Source)
at sun.security.ssl.SSLSocketImpl.kickstartHandshake(Unknown Source)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(Unknown Source)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getOutputStream(Unknown Source)
at com.splunk.HttpService.send(HttpService.java:365)
... 6 more

Tags (3)
0 Karma

Damien_Dallimor
Ultra Champion

I suggest you update your Splunk Java SDK to the latest release that has support for TLS. (SSL is now disabled by default in the JRE)

0 Karma

acharlieh
Influencer

Are you using Java 8? If so, this seems to be a duplicate question of: http://answers.splunk.com/answers/209379/no-appropriate-protocol-protocol-is-disabled-or-ci.html

0 Karma
Get Updates on the Splunk Community!

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...