libmicrohttpd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [libmicrohttpd] How to implement gnutls session resumption in libmic


From: Christian Grothoff
Subject: Re: [libmicrohttpd] How to implement gnutls session resumption in libmicrohttpd
Date: Sat, 24 Dec 2022 17:48:41 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2

Dear Jimmy,

I've not tested this, but I believe this should work:

- create a key using gnutls_session_ticket_key_generate
- register a MHD_NotifyConnectionCallback using MHD_OPTION_NOTIFY_CONNECTION
- inside that callback, use MHD_get_connection_info with MHD_CONNECTION_INFO_GNUTLS_SESSION to get the GnuTLS session handle of the connection
- use gnutls_session_ticket_enable_server on that session to set the key

Please let us know if this works!

Happy hacking!

Christian

On 12/23/22 09:50, Jimmy wrote:
Hi everyone,

__

I contact you because I can't find any answer to my problem by searching on the Internet. I thank you for the time you will take to read me.

I was reading the documentation of gnutls and I saw that it is possible to implement session resumption as described in the gnutls documentation: https://www.gnutls.org/manual/gnutls.html#Session-resumption <https://www.gnutls.org/manual/gnutls.html#Session-resumption> . I would like to use the gnutls session resumption feature with libmicrohttpd but I don’t know how to implement these changes to add this feature. The GnuTls session resumption examples are independent of libmicrohttpd ( https://gitlab.com/gnutls/gnutls/-/blob/master/src/serv.c <https://gitlab.com/gnutls/gnutls/-/blob/master/src/serv.c> ) .So, I have difficulties to see how to adapt the example to my use case.  Would it be possible to help me please ?__

__ Another question: is it possible to implement TLS authentication externally to libmicrohttpd? Is it possible to do this with external event loops?

__

Have a nice day,

Best regards,




reply via email to

[Prev in Thread] Current Thread [Next in Thread]