summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2012-09-28 14:07:46 +0200
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2012-09-28 17:48:18 +0200
commite5823f75e6942a1dc41442e9524419db9ad80c05 (patch)
tree7047e3355a357df610486c28ad0b2549ed871196
parent80e3fa56f4f99008b523491f4d758de7a68ff777 (diff)
downloadgnutls-e5823f75e6942a1dc41442e9524419db9ad80c05.tar.gz
Session ID is correctly read.
-rw-r--r--src/serv.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/src/serv.c b/src/serv.c
index 2e9c674726..26b669961a 100644
--- a/src/serv.c
+++ b/src/serv.c
@@ -330,14 +330,6 @@ generate_rsa_params (void)
LIST_DECLARE_INIT (listener_list, listener_item, listener_free);
-static int
-ocsp_callback (gnutls_session_t session,
- void *ptr,
- gnutls_datum_t *ocsp_response)
-{
- return GNUTLS_E_NO_CERTIFICATE_STATUS;
-}
-
gnutls_session_t initialize_session (int dtls)
{
gnutls_session_t session;
@@ -370,7 +362,7 @@ gnutls_session_t initialize_session (int dtls)
/* OCSP status-request TLS extension */
if (status_response_ocsp)
{
- if (gnutls_status_request_ocsp_server (session, ocsp_callback, NULL) < 0)
+ if (gnutls_status_request_ocsp_server_file (session, status_response_ocsp, 0) < 0)
{
fprintf (stderr, "Cannot set OCSP status request callback.\n");
exit (1);
@@ -495,6 +487,7 @@ peer_print_info (gnutls_session_t session, int *ret_length,
strcpy (http_buffer, HTTP_BEGIN);
/* print session_id */
+ sesid_size = sizeof(sesid);
gnutls_session_get_id (session, sesid, &sesid_size);
snprintf (tmp_buffer, tmp_buffer_size, "\n<p>Session ID: <i>");
for (i = 0; i < sesid_size; i++)