Re: DTLS broken in CVS?

2010-09-16 Thread Daniel Mentz
12:13 PM, Daniel Mentz wrote: I can't get DTLS working with the current CVS version. When I run ./openssl s_client -dtls1 against ./openssl s_server -dtls1 I get 14710408:error:1408C06F:SSL routines:SSL3_GET_FINISHED:bad digest length:s3_both.c:264: on the server side. Is somebody worki

DTLS broken in CVS?

2010-09-16 Thread Daniel Mentz
I can't get DTLS working with the current CVS version. When I run ./openssl s_client -dtls1 against ./openssl s_server -dtls1 I get 14710408:error:1408C06F:SSL routines:SSL3_GET_FINISHED:bad digest length:s3_both.c:264: on the server side. Is somebody working on that? I should point out th

Re: [openssl.org #2230] Resolved: [PATCH] DTLS reassembly

2010-04-24 Thread Daniel Mentz via RT
Robin Seggelmann via RT wrote: > #define RSMBLY_BITMASK_IS_COMPLETE(bitmask, msg_len, is_complete) { \ > + if (is_complete) for (ii = (((msg_len) - 1) >> 3) - 1; > ii > 0 ; ii--) \ I'm wondering if there are two issues with this for loop: 1. It fails to check if bitmask[0]

Re: [openssl.org #2230] Resolved: [PATCH] DTLS reassembly

2010-04-24 Thread Daniel Mentz via RT
Robin Seggelmann via RT wrote: > + for (ii = (((start) >> 3) + 1); ii < (((end - > 1)) >> 3); ii++) bitmask[ii] = 0xff; \ I guess there's a minor mistake: I recommend to replace (((end - 1)) >> 3) with (((end) - 1) >> 3) -Daniel _

Re: [openssl.org #2223] [PATCH] DTLS timeout bug

2010-04-06 Thread Daniel Mentz
Robin Seggelmann via RT wrote: To handle handshake message timeouts properly, DTLS sets the socket timeouts according to the currently remaining time until the next timeout occurs. However, in some cases this doesn't work because the operating system returns the socket call a few milliseconds

[openssl.org #2221] [PATCH] DTLS Fragment reassembly

2010-04-06 Thread Daniel Mentz via RT
dtls1_process_out_of_seq_message() has two bugs: - Only one handshake message fragment per sequence number is saved. However, there may be multiple fragments with identical sequence numbers. All of them should be buffered. - Fragments with zero length are not saved. This is incorrect behavior

[openssl.org #2218] [Bug report] DTLS: dtls1_get_record() uses unauthenticated sequence number

2010-04-03 Thread Daniel Mentz via RT
d1_pkt.c:dtls1_get_record() processes DTLS records which it gets from the wire. At the same time, this function performs replay protection: It memorizes the (explicit) sequence numbers of the records and drops records that have already been processed. The sequence numbers of the processed recor

[openssl.org #2209] [PATCH] Error in man page BIO_should_retry(3)

2010-03-28 Thread Daniel Mentz via RT
I believe there's an error in man page BIO_should_retry(3). BIO_get_retry_reason() IMHO does NOT return a mask of the cause of a retry condition, but BIO_retry_type() does. Index: BIO_should_retry.pod === RCS file: /v/openssl/cvs/op

non-blocking i/o discipline in s_client

2009-08-31 Thread Daniel Mentz
I read Eric Rescorla's An Introduction to OpenSSL Programming (Part II) and learned about the i/o discipline you have to implement if you are using OpenSSL with non-blocking i/o. The paper talks about which file descriptors you have to include in your select() calls. Check out section "6 Mul

Re: [openssl.org #2006] [PATCH]: Do not use multiple DTLS records for a single user message

2009-08-13 Thread Daniel Mentz via RT
to the user. > So I changed that check to an assertion. An updated patch is > attached. > > Thanks for testing the patch. > > Best regards > Michael > > > > > On Aug 13, 2009, at 12:34 PM, Daniel Mentz wrote: > >> Michael Tuexen via RT wrote: >

Re: [openssl.org #2006] [PATCH]: Do not use multiple DTLS records for a single user message

2009-08-13 Thread Daniel Mentz
Michael Tuexen via RT wrote: the attached patch fixes a bug where a single user message was distributed over multiple DTLS records. Dear Michael, thanks for the patch. My app runs smoothly now. I'm wondering if we can get rid of the redundant if statement that checks if (len > SSL3_RT_MAX_PL

Re: DTLS: Fragmentation of user data due to PMTU limits makes no sense

2009-08-11 Thread Daniel Mentz
ysctl variable. More comments in-line. Best regards Michael On Aug 10, 2009, at 10:21 AM, Daniel Mentz wrote: In my understanding DTLS should provide UDP semantics when run over the later. That is if a user message is too large in terms of the PMTU it should either be silently discarded or the s

DTLS: Fragmentation of user data due to PMTU limits makes no sense

2009-08-10 Thread Daniel Mentz
In my understanding DTLS should provide UDP semantics when run over the later. That is if a user message is too large in terms of the PMTU it should either be silently discarded or the sender should be notified by an error message similar to "Message too big". In no event should the message be

Re: [openssl.org #1984] [PATCH]: DTLS: ssl3_read_n() concatenates UDP datagrams in DTLS case

2009-07-10 Thread Daniel Mentz
Dear Michael, I've got some concerns regarding your patch: Michael Tuexen via RT wrote: I have looked at the patch provided by Daniel. All suggested changes are OK, but there are two additional things which should be fixed: 1. In ssl3_read_n() the argument max is overwritten before used. I d

Re: [openssl.org #1984] [PATCH]: DTLS: ssl3_read_n() concatenates UDP datagrams in DTLS case

2009-07-10 Thread Daniel Mentz via RT
Dear Michael, I've got some concerns regarding your patch: Michael Tuexen via RT wrote: > I have looked at the patch provided by Daniel. All suggested changes are > OK, but there are two additional things which should be fixed: > > 1. In ssl3_read_n() the argument max is overwritten before used.

[openssl.org #1984] [PATCH]: DTLS: ssl3_read_n() concatenates UDP datagrams in DTLS case

2009-07-09 Thread Daniel Mentz via RT
ssl3_read_n() was conceived to read blocks of data from a byte oriented stream. This can be easily explained by an example: You call ssl3_read_n() with the a parameter like "Read 50 bytes of data". As opposed to the read() function provided by the OS, ssl3_read_n() makes sure you really get 50

[openssl.org #1962] [PATCH] dtls1_get_record() returns a bad record in one edge case

2009-06-30 Thread Daniel Mentz via RT
dtls1_read_bytes() uses dtls1_get_record() to get a record from the wire. There's an agreement between those two functions that says that ssl->s3->rrec.length contains the length of the record just read. If ssl->s3->rrec.length equals 0 then there's no record in the buffer. dtls1_get_record() f

[openssl.org #1923] dtls1_retrieve_buffered_fragment: Read from freed data structure

2009-05-11 Thread Daniel Mentz via RT
This is a bug report. Version: openssl-1.0.0-beta2 OS: Ubuntu 9.04, Linux 2.6.28-11-generic #42-Ubuntu SMP When I run ./openssl s_server -dtls1 -no_ecdhe -timeout -cert large.pem against ./openssl s_client -dtls1 I'll get a Segmentation fault on the client side. I attached the certificate (in

[openssl.org #1921] DTLS: "openssl s_client" broken in 1.0.0-beta2 due to lack of ECDHE support

2009-05-07 Thread Daniel Mentz via RT
r at least print out a log message saying "No DTLS support for ECDHE" Thanks Daniel Mentz __ OpenSSL Project http://www.openssl.org Development Mailing List ope