cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-tracker Archives

[ curl-Bugs-3564730 ] SSL handshake sometimes falls in Release

From: SourceForge.net <noreply_at_sourceforge.net>
Date: Thu, 06 Sep 2012 10:49:49 -0700

Bugs item #3564730, was opened at 2012-09-04 08:12
Message generated for change (Comment added) made by bagder
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=100976&aid=3564730&group_id=976

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: SSL/TLS
Group: None
Status: Open
>Resolution: Works For Me
Priority: 5
Private: No
Submitted By: Aryeh Trainin (aryeht)
Assigned to: Daniel Stenberg (bagder)
Summary: SSL handshake sometimes falls in Release

Initial Comment:
I use libcurl 7.25.0 on Windows 7 with SSL support (SSL version: 1.0.1b), as a DLL.
All libcurl calls are in a single DLL that implements communication with a 3rd party device via HTTPS.
The SSL handshake is roughly as follows:

CURL* m_pCurlInstance = curl_easy_init();
struct curl_httppost *post_first = NULL, *post_last = NULL;
CURLcode cc = curl_easy_setopt(m_pCurlInstance, CURLOPT_SSL_VERIFYPEER, 0);
sprintf_s(sWR, "https://%s\n", szAddress); // certain address
cc = curl_easy_setopt(m_pCurlInstance, CURLOPT_URL, sWR);
CURLFORMcode cfc = curl_formadd(&post_first, &post_last, CURLFORM_COPYNAME, "password-input", CURLFORM_COPYCONTENTS, "password", CURLFORM_END);
cc = curl_easy_perform(m_pCurlInstance);

Normally, this works good, except a certain application on a certain PC in Release configuration. The call of curl_easy_perform() produces Error 35 there, and the error buffer is, merely, "SSL connect error".
The same application runs well in the same environment in Debug, as well as on another PC in Release; also, another application that uses the same DLL in a similar way runs in Release on the same PC without any problem.

I've managed to cope with this issue when I built the libcurl DLL with debug info (that is, in the "DLL Release" configuration of vc6libcurl project I added /Zi and /DEBUG keys).
Please comment on this issue. I'm not sure that the above solution is generic and reliable.

----------------------------------------------------------------------

>Comment By: Daniel Stenberg (bagder)
Date: 2012-09-06 10:49

Message:
I don't see how libcurl would work any differently depending on "debug" or
"release" builds. I would guess the problem is rather something in your
application's code that isn't done properly and thus through some chance
works in debug.

If you believe this is a libcurl bug, then please present us a small and
complete stand-alone source code we can build and run to see the problem.

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=100976&aid=3564730&group_id=976
Received on 2012-09-06

These mail archives are generated by hypermail.

donate! Page updated January 05, 2012.
web site info

File upload with ASP.NET