Paul Menzel | 21 Dec 2011 18:02

SSL read errno 10054

Hi,

I'm a newbie trying consume a web service using PHP & curl.

The PHP is executed on a Windows 2003 server with curl version 7.20.0 installed.

This error message follows the GET:  

        SSL read: error:00000000:lib(0):func(0):reason(0), errno 10054 

Any help resolving this error is much appreciated.

Paul Menzel

 
* About to connect() to some.edu port 443 (#0) 
* Trying xxx.xxx.xxx.xxx… 
* connected * Connected to some.edu (xxx.xxx.xxx.xxx) port 443 (#0) 
* successfully set certificate verify locations: 
* CAfile: C:\somedir\some.crt  CApath: none 
* SSL connection using AES128-SHA 
* Server certificate: 
* subject: C=US; ST=somestate; L=somecity; O=somecollege; OU=GSchool; CN=some.edu 
* start date: 2011-07-18 00:00:00 GMT * expire date: 2014-07-22 12:00:00 GMT * subjectAltName: some.edu
matched 
* issuer: C=US; O=DigiCert Inc; OU=www.digicert.com; CN=DigiCert High Assurance CA-3 
* SSL certificate verify ok.
 > GET /gd_appl/1.0/DEPT HTTP/1.1 User-Agent: PHP Sample Rest Client Host: some.edu Accept: */* 

* SSL read: error:00000000:lib(0):func(0):reason(0), errno 10054 
(Continue reading)

David Colter | 21 Dec 2011 20:15
Picon
Favicon

Re: SSL read errno 10054

Paul,

CAfile: C:\somedir\some.crt  CApath: none

That line looks a little fishy. 

David
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Paul Menzel | 21 Dec 2011 22:00

Re: SSL read errno 10054

Hi,

I'm a newbie trying consume a web service using PHP & curl.

The PHP is executed on a Windows 2003 server with curl version 7.20.0 installed.

This error message follows the GET:  

       SSL read: error:00000000:lib(0):func(0):reason(0), errno 10054 

Any help resolving this error is much appreciated.

Paul Menzel

* About to connect() to some.edu port 443 (#0) 
* Trying xxx.xxx.xxx.xxx… 
* connected * Connected to some.edu (xxx.xxx.xxx.xxx) port 443 (#0) 
* successfully set certificate verify locations: 
* CAfile: C:\somedir\some.crt  CApath: none 
* SSL connection using AES128-SHA 
* Server certificate: 
* subject: C=US; ST=somestate; L=somecity; O=somecollege; OU=GSchool; CN=some.edu 
* start date: 2011-07-18 00:00:00 GMT * expire date: 2014-07-22 12:00:00 GMT * subjectAltName: some.edu
matched 
* issuer: C=US; O=DigiCert Inc; OU=www.digicert.com; CN=DigiCert High Assurance CA-3 
* SSL certificate verify ok.
> GET /gd_appl/1.0/DEPT HTTP/1.1 User-Agent: PHP Sample Rest Client Host: some.edu Accept: */* 

* SSL read: error:00000000:lib(0):func(0):reason(0), errno 10054 

* Empty reply from server 
* Connection #0 to host some.edu left intact 
* Closing connection #0

On Dec 21, 2011, at 11:15 AM, David Colter wrote:

> Paul,
> 
>> CAfile: C:\somedir\some.crt  CApath: none
> 
> That line looks a little fishy. 
> 
> David
> _______________________________________________
> http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php

David --

somedir and some.crt are substitutes for the actual directory and file -- I was trying to obscure some of our identity.

The actual option statement I use is:

      curl_setopt($c, CURLOPT_CAINFO, "C:\cert\ca_bundle.crt");

Adding this CURLOPT_CAINFO got rid of an earlier error message reading:

       SSL certificate verify result: unable to get local issuer certificate (20), continuing anyway. 

Am afraid I'm still stuck with the SSL read error.

Paul 

_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php

David Colter | 22 Dec 2011 16:42
Picon
Favicon

Re: SSL read errno 10054

Paul,

somedir and some.crt are substitutes for the actual directory and file -- I was trying to obscure some of our identity.

The actual option statement I use is:

     curl_setopt($c, CURLOPT_CAINFO, "C:\cert\ca_bundle.crt");

Adding this CURLOPT_CAINFO got rid of an earlier error message reading:

      SSL certificate verify result: unable to get local issuer certificate (20), continuing anyway. 


Am afraid I'm still stuck with the SSL read error.

Can you post your code? That will help us narrow down the source of your error.

Also, that cert file should contain a large number of certificate keys. It is possible that either the target sites SSL isn't present. Also, as a new cURL user, I religiously compare the output you've received (and included in earlier post) with the output of the headers received in a browser through Developer tools or Live HTTP Headers.

David
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php

Gmane