RE: Multi-threaded SSL Socket Usage

2007-05-23 Thread Dinh, Thao V CIV NSWCDD, K72
Armstrong Sent: Tuesday, May 15, 2007 6:18 To: openssl-users@openssl.org Subject: Multi-threaded SSL Socket Usage Hi Everyone, I hope I have found the right place to ask for some advice. An application we have developed is responsible for handling concurrent connections from multiple SSL Sockets

RE: Multi-threaded SSL Socket Usage

2007-05-18 Thread David Schwartz
// Receiving WANT_READ during an SSL_write bool writeSuccess = false; while (!writeSuccess) { ret = SSL_write(...) if (ssl_Error(ret) == SSL_ERROR_WANT_WRITE) { // Wants a write, just re-try the operation. Continue; } Why are you retrying

FW: Multi-threaded SSL Socket Usage

2007-05-17 Thread Andrew Armstrong
Resend; it's been a few hours and my reply below has yet to come through. - Andrew -Original Message- From: Andrew Armstrong [mailto:[EMAIL PROTECTED] Sent: Thursday, 17 May 2007 6:49 PM To: 'openssl-users@openssl.org' Subject: RE: Multi-threaded SSL Socket Usage Thanks for your

RE: Multi-threaded SSL Socket Usage

2007-05-17 Thread Andrew Armstrong
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andrew Armstrong Sent: Thursday, 17 May 2007 8:13 PM To: openssl-users@openssl.org Subject: FW: Multi-threaded SSL Socket Usage Resend; it's been a few hours and my reply below has yet to come through. - Andrew

RE: Multi-threaded SSL Socket Usage

2007-05-17 Thread Andrew Armstrong
Subject: RE: Multi-threaded SSL Socket Usage The design of the application is that there are worker threads which pick up data and send them out via the sockets. This works for the most part, however as mentioned it will sometimes no longer appear to work (data is not received in a timely

RE: Multi-threaded SSL Socket Usage

2007-05-17 Thread David Schwartz
Thanks for your response David, Rodney. I understand (clearer now) the requirement that: * If SSL_read reports WANT_WRITE; we need to issue an immediate SSL_write However; what do I actually write? Do I write a blank/empty string (SSL_write(ssl, , 0)?) - I may not have anything to write.

Multi-threaded SSL Socket Usage

2007-05-15 Thread Andrew Armstrong
Hi Everyone, I hope I have found the right place to ask for some advice. An application we have developed is responsible for handling concurrent connections from multiple SSL Sockets. While the application works fine for a while; there will sometimes be an issue where a socket blocked on

Re: Multi-threaded SSL Socket Usage

2007-05-15 Thread Rodney Thayer
Andrew Armstrong wrote: Is there anyone out there with experience in using OpenSSL in a multi-threaded application that can provide some sample code or anything to help address these issues? I vaguely recall the last time I did this that OpenSSL made no claim of thread safety and you had to

RE: Multi-threaded SSL Socket Usage

2007-05-15 Thread David Schwartz
The design of the application is that there are worker threads which pick up data and send them out via the sockets. This works for the most part, however as mentioned it will sometimes no longer appear to work (data is not received in a timely fashion for example). I would think this is