[Cryptography-dev] pyOpenSSL: non-blocking socket support

Nikolaus Rath Nikolaus at rath.org
Tue Jun 28 12:50:09 EDT 2016


On Jun 27 2016, Glyph <glyph-wgPraSjSqjuEakHPNWoOSQC/G2K4zDHf at public.gmane.org> wrote:
>> On Jun 27, 2016, at 22:23, Vladimir Didenko <vladimir.didenko-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org> wrote:
>> 
>> 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!).
>
> The better way to use pyOpenSSL (and more recent stdlib ssl modules)
> is to use Memory BIOs, though.  Twisted migrated many years back from
> letting OpenSSL do the socket I/O to doing the socket I/O itself and
> the result has been much more portable, testable, and reliable.

Hum. When using BIOs, does this mean that I can safely refill/read-out
the BIO when getting SSLWantRead/SSLWantRead and then call the SSL
function again, or do I need to keep track of the detailed io state
again?

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.«


More information about the Cryptography-dev mailing list