> 
> Hi,
> 
> I am reading across the network, using SSLeay-0.9.0.b, and have an
> intermittent problem - the sending socket is being closed, but this is
> not always being detected by the receiving SSL.  In particular,
> 
> SSL_read(ssl, buffer, length)
> 
> is returning zero rather than -1.
> 
> This seems to be a bug, possibly connected with non-blocking reads.  So
> is there a fix and/or can anyone describe how to do blocking reads (I
> have tried before, but couldn't make sense of the various brief messages
> from eay that were archived on the (old) newsgroup)?
> 
> Thanks,
> Andrew
> 
> 
> PS.  Further info:
> 
> BIO_eof(SSL_get_rbio(ssl)) is also returning zero
> 
> Looking at the windows docs, it seems that detection of socket closure
> on NT requires detecting:
> - select indicating that data is available to read
> - recv then returning 0
> for non-blocking reads.
> 

It would also be nice if SSL_pending() would return an error value 
when the connection is gone.


    Jeffrey Altman * Sr.Software Designer * Kermit-95 for Win32 and OS/2
                 The Kermit Project * Columbia University
              612 West 115th St #716 * New York, NY * 10025
  http://www.kermit-project.org/k95.html * [EMAIL PROTECTED]


______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to