Splunk Enterprise

SSL Certificate issue

AntonyPriwin
Explorer

Hi 

We have a situation, while trying to post a request to a external api from java script, we are getting timeout error.  

While trying to hit the same url through curl we are getting the below ssl cert error. 

"curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: https://curl.haxx.se/docs/sslcerts.html

curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and
how to fix it, please visit the web page mentioned above. "

I have attached the error snip and the related JS here.

JS snippet:

const userAction = async (pid) => {
const url='https://xyz.com:443/PID?ppid='+pid;
const response = await fetch(url,{ method: 'POST',mode: 'cors'})
.then(response => console.log(response))
.then(xmlString => console.log($.parseXML(xmlString)) )
.catch(error => console.log(error))

has anyone come across the above issue, any help is appreciated 

Thanks.

Labels (3)
Tags (2)
0 Karma

isoutamo
SplunkTrust
SplunkTrust

Hi

you are probably using your own certificates or splunk's generated (without any intermediate certs). Then your client code is expecting that CA which has signed that code must be trusted.

You could test this with curl -v https://zyx.... vs. curl -vk https://xyz.... The first own told that it cannot verify certificate and second one works.

There are two options for you.

  1. Switch to official certificates on splunk side or if you have VIP before it then you can add it there.
  2. Add to your code parameters which don't require that CA is known (less secure option)
  3. If you are using private certs then add your CA as trusted for your "code"/system

r. Ismo

AntonyPriwin
Explorer

Hi, 

Added intermediate cert but getting below error

 

 curl: (35) OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to xyz.com:443 

 

Thanks in advance 

0 Karma

Gr0und_Z3r0
Contributor

Has the instance being whitelisted to allow traffic from your Splunk instance or from where the request is generated /triggered? 

0 Karma
Get Updates on the Splunk Community!

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...