> Twisted normally wants to do all the low level network operations, like
> sending and reading through sockets. But it also has a wrapping
> interface that allows me to hook my stuff in. I can successfully make an
> SSL handshake and have my client send data to the server through
> M2Crypto (OpenSSL).

        Google for information about 'bio pairs' and look at the exmaple code. A
socket BIO won't work for what you're doing.

        With bio pairs, your code does four things:

        1) When data is received from the socket, you give the encrypted it to
OpenSSL.

        2) When OpenSSL wants to send encrypted data, you send it over the 
socket.

        3) When your application wants to send data, you give the decrypted 
data to
OpenSSL.

        4) When OpenSSL has decrypted data to give your application, you get it
from OpenSSL and pass it on.

        So long as you think of these four things as independent and don't 
assume
that data received over the socket will result in application data, you'll
be fine.

        DS


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

Reply via email to