Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-31 Thread Pau Rodriguez-Estivill
Yes I'm using Debian GNU/Linux, using last OpenSSL from the web page but I didn't compiled it with any debug flag. Using my program doesn't apear any output to strerr other than the traces I print to debug my program. So I suppouse that DTLS code didn't find the situation as unexpected. :( Thanks.

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-31 Thread Kyle Hamilton
The DTLS code has several areas that do an fprintf to stderr in the case of unexpected situations. If you're closing or redirecting file descriptor 2, it'll prevent you from seeing any of that output. You're running under Linux? -Kyle H On Sun, Aug 31, 2008 at 6:37 AM, Pau Rodriguez-Estivill <[

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-31 Thread Pau Rodriguez-Estivill
I have tested my program replacing SSL_write with sendto and SSL_read with memcpy. So it didn't appear to be my fault. On Sun, Aug 31, 2008 at 3:10 PM, Kyle Hamilton <[EMAIL PROTECTED]> wrote: > Is there any output printed on stderr of either side of the connection? > > -Kyle H > I don't really u

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-31 Thread Kyle Hamilton
Is there any output printed on stderr of either side of the connection? -Kyle H On Sun, Aug 31, 2008 at 6:02 AM, Pau Rodriguez-Estivill <[EMAIL PROTECTED]> wrote: > I already tested with last version and I have the same results: > Here the versions used and the build options: > > OpenSSL 0.9.8h 2

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-31 Thread Pau Rodriguez-Estivill
I already tested with last version and I have the same results: Here the versions used and the build options: OpenSSL 0.9.8h 28 May 2008 built on: Sun Aug 31 13:56:12 CEST 2008 platform: linux-x86_64 options: bn(64,64) md2(int) rc4(8x,int) des(idx,cisc,16,int) idea(int) blowfish(ptr2) compiler: g

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-31 Thread Pau Rodriguez-Estivill
OpenSSL 0.9.8g 19 Oct 2007 And also isn't de official, is the Debian build. So I'm also going to try last version, you recomend 0.9.8h or last snapshot? Thanks. Pau On Sun, Aug 31, 2008 at 10:16 AM, Kyle Hamilton <[EMAIL PROTECTED]> wrote: > Specifically which version of the openssl library are

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-31 Thread Kyle Hamilton
Specifically which version of the openssl library are you using? I'm going to try to dig into this. -Kyle H On Sat, Aug 30, 2008 at 9:45 AM, Pau Rodriguez-Estivill <[EMAIL PROTECTED]> wrote: > Hi! > I have done more tests of this strange data blocks: > I send 2 kinds of blocks one of 1500 bytes

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-30 Thread Pau Rodriguez-Estivill
Hi! I have done more tests of this strange data blocks: I send 2 kinds of blocks one of 1500 bytes (block A) and another of 48bytes (block B). A blocks have an identifier. The normal way is receive first 1500bytes of A and then 48 of B: 1: (id 515) 2: B But this i

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-29 Thread Pau Rodriguez Estivill
I always try to do an SSL_read every time I give a new packet to OpenSSL library, It's true that I only try it once per packet I give. Maybe I should try SSL_pending after this read, to ensure that aren't more data. Normally SSL_pending return 0, even before trying to read. When I call to SSL_rea

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-29 Thread Pau Rodriguez Estivill
This license is only for binary distribution, and not for my source distribution, I suppose. On Sat, Aug 30, 2008 at 1:01 AM, Kyle Hamilton <[EMAIL PROTECTED]> wrote: > Also, regarding the googlecode home page for your project: you need to > also explicitly mention the people who wrote SSLeay (fro

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-29 Thread Kyle Hamilton
Also, regarding the googlecode home page for your project: you need to also explicitly mention the people who wrote SSLeay (from which OpenSSL is derived), not just the OpenSSL project. The details are in the LICENSE file in the OpenSSL package. :) "This product includes software developed by the

Re: VPN DTLS SSL_WANT_READ and strange data results.

2008-08-29 Thread Kyle Hamilton
If SSL_read or SSL_write return SSL_WANT_READ or SSL_WANT_WRITE, just at some point call them again. It means either that insufficient data has actually come in to decrypt the next SSL packet, or that there's a request for a renegotiation, or whathaveyou. The SSL_read and SSL_write functions will

VPN DTLS SSL_WANT_READ and strange data results.

2008-08-29 Thread Pau Rodriguez Estivill
Hi, I'm using OpenSSL to create a VPN software based on the DTLS implementation of it. The source is available here: http://vpmn.googlecode.com/svn/trunk/src/ My application is currently using pthreads and I use a mutex for every SSL object, locking it before every SSL_* function call. There are