On Jun 28 2016, Vladimir Didenko <vladimir.didenko-re5jqeeqqe8avxtiumw...@public.gmane.org> wrote: > 2016-06-28 2:07 GMT+03:00 Nikolaus Rath > <nikolaus-bth8mxji...@public.gmane.org>: > >> Hello, >> >> IIAC, when using the standard library's ssl module, the following can >> happen (distilled from http://bugs.python.org/issue22499): >> > > I read this issue and it looks like I misunderstood you question. > > >> If I understand correctly, this is because the ssl module does not >> actually implement the 'struct iostate' state machinery required by >> OpenSSL and instead just blindly raises SSLWantRead/SSLWantWrite. > > And it shouldn't implement it. It is task for user to handle IO state.
Is there a reason not to implement it in the pyOpenSSL layer, though? >> Can someone tell me how pyOpenSSL supports non-blocking socket? Does it >> also require the caller to maintain struct iostate, or does it allow to >> work with just SSLWantRead/Write and select()? > > Doesn't differ from standard ssl module. > > Resume: you can use nonblocking ssl socket with standard ssl module and > PyOpenSSL. Though it requires some work from you (but it is not hard!). I don't understand why everyone using it would have to re-implement the same functionality. Would you be interested in a patch that adds this to pyOpenSSL? Best, -Nikolaus -- GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F »Time flies like an arrow, fruit flies like a Banana.« _______________________________________________ Cryptography-dev mailing list Cryptography-dev@python.org https://mail.python.org/mailman/listinfo/cryptography-dev