Security

SDK JAVA Connection issues -- unable to find valid certification path to requested target

dshah2
Engager
// Log in using a basic authorization header
        // Note: Do not call the Service.login method
        Service service = new Service("xyz.xyz.xyz.xyz", 8089);
        String credentials = "username:password";
        String basicAuthHeader = Base64.encode(credentials.getBytes());
        service.setToken("Basic " + basicAuthHeader);
        // Print the session token
        System.out.println("Your session token: " + service.getToken());

Getting exception this LINE
// Create the job
InputStream exportStream = service.export(mySearch, jobArgs);

java.lang.RuntimeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at com.splunk.HttpService.send(HttpService.java:326)
at com.splunk.Service.send(Service.java:1211)
at com.splunk.HttpService.get(HttpService.java:130)
at com.splunk.Service.export(Service.java:196)
at com.splunk.Service.export(Service.java:211)
at

emobr01
Engager

2 years, over 1,000 views and no answer??? Nice work Splunk....

teresa1688
Explorer

Please shed the light if you know how to resolve this. I am seeing the same error. The code worked locally but failed when deploy the connection client to weblogic server 12c.

0 Karma

sp04355
New Member

I have the same issue right now, it stops me from feather development and buying the product.

0 Karma
Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...