<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic CURL error 60 -  server certificate verification failed. CAfile: certificates/cert.pem CRLfile: none in Integration and Testing</title>
    <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/CURL-error-60-server-certificate-verification-failed-CAfile/m-p/66145#M39725</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to make a dummy transaction through CURL using Sandbox account &amp;amp; the latest cacert.pem file as provided at this path -&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/AuthorizeNet/sdk-php/blob/master/lib/ssl/cert.pem" target="_blank"&gt;https://github.com/AuthorizeNet/sdk-php/blob/master/lib/ssl/cert.pem&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The command I'm using is -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;sudo curl --cacert ./certificates/cacert.pem -d"x_login=&amp;lt;API_ID&amp;gt;&amp;amp;x_tran_key=&amp;lt;TRANSACTION_KEY&amp;gt;&amp;amp;x_delim_data=TRUE&amp;amp;x_url=FALSE&amp;amp;x_type=AUTH_CAPTURE&amp;amp;x_method=CC&amp;amp;x_relay_response=FALSE&amp;amp;x_card_num=4111111111111111&amp;amp;x_exp_date=05/2019&amp;amp;x_amount=100.00&amp;amp;x_address=&amp;amp;x_zip=&amp;amp;x_card_code=777" "&lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I get this error -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;curl: (60) server certificate verification failed. CAfile: ./certificates/cert.pem CRLfile: none&lt;BR /&gt;More details here: &lt;A href="http://curl.haxx.se/docs/sslcerts.html" target="_blank"&gt;http://curl.haxx.se/docs/sslcerts.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;curl performs SSL certificate verification by default, using a "bundle"&lt;BR /&gt;&amp;nbsp;of Certificate Authority (CA) public keys (CA certs). If the default&lt;BR /&gt;&amp;nbsp;bundle file isn't adequate, you can specify an alternate file&lt;BR /&gt;&amp;nbsp;using the --cacert option.&lt;BR /&gt;If this HTTPS server uses a certificate signed by a CA represented in&lt;BR /&gt;&amp;nbsp;the bundle, the certificate verification probably failed due to a&lt;BR /&gt;&amp;nbsp;problem with the certificate (it might be expired, or the name might&lt;BR /&gt;&amp;nbsp;not match the domain name in the URL).&lt;BR /&gt;If you'd like to turn off curl's verification of the certificate, use&lt;BR /&gt;&amp;nbsp;the -k (or --insecure) option.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I use the -k or --insecure option which skips the certificate validation, the transaction is approved as follows -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sudo curl --insecure --cacert ./certificates/cert.pem -d"x_login=&amp;lt;API_ID&amp;gt;&amp;amp;x_tran_key=&amp;lt;TRANSACTION_KEY&amp;gt;&amp;amp;x_delim_data=TRUE&amp;amp;x_url=FALSE&amp;amp;x_type=AUTH_CAPTURE&amp;amp;x_method=CC&amp;amp;x_relay_response=FALSE&amp;amp;x_card_num=4111111111111111&amp;amp;x_exp_date=05/2019&amp;amp;x_amount=100.00&amp;amp;x_address=&amp;amp;x_zip=&amp;amp;x_card_code=777" "&lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;"&lt;BR /&gt;1,1,1,This transaction has been approved.,4BSLRJ,Y,60115870054,,,100.00,CC,auth_capture,,,,,,,,,,,,,,,,,,,,,,,,,,560D4634C183897AFBA9AECCBB7D7A05,P,2,,,,,,,,,,,XXXX1111,Visa,,,,,,,,,,,,,,,,,FALSE,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone help me regarding this? Why the certification validation is failing here? Also, is this the right way to test it?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We want to integrate this certificate in our HPE MSM controller where we give the URL - &lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt; and the API_ID &amp;amp; Transaction_Key. In the code for the software of HPE MSM controller, we're using CURL to reach the URL for certificate validation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Simran&lt;/P&gt;</description>
    <pubDate>Tue, 29 Jan 2019 06:45:07 GMT</pubDate>
    <dc:creator>sdsingh1989</dc:creator>
    <dc:date>2019-01-29T06:45:07Z</dc:date>
    <item>
      <title>CURL error 60 -  server certificate verification failed. CAfile: certificates/cert.pem CRLfile: none</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/CURL-error-60-server-certificate-verification-failed-CAfile/m-p/66145#M39725</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to make a dummy transaction through CURL using Sandbox account &amp;amp; the latest cacert.pem file as provided at this path -&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/AuthorizeNet/sdk-php/blob/master/lib/ssl/cert.pem" target="_blank"&gt;https://github.com/AuthorizeNet/sdk-php/blob/master/lib/ssl/cert.pem&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The command I'm using is -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;sudo curl --cacert ./certificates/cacert.pem -d"x_login=&amp;lt;API_ID&amp;gt;&amp;amp;x_tran_key=&amp;lt;TRANSACTION_KEY&amp;gt;&amp;amp;x_delim_data=TRUE&amp;amp;x_url=FALSE&amp;amp;x_type=AUTH_CAPTURE&amp;amp;x_method=CC&amp;amp;x_relay_response=FALSE&amp;amp;x_card_num=4111111111111111&amp;amp;x_exp_date=05/2019&amp;amp;x_amount=100.00&amp;amp;x_address=&amp;amp;x_zip=&amp;amp;x_card_code=777" "&lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I get this error -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;curl: (60) server certificate verification failed. CAfile: ./certificates/cert.pem CRLfile: none&lt;BR /&gt;More details here: &lt;A href="http://curl.haxx.se/docs/sslcerts.html" target="_blank"&gt;http://curl.haxx.se/docs/sslcerts.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;curl performs SSL certificate verification by default, using a "bundle"&lt;BR /&gt;&amp;nbsp;of Certificate Authority (CA) public keys (CA certs). If the default&lt;BR /&gt;&amp;nbsp;bundle file isn't adequate, you can specify an alternate file&lt;BR /&gt;&amp;nbsp;using the --cacert option.&lt;BR /&gt;If this HTTPS server uses a certificate signed by a CA represented in&lt;BR /&gt;&amp;nbsp;the bundle, the certificate verification probably failed due to a&lt;BR /&gt;&amp;nbsp;problem with the certificate (it might be expired, or the name might&lt;BR /&gt;&amp;nbsp;not match the domain name in the URL).&lt;BR /&gt;If you'd like to turn off curl's verification of the certificate, use&lt;BR /&gt;&amp;nbsp;the -k (or --insecure) option.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I use the -k or --insecure option which skips the certificate validation, the transaction is approved as follows -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sudo curl --insecure --cacert ./certificates/cert.pem -d"x_login=&amp;lt;API_ID&amp;gt;&amp;amp;x_tran_key=&amp;lt;TRANSACTION_KEY&amp;gt;&amp;amp;x_delim_data=TRUE&amp;amp;x_url=FALSE&amp;amp;x_type=AUTH_CAPTURE&amp;amp;x_method=CC&amp;amp;x_relay_response=FALSE&amp;amp;x_card_num=4111111111111111&amp;amp;x_exp_date=05/2019&amp;amp;x_amount=100.00&amp;amp;x_address=&amp;amp;x_zip=&amp;amp;x_card_code=777" "&lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;"&lt;BR /&gt;1,1,1,This transaction has been approved.,4BSLRJ,Y,60115870054,,,100.00,CC,auth_capture,,,,,,,,,,,,,,,,,,,,,,,,,,560D4634C183897AFBA9AECCBB7D7A05,P,2,,,,,,,,,,,XXXX1111,Visa,,,,,,,,,,,,,,,,,FALSE,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone help me regarding this? Why the certification validation is failing here? Also, is this the right way to test it?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We want to integrate this certificate in our HPE MSM controller where we give the URL - &lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt; and the API_ID &amp;amp; Transaction_Key. In the code for the software of HPE MSM controller, we're using CURL to reach the URL for certificate validation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Simran&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jan 2019 06:45:07 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/CURL-error-60-server-certificate-verification-failed-CAfile/m-p/66145#M39725</guid>
      <dc:creator>sdsingh1989</dc:creator>
      <dc:date>2019-01-29T06:45:07Z</dc:date>
    </item>
  </channel>
</rss>

