[gnutls-dev] Re: OpenCDK indexing fails if a public key is at offset 0

Nikos Mavrogiannopoulos nmav at gnutls.org
Mon Sep 25 17:18:21 CEST 2006

On 9/25/06, Simon Josefsson <jas at extundo.com> wrote:

> > This is probably a silly question, but I can't split the read and
> > write paths of a single session across several threads, can I? (e.g.
> > one thread which only calls record_send and other which only calls
> > record_recv). I'm fairly certain I can't, but I'm just checking
> > because it has such a large effect on the code.
> It isn't obvious that this wouldn't work.  Looking at the code,
> receiving and sending are pretty separated.  One concern I had would
> be if receiving something (e.g., an alert, change cipher suite,
> re-handshake request) could trigger additional alerts or other packets
> that would be sent by the library automatically, but I can't find any
> such examples.

Indeed this works. The only problem are the bye messages, which need
some care to be sent without the SHUT_RDWR flag but instead with the WR
flag and wait for an EOF by the peer.

Of course you cannot mix the behavior by sending later using the recv thread


More information about the Gnutls-devel mailing list