[Help-gnutls] exporting session information from one process to another
nmav at gnutls.org
Fri Feb 13 22:22:24 CET 2004
On Fri, Feb 13, 2004 at 07:38:14PM +0100, Brieuc Jeunhomme wrote:
> I need to export session information from one process to another
> process. Simply put, I have a first process that accept()s a
> connection, allocates credentials, sets certificate information etc,
> then fork()s.
> The child process handles the handshake (it calls gnutls_handshake()),
> but, once the handshake is complete, I would like the parent process to
> use the connection, calling gnutls_record_send and gnutls_record_recv.
This is not possible with the current API, and it's not easy to add.
It would probably need to copy the "ConnectionState" parameters, but I'm
not sure this is sufficient. Maybe using a thread instead of a process
would solve the problem easily.
> I have tryed this with 1.0.5, using gnutls_session_set_data and
> gnutls_session_get_data to exchange the session information between the
> two processes, but this doesn't seem to be enough (gnutls_record_send
> works fine if called from the child process, but not from the parent
> process. However, the goal is to have the child process exit after the
> negociation and have the parent process use the established session).
> Is there a way to do this with the current gnutls library ? If not,
> would people here be interested in a patch for this ?
I would be interested, but it seems like a difficult thing to do, and
might not worth the effort.
More information about the Gnutls-help