cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: SSL Certificate Verification

From: White, Gary [IT] <gary.white_at_citigroup.com>
Date: Tue, 14 Oct 2003 11:59:33 +0100

Hi,

Thanks for the help. However, still no luck. Exactly the same error. I think
the problem lies in that I dont fully understand what I need to do in order
to verify the servers certificate. As far as I understand you need to set

curl_easy_setopt(curl,CURLOPT_CAINFO,pCACertFile);

to something or other in order for this to work properly(correct?). My
question is what.

I dont understand the logic behind setting

curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, FALSE);

either and how this could help the situation. Any further advise would be
much appreciated.

All the best.

Gary

-----Original Message-----
From: Henrik Storner [mailto:henrik-curl_at_hswn.dk]
Sent: 13 October 2003 22:31
To: curl-library_at_lists.sourceforge.net
Subject: Re: SSL Certificate Verification

On Mon, Oct 13, 2003 at 06:14:59PM +0100, White, Gary [IT] wrote:

> I have succeeded in connecting to the server and perform my functionality
with
> verifypeer set to false.
>
> curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, FALSE);
>
> However, when I set it to true I get the error
>
> * SSL certificate problem, verify that the CA cert is OK

Add a

  curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, FALSE);

right after the VERIFYPEER setting, and it should work.

-- 
Henrik Storner <henrik_at_hswn.dk> 
-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
Received on 2003-10-14