RE: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-05-02 Thread John Unsworth
Caswell Sent: 01 May 2019 08:42 To: openssl-users@openssl.org Subject: Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN CAUTION: This email originated from outside of Synchronoss. On 30/04/2019 23:37, Viktor Dukhovni wrote: > On Tue, Apr 30, 2019 at 03:23:23PM -0700, Erik Forsberg wr

Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-05-02 Thread Matt Caswell
On 30/04/2019 23:37, Viktor Dukhovni wrote: > On Tue, Apr 30, 2019 at 03:23:23PM -0700, Erik Forsberg wrote: > >>> Is the handshake explicit, or does the application just call >>> SSL_read(), with OpenSSL performing the handshake as needed? >> >> I occasionally (somewhat rarely) see the issue

Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-04-30 Thread Erik Forsberg
>-- Original Message -- > > >>-- Original Message -- >> >>On Tue, Apr 30, 2019 at 03:23:23PM -0700, Erik Forsberg wrote: >> >>> >Is the handshake explicit, or does the application just call >>> >SSL_read(), with OpenSSL performing the handshake as needed? >>> >>> I occasionally (somewhat

Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-04-30 Thread Erik Forsberg
>-- Original Message -- > >On Tue, Apr 30, 2019 at 03:23:23PM -0700, Erik Forsberg wrote: > >> >Is the handshake explicit, or does the application just call >> >SSL_read(), with OpenSSL performing the handshake as needed? >> >> I occasionally (somewhat rarely) see the issue mentioned by the OP.

Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-04-30 Thread Viktor Dukhovni
On Tue, Apr 30, 2019 at 03:23:23PM -0700, Erik Forsberg wrote: > >Is the handshake explicit, or does the application just call > >SSL_read(), with OpenSSL performing the handshake as needed? > > I occasionally (somewhat rarely) see the issue mentioned by the OP. > Ignoring the error, or mapping

Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-04-30 Thread Erik Forsberg
I can add some of my own observations to this below ... >> I haven't looked at the code, but my impression is that WANT_READ and >> WANT_WRITE are returned in two cases: when OpenSSL has received or sent a >> partial record and needs to complete it; or when the TLS state is such that >>

Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-04-30 Thread Viktor Dukhovni
> On Apr 30, 2019, at 12:31 PM, Michael Wojcik > wrote: > > I haven't seen a reply to this, so I'll take a stab... > > I haven't looked at the code, but my impression is that WANT_READ and > WANT_WRITE are returned in two cases: when OpenSSL has received or sent a > partial record and needs

Re: SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-04-30 Thread Michael Wojcik
> From: openssl-users on behalf of John > Unsworth > Sent: Monday, April 29, 2019 10:54 > We are using OpenSSL 1.1.0h on Linux to send operations to LDAP servers. We > use SSL_read() > to receive the replies on a non-blocking socket. The vast majority of times > SSL_read() returns >0, >

SSL_read() returning SSL_ERROR_SYSCALL with errno 11EAGAIN

2019-04-29 Thread John Unsworth
We are using OpenSSL 1.1.0h on Linux to send operations to LDAP servers. We use SSL_read() to receive the replies on a non-blocking socket. The vast majority of times SSL_read() returns >0, SSL_ERROR_WANT_READ or SSL_ERROR_WANT_WRITE as per the spec. However we are very occasionally seeing