Ok, I read the RFC and I believe I understand it now. During the 1st call to SSL_connect(), the client sends the Hello message. Takes very little time and SSL_connect() returns. When the server replies with the Hello message, the socket becomes readable. epoll returns and we call SSL_connect() the second time. During the second call, all the complex computations take place. As Kyle pointed out, OpenSSL being single-threaded, the computations proceed to completion. This is the time consuming step. Now the client sends its message to server. SSL_connect() returns. Finally, the server responds with its finished message. That's the 3rd call. And we're done after that.
Thanks for your help in my understanding. -Rij ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager majord...@openssl.org