Understanding SSL_read()/SSL_write()

2009-10-14 Thread Rij
ll have 30 + 40 = 70K of data. Will the SSL read pointer still be at the beginning, meaning the next 10 K to be delivered to the app is really data from the previous call? Regards, Rij __ OpenSSL Project

SSL_clear to reuse SSL session on client

2009-08-21 Thread Rij
(). When the next client comes in, it reuses the same SSL object. Does this mean that the session from the previous connection will also be reused? --Rij __ OpenSSL Project http://www.openssl.org

Verifying servers

2009-08-10 Thread Rij
Hello All, Do the following two perform the same job? 1) SSL_CTX_set_verify(ctx, SSL_VERIFY_PEER, NULL) 2) SSL_get_verify_result(ssl) -Rij __ OpenSSL Project http://www.openssl.org User Support

Non-technical question on entrepreneurship

2009-08-09 Thread Rij
r-specific information either which could be a way to reach out to individuals. Any thoughts/suggestions? -Rij __ OpenSSL Project http://www.openssl.org User Support Mailing List

Re: Non-blocking connect: Doesn't return immediately

2009-08-07 Thread Rij
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 Ma

Re: Non-blocking connect: Doesn't return immediately

2009-08-06 Thread Rij
> > Setting up an SSL connection requires some computationally intensive > operations using public key algorithms and some others involving the setup of > digests and ciphers. > Thanks Steve for your response. I realize that. But isn't the objective of using non-blocking soket/bio is so that the

Non-blocking connect: Doesn't return immediately

2009-08-05 Thread Rij
Hi All, I am opening a SSL connection from a client. The underlying socket and BIO are non-blocking. I am observing that SSL_connect is executing three times before it completes. While the first and the last call return almost immediately (less than 1 ms), the intermediate call takes 11 ms. Is thi

Re: SSL_connect on non blocking socket: Works but need better understanding

2009-08-04 Thread Rij
UT); break; case SSL_ERROR_WANT_READ: epoll_control(s_epfd, EPOLL_CTL_MOD, handle->sock, EPOLLIN); break; } return FALSE; } Any thoughts? -Rij _

Re: SSL_connect on non blocking socket: Works but need better understanding

2009-07-31 Thread Rij
> If you get SSL_ERROR_WANT_READ, you need to epoll/select for readability. If > you get SSL_ERROR_WANT_WRITE, you need to epoll/select for readability. > I am assuming the above was a typo and you meant writeability for SSL_ERROR_WRITE. Ok. That's interesting. I actually followed the concept from

SSL_connect on non blocking socket: Works but need better understanding

2009-07-31 Thread Rij
, much like blocking connect(). Is there a better way of writing the code? Thanks, Rij ssl = SSL_new(ctx); sbio = BIO_new_socket(sock, BIO_NOCLOSE); SSL_set_bio(ssl, sbio, sbio); connected = 0; while (1) { r_code = SSL_connect(ssl

Re: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol

2009-07-27 Thread Rij
Hi Dave, Thanks for your reply. I was able to fix it a while ago. And your guess is correct. My port number was getting messed up. And extra thinks for the tip on the libraries. :) On Mon, Jul 27, 2009 at 1:31 PM, Dave Thompson wrote: >> From: owner-openssl-us...@openssl.org On Behalf

error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol

2009-07-23 Thread Rij
Hello, I have a simple client operating in blocking mode. When I try to connect to the server, I get the error: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol Anybody aware of this error? I had previously written both a blocking and non-blocking client with help of people fro

Non-blocking connect: getsockopt fails

2009-07-16 Thread Rij
Hi All, I am trying to write a non-blocking client. Based on previous threads that I have read on this forum, I have adopted the following strategy. 1) Get a new BIO object. 2) I set the BIO to be non-blocking. As I understood from the manual, I set it to non-blocking just before calling BIO_do_c

Non-blocking read: Not reading entire data

2009-07-15 Thread Rij
Hello All, I had written a simple client earlier which did a blocking read and was able to retrieve the document from the server. Now, I am trying to rewrite the code to do non-blocking read. But only part of the data is showing. Can someone please show what's wrong? I am eliminating variable decl

Can I use self-signed client certificates to access ANY secure site?

2009-07-15 Thread Rij
Hi All, I am absolutely new to this world of SSL, as will be evident from my confusions and questions. I am trying to write a client that will securely connect to N web servers every T seconds, and retrieve a document: info.txt. To test it, I wrote the following code (borrowed from: http://www.i