libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit faabde7649be638b3be42e83be0bf367741d38a1
parent aa8f99d22eb51f0a662d6fcba926fcf6b9e994b1
Author: Christian Grothoff <christian@grothoff.org>
Date:   Fri, 22 Jun 2012 09:08:03 +0000

-fixing #2443: tutorial was unclear

Diffstat:
Mdoc/chapters/tlsauthentication.inc | 7+++++--
Mdoc/examples/tlsauthentication.c | 2+-
2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/doc/chapters/tlsauthentication.inc b/doc/chapters/tlsauthentication.inc @@ -157,8 +157,11 @@ obtain the raw GnuTLS session handle from @emph{MHD} using #include <gnutls/x509.h> gnutls_session_t tls_session; -tls_session = MHD_get_connection_info (connection, - MHD_CONNECTION_INFO_GNUTLS_SESSION); +union MHD_ConnectionInfo *ci; + +ci = MHD_get_connection_info (connection, + MHD_CONNECTION_INFO_GNUTLS_SESSION); +tls_session = ci->tls_session; @end verbatim You can then extract the client certificate: diff --git a/doc/examples/tlsauthentication.c b/doc/examples/tlsauthentication.c @@ -13,7 +13,7 @@ #define SERVERCERTFILE "server.pem" -char * +static char * string_to_base64 (const char *message) { const char *lookup =