[openssl.org #3512] SSL_MODE_ENABLE_PARTIAL_WRITE does not work in DTLS

2014-09-09 Thread Rich Salz via RT
Partial writes don't work for UDP. -- Rich Salz, OpenSSL dev team; rs...@openssl.org __ OpenSSL Project http://www.openssl.org Development Mailing List openssl-dev@openssl.org

Re: [openssl.org #3512] SSL_MODE_ENABLE_PARTIAL_WRITE does not work in DTLS

2014-09-01 Thread Iñaki Baz Castillo
2014-09-01 15:42 GMT+02:00 Salz, Rich : > The size of your UDP packet depends on the MTU supported by everyone along > the path. (BTW, that's what heartbeat was created.) Yes, it is understood now. But, given that DTLS provides reliability and message order, it makes sense IMHO that SSL_write(lo

RE: [openssl.org #3512] SSL_MODE_ENABLE_PARTIAL_WRITE does not work in DTLS

2014-09-01 Thread Salz, Rich
You can't use partial writes. The size of your UDP packet depends on the MTU supported by everyone along the path. (BTW, that's what heartbeat was created.) I suggest you get your program working "properly" for your definition of what properly means, without DTLS. Then add DTLS. And have you

[openssl.org #3512] SSL_MODE_ENABLE_PARTIAL_WRITE does not work in DTLS

2014-09-01 Thread Iñaki Baz Castillo via RT
SSL in DTLS mode. SSL_CTX with SSL_MODE_ENABLE_PARTIAL_WRITE option enabled so SSL_write() may return less than the given data length. It does not work. I call SSL_write() by passing a very long data (65536) and it still returns -1. So, in case I want to write a big data over a DTLS UDP connection

Re: SSL_MODE_ENABLE_PARTIAL_WRITE does not work in DTLS

2014-08-21 Thread Pradosh Mohapatra
UDP's datagram semantics means that the application either writes an entire datagram (if kernel socket buffer has enough space) or it needs to retry. I am guessing that comes to play here. - Pradosh On Thursday, August 21, 2014 3:31 PM, Iñaki Baz Castillo wrote: OpenSSL 1.1.0-dev (git maste

SSL_MODE_ENABLE_PARTIAL_WRITE does not work in DTLS

2014-08-21 Thread Iñaki Baz Castillo
OpenSSL 1.1.0-dev (git master version at 2014-08-22) compiled in OSX 10.9.4. I've a SSL in DTLSv1 server mode. Previously in its SSL_CTX I set the SSL_MODE_ENABLE_PARTIAL_WRITE option to enable SSL_write() to return less than the given data length. I've also tried to set it at SSL level with SSL_s