cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: SSL certificate problem, verify that the CA cert is OK.

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 30 Jan 2008 12:36:03 +0100 (CET)

On Wed, 30 Jan 2008, data data wrote:

> I tried to use curl to connetc to a HTTPS paget. But I am getting the error
> result "SSL certificate problem, verify that the CA cert is OK." . I am sure
> that it something has to do with the passed curl options and my passed ssl
> certificate configuration/bundle.

Just a note here. This is the curl-users list, which covers the curl tool and
related subjects. There's a curl-and-php list that might be more suitable for
the PHP/CURL-specific parts.

> $curl->setOption(CURLOPT_SSL_VERIFYHOST, 0);
> $curl->setOption(CURLOPT_SSL_VERIFYPEER,false);
>
> $curl->setOption(CURLOPT_CAINFO,"C:/Programme/xampp/php/cert/cacert.pem");

If you don't verify the peer, there's really no point in providing a cacert
either...

> My configuration:
> - windows xp
> - xamp Version 1.5.5
> - PHP 5.2.0
> - OpenSSL 0.9.8d

You forgot the most important thing: what libcurl version? Also, do note that
your OpenSSL version is outdated and vulnerable.

What happens if you run "curl -k https://desperado:8009/shop/admin" on the
command line?

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2008-01-30