gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r7932 - in libmicrohttpd/src/daemon: . https https/tls


From: gnunet
Subject: [GNUnet-SVN] r7932 - in libmicrohttpd/src/daemon: . https https/tls
Date: Mon, 17 Nov 2008 00:50:59 -0700 (MST)

Author: grothoff
Date: 2008-11-17 00:50:59 -0700 (Mon, 17 Nov 2008)
New Revision: 7932

Modified:
   libmicrohttpd/src/daemon/connection.c
   libmicrohttpd/src/daemon/connection_https.c
   libmicrohttpd/src/daemon/https/gnutls.h
   libmicrohttpd/src/daemon/https/tls/auth_rsa.c
   libmicrohttpd/src/daemon/https/tls/ext_cert_type.c
   libmicrohttpd/src/daemon/https/tls/ext_max_record.c
   libmicrohttpd/src/daemon/https/tls/ext_server_name.c
   libmicrohttpd/src/daemon/https/tls/gnutls_algorithms.c
   libmicrohttpd/src/daemon/https/tls/gnutls_auth.c
   libmicrohttpd/src/daemon/https/tls/gnutls_buffers.c
   libmicrohttpd/src/daemon/https/tls/gnutls_cipher.c
   libmicrohttpd/src/daemon/https/tls/gnutls_constate.c
   libmicrohttpd/src/daemon/https/tls/gnutls_extensions.c
   libmicrohttpd/src/daemon/https/tls/gnutls_handshake.c
   libmicrohttpd/src/daemon/https/tls/gnutls_kx.c
   libmicrohttpd/src/daemon/https/tls/gnutls_record.c
   libmicrohttpd/src/daemon/https/tls/gnutls_sig.c
   libmicrohttpd/src/daemon/https/tls/gnutls_state.c
   libmicrohttpd/src/daemon/https/tls/gnutls_x509.c
Log:
properly

Modified: libmicrohttpd/src/daemon/connection.c
===================================================================
--- libmicrohttpd/src/daemon/connection.c       2008-11-17 07:49:16 UTC (rev 
7931)
+++ libmicrohttpd/src/daemon/connection.c       2008-11-17 07:50:59 UTC (rev 
7932)
@@ -288,8 +288,9 @@
   connection->socket_fd = -1;
   connection->state = MHD_CONNECTION_CLOSED;
   if (connection->daemon->notify_completed != NULL)
-    connection->daemon->notify_completed (connection->daemon->
-                                          notify_completed_cls, connection,
+    connection->daemon->notify_completed (connection->
+                                          daemon->notify_completed_cls,
+                                          connection,
                                           &connection->client_context,
                                           termination_code);
 }
@@ -1038,8 +1039,9 @@
   if (connection->daemon->uri_log_callback != NULL)
     connection->client_context
       =
-      connection->daemon->uri_log_callback (connection->daemon->
-                                            uri_log_callback_cls, uri);
+      connection->daemon->uri_log_callback (connection->
+                                            daemon->uri_log_callback_cls,
+                                            uri);
   args = strstr (uri, "?");
   if (args != NULL)
     {
@@ -1187,8 +1189,8 @@
         }
       used = processed;
       if (MHD_NO ==
-          connection->daemon->default_handler (connection->daemon->
-                                               default_handler_cls,
+          connection->daemon->default_handler (connection->
+                                               daemon->default_handler_cls,
                                                connection, connection->url,
                                                connection->method,
                                                connection->version,
@@ -1239,8 +1241,7 @@
     return MHD_NO;
 
   bytes_read = connection->recv_cls (connection,
-                                     &connection->
-                                     read_buffer
+                                     &connection->read_buffer
                                      [connection->read_buffer_offset],
                                      connection->read_buffer_size -
                                      connection->read_buffer_offset);
@@ -1590,9 +1591,11 @@
         case MHD_CONNECTION_CONTINUE_SENDING:
           ret = connection->send_cls (connection,
                                       &HTTP_100_CONTINUE
-                                      
[connection->continue_message_write_offset],
+                                      [connection->
+                                       continue_message_write_offset],
                                       strlen (HTTP_100_CONTINUE) -
-                                      
connection->continue_message_write_offset);
+                                      connection->
+                                      continue_message_write_offset);
           if (ret < 0)
             {
               if (errno == EINTR)
@@ -1642,12 +1645,12 @@
             {
               ret = MHD__gnutls_record_send (connection->tls_session,
                                              &connection->response->data
-                                             [connection->
+                                             
[connection->response_write_position
+                                              - response->data_start],
+                                             response->data_size -
+                                             (connection->
                                               response_write_position -
-                                              response->data_start],
-                                             response->data_size -
-                                             
(connection->response_write_position
-                                              - response->data_start));
+                                              response->data_start));
             }
           else
 #endif
@@ -2008,8 +2011,8 @@
 #endif
           MHD_destroy_response (connection->response);
           if (connection->daemon->notify_completed != NULL)
-            connection->daemon->notify_completed (connection->daemon->
-                                                  notify_completed_cls,
+            connection->daemon->notify_completed (connection->
+                                                  daemon->notify_completed_cls,
                                                   connection,
                                                   &connection->client_context,
                                                   
MHD_REQUEST_TERMINATED_COMPLETED_OK);

Modified: libmicrohttpd/src/daemon/connection_https.c
===================================================================
--- libmicrohttpd/src/daemon/connection_https.c 2008-11-17 07:49:16 UTC (rev 
7931)
+++ libmicrohttpd/src/daemon/connection_https.c 2008-11-17 07:50:59 UTC (rev 
7932)
@@ -58,26 +58,26 @@
     {
 #if HTTPS_SUPPORT
     case MHD_CONNECTION_INFO_CIPHER_ALGO:
-      return (const union MHD_ConnectionInfo *) &connection->
-        tls_session->security_parameters.read_bulk_cipher_algorithm;
+      return (const union MHD_ConnectionInfo *) &connection->tls_session->
+        security_parameters.read_bulk_cipher_algorithm;
     case MHD_CONNECTION_INFO_KX_ALGO:
-      return (const union MHD_ConnectionInfo *) &connection->
-        tls_session->security_parameters.kx_algorithm;
+      return (const union MHD_ConnectionInfo *) &connection->tls_session->
+        security_parameters.kx_algorithm;
     case MHD_CONNECTION_INFO_CREDENTIALS_TYPE:
-      return (const union MHD_ConnectionInfo *) &connection->
-        tls_session->key->cred->algorithm;
+      return (const union MHD_ConnectionInfo *) &connection->tls_session->
+        key->cred->algorithm;
     case MHD_CONNECTION_INFO_MAC_ALGO:
-      return (const union MHD_ConnectionInfo *) &connection->
-        tls_session->security_parameters.read_mac_algorithm;
+      return (const union MHD_ConnectionInfo *) &connection->tls_session->
+        security_parameters.read_mac_algorithm;
     case MHD_CONNECTION_INFO_COMPRESSION_METHOD:
-      return (const union MHD_ConnectionInfo *) &connection->
-        tls_session->security_parameters.read_compression_algorithm;
+      return (const union MHD_ConnectionInfo *) &connection->tls_session->
+        security_parameters.read_compression_algorithm;
     case MHD_CONNECTION_INFO_PROTOCOL:
-      return (const union MHD_ConnectionInfo *) &connection->
-        tls_session->security_parameters.version;
+      return (const union MHD_ConnectionInfo *) &connection->tls_session->
+        security_parameters.version;
     case MHD_CONNECTION_INFO_CERT_TYPE:
-      return (const union MHD_ConnectionInfo *) &connection->
-        tls_session->security_parameters.cert_type;
+      return (const union MHD_ConnectionInfo *) &connection->tls_session->
+        security_parameters.cert_type;
 #endif
     default:
       return NULL;
@@ -261,8 +261,9 @@
           MHD_DLOG (connection->daemon,
                     "Received TLS alert: %s\n",
                     MHD__gnutls_alert_get_name ((int)
-                                                connection->tls_session->
-                                                internals.last_alert));
+                                                connection->
+                                                tls_session->internals.
+                                                last_alert));
 #endif
           return MHD_YES;
         }

Modified: libmicrohttpd/src/daemon/https/gnutls.h
===================================================================
--- libmicrohttpd/src/daemon/https/gnutls.h     2008-11-17 07:49:16 UTC (rev 
7931)
+++ libmicrohttpd/src/daemon/https/gnutls.h     2008-11-17 07:50:59 UTC (rev 
7932)
@@ -38,7 +38,10 @@
 #ifdef __cplusplus
 extern "C"
 {
+#if 0                           /* keep Emacsens' auto-indent happy */
+}
 #endif
+#endif
 
 #define LIBGNUTLS_VERSION "2.2.3"
 
@@ -56,11 +59,11 @@
 
 #include "microhttpd.h"
 
-  typedef enum
-  {
-    GNUTLS_PARAMS_RSA_EXPORT = 1,
-    GNUTLS_PARAMS_DH
-  } MHD_gnutls_params_type_t;
+typedef enum
+{
+  GNUTLS_PARAMS_RSA_EXPORT = 1,
+  GNUTLS_PARAMS_DH
+} MHD_gnutls_params_type_t;
 
   /* exported for other gnutls headers. This is the maximum number of
    * algorithms (ciphers, kx or macs).
@@ -68,419 +71,415 @@
 #define GNUTLS_MAX_ALGORITHM_NUM 16
 #define GNUTLS_COMP_ZLIB GNUTLS_COMP_DEFLATE
 
-  typedef enum
-  {
-    GNUTLS_SERVER = 1,
-    GNUTLS_CLIENT
-  } MHD_gnutls_connection_end_t;
+typedef enum
+{
+  GNUTLS_SERVER = 1,
+  GNUTLS_CLIENT
+} MHD_gnutls_connection_end_t;
 
-  typedef enum
-  {
-    GNUTLS_AL_WARNING = 1,
-    GNUTLS_AL_FATAL
-  } MHD_gnutls_alert_level_t;
+typedef enum
+{
+  GNUTLS_AL_WARNING = 1,
+  GNUTLS_AL_FATAL
+} MHD_gnutls_alert_level_t;
 
-  typedef enum
-  {
-    GNUTLS_A_CLOSE_NOTIFY,
-    GNUTLS_A_UNEXPECTED_MESSAGE = 10,
-    GNUTLS_A_BAD_RECORD_MAC = 20,
-    GNUTLS_A_DECRYPTION_FAILED,
-    GNUTLS_A_RECORD_OVERFLOW,
-    GNUTLS_A_DECOMPRESSION_FAILURE = 30,
-    GNUTLS_A_HANDSHAKE_FAILURE = 40,
-    GNUTLS_A_SSL3_NO_CERTIFICATE = 41,
-    GNUTLS_A_BAD_CERTIFICATE = 42,
-    GNUTLS_A_UNSUPPORTED_CERTIFICATE,
-    GNUTLS_A_CERTIFICATE_REVOKED,
-    GNUTLS_A_CERTIFICATE_EXPIRED,
-    GNUTLS_A_CERTIFICATE_UNKNOWN,
-    GNUTLS_A_ILLEGAL_PARAMETER,
-    GNUTLS_A_UNKNOWN_CA,
-    GNUTLS_A_ACCESS_DENIED,
-    GNUTLS_A_DECODE_ERROR = 50,
-    GNUTLS_A_DECRYPT_ERROR,
-    GNUTLS_A_EXPORT_RESTRICTION = 60,
-    GNUTLS_A_PROTOCOL_VERSION = 70,
-    GNUTLS_A_INSUFFICIENT_SECURITY,
-    GNUTLS_A_INTERNAL_ERROR = 80,
-    GNUTLS_A_USER_CANCELED = 90,
-    GNUTLS_A_NO_RENEGOTIATION = 100,
-    GNUTLS_A_UNSUPPORTED_EXTENSION = 110,
-    GNUTLS_A_CERTIFICATE_UNOBTAINABLE = 111,
-    GNUTLS_A_UNRECOGNIZED_NAME = 112,
-    GNUTLS_A_UNKNOWN_PSK_IDENTITY = 115,
-  } MHD_gnutls_alert_description_t;
+typedef enum
+{
+  GNUTLS_A_CLOSE_NOTIFY,
+  GNUTLS_A_UNEXPECTED_MESSAGE = 10,
+  GNUTLS_A_BAD_RECORD_MAC = 20,
+  GNUTLS_A_DECRYPTION_FAILED,
+  GNUTLS_A_RECORD_OVERFLOW,
+  GNUTLS_A_DECOMPRESSION_FAILURE = 30,
+  GNUTLS_A_HANDSHAKE_FAILURE = 40,
+  GNUTLS_A_SSL3_NO_CERTIFICATE = 41,
+  GNUTLS_A_BAD_CERTIFICATE = 42,
+  GNUTLS_A_UNSUPPORTED_CERTIFICATE,
+  GNUTLS_A_CERTIFICATE_REVOKED,
+  GNUTLS_A_CERTIFICATE_EXPIRED,
+  GNUTLS_A_CERTIFICATE_UNKNOWN,
+  GNUTLS_A_ILLEGAL_PARAMETER,
+  GNUTLS_A_UNKNOWN_CA,
+  GNUTLS_A_ACCESS_DENIED,
+  GNUTLS_A_DECODE_ERROR = 50,
+  GNUTLS_A_DECRYPT_ERROR,
+  GNUTLS_A_EXPORT_RESTRICTION = 60,
+  GNUTLS_A_PROTOCOL_VERSION = 70,
+  GNUTLS_A_INSUFFICIENT_SECURITY,
+  GNUTLS_A_INTERNAL_ERROR = 80,
+  GNUTLS_A_USER_CANCELED = 90,
+  GNUTLS_A_NO_RENEGOTIATION = 100,
+  GNUTLS_A_UNSUPPORTED_EXTENSION = 110,
+  GNUTLS_A_CERTIFICATE_UNOBTAINABLE = 111,
+  GNUTLS_A_UNRECOGNIZED_NAME = 112,
+  GNUTLS_A_UNKNOWN_PSK_IDENTITY = 115,
+} MHD_gnutls_alert_description_t;
 
-  typedef enum
-  { GNUTLS_HANDSHAKE_HELLO_REQUEST = 0,
-    GNUTLS_HANDSHAKE_CLIENT_HELLO = 1,
-    GNUTLS_HANDSHAKE_SERVER_HELLO = 2,
-    GNUTLS_HANDSHAKE_CERTIFICATE_PKT = 11,
-    GNUTLS_HANDSHAKE_SERVER_KEY_EXCHANGE = 12,
-    GNUTLS_HANDSHAKE_CERTIFICATE_REQUEST = 13,
-    GNUTLS_HANDSHAKE_SERVER_HELLO_DONE = 14,
-    GNUTLS_HANDSHAKE_CERTIFICATE_VERIFY = 15,
-    GNUTLS_HANDSHAKE_CLIENT_KEY_EXCHANGE = 16,
-    GNUTLS_HANDSHAKE_FINISHED = 20,
-    GNUTLS_HANDSHAKE_SUPPLEMENTAL = 23
-  } MHD_gnutls_handshake_description_t;
+typedef enum
+{ GNUTLS_HANDSHAKE_HELLO_REQUEST = 0,
+  GNUTLS_HANDSHAKE_CLIENT_HELLO = 1,
+  GNUTLS_HANDSHAKE_SERVER_HELLO = 2,
+  GNUTLS_HANDSHAKE_CERTIFICATE_PKT = 11,
+  GNUTLS_HANDSHAKE_SERVER_KEY_EXCHANGE = 12,
+  GNUTLS_HANDSHAKE_CERTIFICATE_REQUEST = 13,
+  GNUTLS_HANDSHAKE_SERVER_HELLO_DONE = 14,
+  GNUTLS_HANDSHAKE_CERTIFICATE_VERIFY = 15,
+  GNUTLS_HANDSHAKE_CLIENT_KEY_EXCHANGE = 16,
+  GNUTLS_HANDSHAKE_FINISHED = 20,
+  GNUTLS_HANDSHAKE_SUPPLEMENTAL = 23
+} MHD_gnutls_handshake_description_t;
 
-  typedef enum
-  {
-    GNUTLS_CERT_INVALID = 2,    /* will be set if the certificate
+typedef enum
+{
+  GNUTLS_CERT_INVALID = 2,      /* will be set if the certificate
                                  * was not verified.
                                  */
-    GNUTLS_CERT_REVOKED = 32,   /* in X.509 this will be set only if CRLs are 
checked
+  GNUTLS_CERT_REVOKED = 32,     /* in X.509 this will be set only if CRLs are 
checked
                                  */
 
-    /* Those are extra information about the verification
-     * process. Will be set only if the certificate was
-     * not verified.
-     */
-    GNUTLS_CERT_SIGNER_NOT_FOUND = 64,
-    GNUTLS_CERT_SIGNER_NOT_CA = 128,
-    GNUTLS_CERT_INSECURE_ALGORITHM = 256
-  } MHD_gnutls_certificate_status_t;
+  /* Those are extra information about the verification
+   * process. Will be set only if the certificate was
+   * not verified.
+   */
+  GNUTLS_CERT_SIGNER_NOT_FOUND = 64,
+  GNUTLS_CERT_SIGNER_NOT_CA = 128,
+  GNUTLS_CERT_INSECURE_ALGORITHM = 256
+} MHD_gnutls_certificate_status_t;
 
-  typedef enum
-  {
-    GNUTLS_CERT_IGNORE,
-    GNUTLS_CERT_REQUEST = 1,
-    GNUTLS_CERT_REQUIRE
-  } MHD_gnutls_certificate_request_t;
+typedef enum
+{
+  GNUTLS_CERT_IGNORE,
+  GNUTLS_CERT_REQUEST = 1,
+  GNUTLS_CERT_REQUIRE
+} MHD_gnutls_certificate_request_t;
 
-  typedef enum
-  {
-    GNUTLS_SHUT_RDWR = 0,
-    GNUTLS_SHUT_WR = 1
-  } MHD_gnutls_close_request_t;
+typedef enum
+{
+  GNUTLS_SHUT_RDWR = 0,
+  GNUTLS_SHUT_WR = 1
+} MHD_gnutls_close_request_t;
 
-  typedef enum
-  {
-    GNUTLS_X509_FMT_DER,
-    GNUTLS_X509_FMT_PEM
-  } MHD_gnutls_x509_crt_fmt_t;
+typedef enum
+{
+  GNUTLS_X509_FMT_DER,
+  GNUTLS_X509_FMT_PEM
+} MHD_gnutls_x509_crt_fmt_t;
 
-  typedef enum
-  {
-    GNUTLS_SIGN_UNKNOWN = 0,
-    GNUTLS_SIGN_RSA_SHA1 = 1,
-    GNUTLS_SIGN_DSA_SHA1,
-    GNUTLS_SIGN_RSA_MD5,
-    GNUTLS_SIGN_RSA_MD2,
-    GNUTLS_SIGN_RSA_RMD160,
-    GNUTLS_SIGN_RSA_SHA256,
-    GNUTLS_SIGN_RSA_SHA384,
-    GNUTLS_SIGN_RSA_SHA512
-  } MHD_gnutls_sign_algorithm_t;
+typedef enum
+{
+  GNUTLS_SIGN_UNKNOWN = 0,
+  GNUTLS_SIGN_RSA_SHA1 = 1,
+  GNUTLS_SIGN_DSA_SHA1,
+  GNUTLS_SIGN_RSA_MD5,
+  GNUTLS_SIGN_RSA_MD2,
+  GNUTLS_SIGN_RSA_RMD160,
+  GNUTLS_SIGN_RSA_SHA256,
+  GNUTLS_SIGN_RSA_SHA384,
+  GNUTLS_SIGN_RSA_SHA512
+} MHD_gnutls_sign_algorithm_t;
 
 /* If you want to change this, then also change the define in
  * MHD_gnutls_int.h, and recompile.
  */
-  typedef void *MHD_gnutls_transport_ptr_t;
+typedef void *MHD_gnutls_transport_ptr_t;
 
-  struct MHD_gtls_session_int;
-  typedef struct MHD_gtls_session_int *MHD_gtls_session_t;
+struct MHD_gtls_session_int;
+typedef struct MHD_gtls_session_int *MHD_gtls_session_t;
 
-  struct MHD_gtls_dh_params_int;
-  typedef struct MHD_gtls_dh_params_int *MHD_gtls_dh_params_t;
+struct MHD_gtls_dh_params_int;
+typedef struct MHD_gtls_dh_params_int *MHD_gtls_dh_params_t;
 
-  struct MHD_gtls_x509_privkey_int;     /* XXX ugly. */
-  typedef struct MHD_gtls_x509_privkey_int *MHD_gtls_rsa_params_t;      /* XXX 
ugly. */
+struct MHD_gtls_x509_privkey_int;       /* XXX ugly. */
+typedef struct MHD_gtls_x509_privkey_int *MHD_gtls_rsa_params_t;        /* XXX 
ugly. */
 
-  struct MHD_gtls_priority_st;
-  typedef struct MHD_gtls_priority_st *MHD_gnutls_priority_t;
+struct MHD_gtls_priority_st;
+typedef struct MHD_gtls_priority_st *MHD_gnutls_priority_t;
 
-  typedef struct
-  {
-    unsigned char *data;
-    unsigned int size;
-  } MHD_gnutls_datum_t;
+typedef struct
+{
+  unsigned char *data;
+  unsigned int size;
+} MHD_gnutls_datum_t;
 
 
-  typedef struct MHD_gnutls_params_st
+typedef struct MHD_gnutls_params_st
+{
+  MHD_gnutls_params_type_t type;
+  union params
   {
-    MHD_gnutls_params_type_t type;
-    union params
-    {
-      MHD_gtls_dh_params_t dh;
-      MHD_gtls_rsa_params_t rsa_export;
-    } params;
-    int deinit;
-  } MHD_gnutls_params_st;
+    MHD_gtls_dh_params_t dh;
+    MHD_gtls_rsa_params_t rsa_export;
+  } params;
+  int deinit;
+} MHD_gnutls_params_st;
 
-  typedef int MHD_gnutls_params_function (MHD_gtls_session_t,
-                                          MHD_gnutls_params_type_t,
-                                          MHD_gnutls_params_st *);
+typedef int MHD_gnutls_params_function (MHD_gtls_session_t,
+                                        MHD_gnutls_params_type_t,
+                                        MHD_gnutls_params_st *);
 
 /* internal functions */
-  int MHD__gnutls_global_init (void);
-  void MHD__gnutls_global_deinit (void);
+int MHD__gnutls_global_init (void);
+void MHD__gnutls_global_deinit (void);
 
-  int MHD__gnutls_init (MHD_gtls_session_t * session,
-                        MHD_gnutls_connection_end_t con_end);
-  void MHD__gnutls_deinit (MHD_gtls_session_t session);
+int MHD__gnutls_init (MHD_gtls_session_t * session,
+                      MHD_gnutls_connection_end_t con_end);
+void MHD__gnutls_deinit (MHD_gtls_session_t session);
 
-  int MHD__gnutls_bye (MHD_gtls_session_t session,
-                       MHD_gnutls_close_request_t how);
-  int MHD__gnutls_handshake (MHD_gtls_session_t session);
-  int MHD__gnutls_rehandshake (MHD_gtls_session_t session);
+int MHD__gnutls_bye (MHD_gtls_session_t session,
+                     MHD_gnutls_close_request_t how);
+int MHD__gnutls_handshake (MHD_gtls_session_t session);
+int MHD__gnutls_rehandshake (MHD_gtls_session_t session);
 
-  MHD_gnutls_alert_description_t MHD_gnutls_alert_get (MHD_gtls_session_t
-                                                       session);
-  int MHD__gnutls_alert_send (MHD_gtls_session_t session,
-                              MHD_gnutls_alert_level_t level,
-                              MHD_gnutls_alert_description_t desc);
-  int MHD__gnutls_alert_send_appropriate (MHD_gtls_session_t session,
-                                          int err);
-  const char *MHD__gnutls_alert_get_name (MHD_gnutls_alert_description_t
-                                          alert);
+MHD_gnutls_alert_description_t MHD_gnutls_alert_get (MHD_gtls_session_t
+                                                     session);
+int MHD__gnutls_alert_send (MHD_gtls_session_t session,
+                            MHD_gnutls_alert_level_t level,
+                            MHD_gnutls_alert_description_t desc);
+int MHD__gnutls_alert_send_appropriate (MHD_gtls_session_t session, int err);
+const char *MHD__gnutls_alert_get_name (MHD_gnutls_alert_description_t alert);
 
-  enum MHD_GNUTLS_CompressionMethod
-    MHD_gtls_compression_get (MHD_gtls_session_t session);
-  size_t MHD__gnutls_cipher_get_key_size (enum MHD_GNUTLS_CipherAlgorithm
-                                          algorithm);
+enum MHD_GNUTLS_CompressionMethod
+MHD_gtls_compression_get (MHD_gtls_session_t session);
+size_t MHD__gnutls_cipher_get_key_size (enum MHD_GNUTLS_CipherAlgorithm
+                                        algorithm);
 
 /* the name of the specified algorithms */
-  const char *MHD_gtls_compression_get_name (enum
-                                             MHD_GNUTLS_CompressionMethod
-                                             algorithm);
-  enum MHD_GNUTLS_CompressionMethod MHD_gtls_compression_get_id (const char
-                                                                 *name);
+const char *MHD_gtls_compression_get_name (enum
+                                           MHD_GNUTLS_CompressionMethod
+                                           algorithm);
+enum MHD_GNUTLS_CompressionMethod MHD_gtls_compression_get_id (const char
+                                                               *name);
 
   /* error functions */
-  int MHD_gtls_error_is_fatal (int error);
-  int MHD_gtls_error_to_alert (int err, int *level);
-  void MHD_gtls_perror (int error);
-  const char *MHD_gtls_strerror (int error);
+int MHD_gtls_error_is_fatal (int error);
+int MHD_gtls_error_to_alert (int err, int *level);
+void MHD_gtls_perror (int error);
+const char *MHD_gtls_strerror (int error);
 
 /*
  * Record layer functions.
  */
-  ssize_t MHD__gnutls_record_send (MHD_gtls_session_t session,
-                                   const void *data, size_t sizeofdata);
-  ssize_t MHD__gnutls_record_recv (MHD_gtls_session_t session, void *data,
-                                   size_t sizeofdata);
+ssize_t MHD__gnutls_record_send (MHD_gtls_session_t session,
+                                 const void *data, size_t sizeofdata);
+ssize_t MHD__gnutls_record_recv (MHD_gtls_session_t session, void *data,
+                                 size_t sizeofdata);
 
   /* provides extra compatibility */
-  int MHD__gnutls_record_get_direction (MHD_gtls_session_t session);
+int MHD__gnutls_record_get_direction (MHD_gtls_session_t session);
 
 /*
  * TLS Extensions
  */
-  typedef enum
-  {
-    GNUTLS_NAME_DNS = 1
-  } MHD_gnutls_server_name_type_t;
+typedef enum
+{
+  GNUTLS_NAME_DNS = 1
+} MHD_gnutls_server_name_type_t;
 
   /* Opaque PRF Input
    * http://tools.ietf.org/id/draft-rescorla-tls-opaque-prf-input-00.txt
    */
 
-  typedef int (*MHD_gnutls_oprfi_callback_func) (MHD_gtls_session_t session,
-                                                 void *userdata,
-                                                 size_t oprfi_len,
-                                                 const unsigned char
-                                                 *in_oprfi,
-                                                 unsigned char *out_oprfi);
+typedef int (*MHD_gnutls_oprfi_callback_func) (MHD_gtls_session_t session,
+                                               void *userdata,
+                                               size_t oprfi_len,
+                                               const unsigned char
+                                               *in_oprfi,
+                                               unsigned char *out_oprfi);
 
   /* Supplemental data, RFC 4680. */
-  typedef enum
-  {
-    GNUTLS_SUPPLEMENTAL_USER_MAPPING_DATA = 0
-  } MHD_gnutls_supplemental_data_format_type_t;
+typedef enum
+{
+  GNUTLS_SUPPLEMENTAL_USER_MAPPING_DATA = 0
+} MHD_gnutls_supplemental_data_format_type_t;
 
 
-  int MHD_tls_set_default_priority (MHD_gnutls_priority_t *,
-                                    const char *priority,
-                                    const char **err_pos);
-  void MHD__gnutls_priority_deinit (MHD_gnutls_priority_t);
+int MHD_tls_set_default_priority (MHD_gnutls_priority_t *,
+                                  const char *priority, const char **err_pos);
+void MHD__gnutls_priority_deinit (MHD_gnutls_priority_t);
 
-  int MHD__gnutls_priority_set (MHD_gtls_session_t session,
-                                MHD_gnutls_priority_t);
-  int MHD__gnutls_priority_set_direct (MHD_gtls_session_t session,
-                                       const char *priority,
-                                       const char **err_pos);
+int MHD__gnutls_priority_set (MHD_gtls_session_t session,
+                              MHD_gnutls_priority_t);
+int MHD__gnutls_priority_set_direct (MHD_gtls_session_t session,
+                                     const char *priority,
+                                     const char **err_pos);
 
 /* get the currently used protocol version */
-  enum MHD_GNUTLS_Protocol
-    MHD__gnutls_protocol_get_version (MHD_gtls_session_t session);
+enum MHD_GNUTLS_Protocol
+MHD__gnutls_protocol_get_version (MHD_gtls_session_t session);
 
-  typedef
-    int (*MHD_gnutls_handshake_post_client_hello_func) (MHD_gtls_session_t);
-  void MHD__gnutls_handshake_set_max_packet_length (MHD_gtls_session_t
-                                                    session, size_t max);
+typedef
+  int (*MHD_gnutls_handshake_post_client_hello_func) (MHD_gtls_session_t);
+void MHD__gnutls_handshake_set_max_packet_length (MHD_gtls_session_t
+                                                  session, size_t max);
 
 /*
  * Functions for setting/clearing credentials
  */
-  void MHD__gnutls_credentials_clear (MHD_gtls_session_t session);
+void MHD__gnutls_credentials_clear (MHD_gtls_session_t session);
 
 /*
  * cred is a structure defined by the kx algorithm
  */
-  int MHD__gnutls_credentials_set (MHD_gtls_session_t session,
-                                   enum MHD_GNUTLS_CredentialsType type,
-                                   void *cred);
+int MHD__gnutls_credentials_set (MHD_gtls_session_t session,
+                                 enum MHD_GNUTLS_CredentialsType type,
+                                 void *cred);
 
 /* Credential structures - used in MHD__gnutls_credentials_set(); */
-  struct MHD_gtls_certificate_credentials_st;
-  typedef struct MHD_gtls_certificate_credentials_st
-    *MHD_gtls_cert_credentials_t;
-  typedef MHD_gtls_cert_credentials_t MHD_gtls_cert_server_credentials;
-  typedef MHD_gtls_cert_credentials_t MHD_gtls_cert_client_credentials;
+struct MHD_gtls_certificate_credentials_st;
+typedef struct MHD_gtls_certificate_credentials_st
+  *MHD_gtls_cert_credentials_t;
+typedef MHD_gtls_cert_credentials_t MHD_gtls_cert_server_credentials;
+typedef MHD_gtls_cert_credentials_t MHD_gtls_cert_client_credentials;
 
-  void MHD__gnutls_certificate_free_credentials (MHD_gtls_cert_credentials_t
-                                                 sc);
-  int
-    MHD__gnutls_certificate_allocate_credentials (MHD_gtls_cert_credentials_t
-                                                  * res);
+void MHD__gnutls_certificate_free_credentials (MHD_gtls_cert_credentials_t
+                                               sc);
+int
+MHD__gnutls_certificate_allocate_credentials (MHD_gtls_cert_credentials_t
+                                              * res);
 
-  void MHD__gnutls_certificate_free_keys (MHD_gtls_cert_credentials_t sc);
-  void MHD__gnutls_certificate_free_cas (MHD_gtls_cert_credentials_t sc);
-  void MHD__gnutls_certificate_free_ca_names (MHD_gtls_cert_credentials_t sc);
+void MHD__gnutls_certificate_free_keys (MHD_gtls_cert_credentials_t sc);
+void MHD__gnutls_certificate_free_cas (MHD_gtls_cert_credentials_t sc);
+void MHD__gnutls_certificate_free_ca_names (MHD_gtls_cert_credentials_t sc);
 
-  int MHD__gnutls_certificate_set_x509_key_mem (MHD_gtls_cert_credentials_t
-                                                res,
-                                                const MHD_gnutls_datum_t *
-                                                CERT,
-                                                const MHD_gnutls_datum_t *
-                                                KEY,
-                                                MHD_gnutls_x509_crt_fmt_t
-                                                type);
+int MHD__gnutls_certificate_set_x509_key_mem (MHD_gtls_cert_credentials_t
+                                              res,
+                                              const MHD_gnutls_datum_t *
+                                              CERT,
+                                              const MHD_gnutls_datum_t *
+                                              KEY,
+                                              MHD_gnutls_x509_crt_fmt_t type);
 
-  void MHD__gnutls_certificate_send_x509_rdn_sequence (MHD_gtls_session_t
-                                                       session, int status);
+void MHD__gnutls_certificate_send_x509_rdn_sequence (MHD_gtls_session_t
+                                                     session, int status);
 
 /*
  * New functions to allow setting already parsed X.509 stuff.
  */
-  struct MHD_gtls_x509_privkey_int;
-  typedef struct MHD_gtls_x509_privkey_int *MHD_gnutls_x509_privkey_t;
+struct MHD_gtls_x509_privkey_int;
+typedef struct MHD_gtls_x509_privkey_int *MHD_gnutls_x509_privkey_t;
 
-  struct MHD_gnutls_x509_crl_int;
-  typedef struct MHD_gnutls_x509_crl_int *MHD_gnutls_x509_crl_t;
+struct MHD_gnutls_x509_crl_int;
+typedef struct MHD_gnutls_x509_crl_int *MHD_gnutls_x509_crl_t;
 
-  struct MHD_gnutls_x509_crt_int;
-  typedef struct MHD_gnutls_x509_crt_int *MHD_gnutls_x509_crt_t;
+struct MHD_gnutls_x509_crt_int;
+typedef struct MHD_gnutls_x509_crt_int *MHD_gnutls_x509_crt_t;
 
 /* global state functions
  */
 
 
-  typedef void *(*MHD_gnutls_alloc_function) (size_t);
-  typedef int (*MHD_gnutls_is_secure_function) (const void *);
-  typedef void *(*MHD_gnutls_calloc_function) (size_t, size_t);
-  typedef void (*MHD_gnutls_free_function) (void *);
-  typedef void *(*MHD_gnutls_realloc_function) (void *, size_t);
+typedef void *(*MHD_gnutls_alloc_function) (size_t);
+typedef int (*MHD_gnutls_is_secure_function) (const void *);
+typedef void *(*MHD_gnutls_calloc_function) (size_t, size_t);
+typedef void (*MHD_gnutls_free_function) (void *);
+typedef void *(*MHD_gnutls_realloc_function) (void *, size_t);
 
 /* For use in callbacks */
-  extern MHD_gnutls_alloc_function MHD_gnutls_malloc;
-  extern MHD_gnutls_alloc_function MHD_gnutls_secure_malloc;
-  extern MHD_gnutls_realloc_function MHD_gnutls_realloc;
-  extern MHD_gnutls_calloc_function MHD_gnutls_calloc;
-  extern MHD_gnutls_free_function MHD_gnutls_free;
+extern MHD_gnutls_alloc_function MHD_gnutls_malloc;
+extern MHD_gnutls_alloc_function MHD_gnutls_secure_malloc;
+extern MHD_gnutls_realloc_function MHD_gnutls_realloc;
+extern MHD_gnutls_calloc_function MHD_gnutls_calloc;
+extern MHD_gnutls_free_function MHD_gnutls_free;
 
-  typedef void (*MHD_gnutls_log_func) (int, const char *);
-  void MHD_gtls_global_set_log_function (MHD_gnutls_log_func log_func);
-  void MHD_gtls_global_set_log_level (int level);
+typedef void (*MHD_gnutls_log_func) (int, const char *);
+void MHD_gtls_global_set_log_function (MHD_gnutls_log_func log_func);
+void MHD_gtls_global_set_log_level (int level);
 
 /*
  * Diffie Hellman parameter handling.
  */
-  int MHD__gnutls_dh_params_init (MHD_gtls_dh_params_t * dh_params);
-  void MHD__gnutls_dh_params_deinit (MHD_gtls_dh_params_t dh_params);
+int MHD__gnutls_dh_params_init (MHD_gtls_dh_params_t * dh_params);
+void MHD__gnutls_dh_params_deinit (MHD_gtls_dh_params_t dh_params);
 
 
 /* RSA params */
-  int MHD__gnutls_rsa_params_init (MHD_gtls_rsa_params_t * rsa_params);
-  void MHD__gnutls_rsa_params_deinit (MHD_gtls_rsa_params_t rsa_params);
-  int MHD__gnutls_rsa_params_generate2 (MHD_gtls_rsa_params_t params,
-                                        unsigned int bits);
+int MHD__gnutls_rsa_params_init (MHD_gtls_rsa_params_t * rsa_params);
+void MHD__gnutls_rsa_params_deinit (MHD_gtls_rsa_params_t rsa_params);
+int MHD__gnutls_rsa_params_generate2 (MHD_gtls_rsa_params_t params,
+                                      unsigned int bits);
 
 
 /*
  * Session stuff
  */
-  typedef ssize_t (*MHD_gtls_pull_func) (MHD_gnutls_transport_ptr_t, void *,
-                                         size_t);
-  typedef ssize_t (*MHD_gtls_push_func) (MHD_gnutls_transport_ptr_t,
-                                         const void *, size_t);
-  void MHD__gnutls_transport_set_ptr (MHD_gtls_session_t session,
-                                      MHD_gnutls_transport_ptr_t ptr);
-  void MHD__gnutls_transport_set_lowat (MHD_gtls_session_t session, int num);
+typedef ssize_t (*MHD_gtls_pull_func) (MHD_gnutls_transport_ptr_t, void *,
+                                       size_t);
+typedef ssize_t (*MHD_gtls_push_func) (MHD_gnutls_transport_ptr_t,
+                                       const void *, size_t);
+void MHD__gnutls_transport_set_ptr (MHD_gtls_session_t session,
+                                    MHD_gnutls_transport_ptr_t ptr);
+void MHD__gnutls_transport_set_lowat (MHD_gtls_session_t session, int num);
 
 
-  void MHD__gnutls_transport_set_push_function (MHD_gtls_session_t session,
-                                                MHD_gtls_push_func push_func);
-  void MHD__gnutls_transport_set_pull_function (MHD_gtls_session_t session,
-                                                MHD_gtls_pull_func pull_func);
+void MHD__gnutls_transport_set_push_function (MHD_gtls_session_t session,
+                                              MHD_gtls_push_func push_func);
+void MHD__gnutls_transport_set_pull_function (MHD_gtls_session_t session,
+                                              MHD_gtls_pull_func pull_func);
 
-  typedef enum MHD_gnutls_x509_subject_alt_name_t
+typedef enum MHD_gnutls_x509_subject_alt_name_t
+{
+  GNUTLS_SAN_DNSNAME = 1,
+  GNUTLS_SAN_RFC822NAME,
+  GNUTLS_SAN_URI,
+  GNUTLS_SAN_IPADDRESS,
+  GNUTLS_SAN_OTHERNAME,
+  GNUTLS_SAN_DN,
+  /* The following are "virtual" subject alternative name types, in
+     that they are represented by an otherName value and an OID.
+     Used by MHD_gnutls_x509_crt_get_subject_alt_othername_oid().  */
+  GNUTLS_SAN_OTHERNAME_XMPP = 1000
+} MHD_gnutls_x509_subject_alt_name_t;
+
+typedef struct MHD_gnutls_retr_st
+{
+  enum MHD_GNUTLS_CertificateType type;
+  union cert
   {
-    GNUTLS_SAN_DNSNAME = 1,
-    GNUTLS_SAN_RFC822NAME,
-    GNUTLS_SAN_URI,
-    GNUTLS_SAN_IPADDRESS,
-    GNUTLS_SAN_OTHERNAME,
-    GNUTLS_SAN_DN,
-    /* The following are "virtual" subject alternative name types, in
-       that they are represented by an otherName value and an OID.
-       Used by MHD_gnutls_x509_crt_get_subject_alt_othername_oid().  */
-    GNUTLS_SAN_OTHERNAME_XMPP = 1000
-  } MHD_gnutls_x509_subject_alt_name_t;
+    MHD_gnutls_x509_crt_t *x509;
+  } cert;
+  unsigned int ncerts;
 
-  typedef struct MHD_gnutls_retr_st
+  union key
   {
-    enum MHD_GNUTLS_CertificateType type;
-    union cert
-    {
-      MHD_gnutls_x509_crt_t *x509;
-    } cert;
-    unsigned int ncerts;
+    MHD_gnutls_x509_privkey_t x509;
+  } key;
 
-    union key
-    {
-      MHD_gnutls_x509_privkey_t x509;
-    } key;
+  unsigned int deinit_all;      /* if non zero all keys will be deinited */
+} MHD_gnutls_retr_st;
 
-    unsigned int deinit_all;    /* if non zero all keys will be deinited */
-  } MHD_gnutls_retr_st;
+typedef int
+MHD_gnutls_certificate_client_retrieve_function (MHD_gtls_session_t,
+                                                 const MHD_gnutls_datum_t
+                                                 * req_ca_rdn, int nreqs,
+                                                 const enum
+                                                 MHD_GNUTLS_PublicKeyAlgorithm
+                                                 *pk_algos,
+                                                 int pk_algos_length,
+                                                 MHD_gnutls_retr_st *);
 
-  typedef int
-    MHD_gnutls_certificate_client_retrieve_function (MHD_gtls_session_t,
-                                                     const MHD_gnutls_datum_t
-                                                     * req_ca_rdn, int nreqs,
-                                                     const enum
-                                                     
MHD_GNUTLS_PublicKeyAlgorithm
-                                                     *pk_algos,
-                                                     int pk_algos_length,
-                                                     MHD_gnutls_retr_st *);
+typedef int
+MHD_gnutls_certificate_server_retrieve_function (MHD_gtls_session_t,
+                                                 MHD_gnutls_retr_st *);
 
-  typedef int
-    MHD_gnutls_certificate_server_retrieve_function (MHD_gtls_session_t,
-                                                     MHD_gnutls_retr_st *);
-
   /*
    * Functions that allow auth_info_t structures handling
    */
-  enum MHD_GNUTLS_CredentialsType MHD_gtls_auth_get_type (MHD_gtls_session_t
-                                                          session);
+enum MHD_GNUTLS_CredentialsType MHD_gtls_auth_get_type (MHD_gtls_session_t
+                                                        session);
   /*
    * DH
    */
-  void MHD__gnutls_dh_set_prime_bits (MHD_gtls_session_t session,
-                                      unsigned int bits);
+void MHD__gnutls_dh_set_prime_bits (MHD_gtls_session_t session,
+                                    unsigned int bits);
 
   /* External signing callback.  Experimental. */
-  typedef int (*MHD_gnutls_sign_func) (MHD_gtls_session_t session,
-                                       void *userdata,
-                                       enum MHD_GNUTLS_CertificateType
-                                       cert_type,
-                                       const MHD_gnutls_datum_t * cert,
-                                       const MHD_gnutls_datum_t * hash,
-                                       MHD_gnutls_datum_t * signature);
+typedef int (*MHD_gnutls_sign_func) (MHD_gtls_session_t session,
+                                     void *userdata,
+                                     enum MHD_GNUTLS_CertificateType
+                                     cert_type,
+                                     const MHD_gnutls_datum_t * cert,
+                                     const MHD_gnutls_datum_t * hash,
+                                     MHD_gnutls_datum_t * signature);
 
   /* key_usage will be an OR of the following values: */
   /* when the key is to be used for signing: */
@@ -628,8 +627,12 @@
 #define GNUTLS_E_APPLICATION_ERROR_MAX -65000
 #define GNUTLS_E_APPLICATION_ERROR_MIN -65500
 
+
+#if 0                           /* keep Emacsens' auto-indent happy */
+{
+#endif
 #ifdef __cplusplus
 }
 #endif
 
-#endif                          /* GNUTLS_H */
+#endif /* GNUTLS_H */

Modified: libmicrohttpd/src/daemon/https/tls/auth_rsa.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/auth_rsa.c       2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/auth_rsa.c       2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -168,8 +168,8 @@
     }
 
   bits =
-    MHD__gnutls_mpi_get_nbits (session->internals.selected_cert_list[0].
-                               params[0]);
+    MHD__gnutls_mpi_get_nbits (session->internals.
+                               selected_cert_list[0].params[0]);
 
   if (MHD_gtls_cipher_suite_get_kx_algo
       (&session->security_parameters.current_cipher_suite)

Modified: libmicrohttpd/src/daemon/https/tls/ext_cert_type.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/ext_cert_type.c  2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/ext_cert_type.c  2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -183,8 +183,8 @@
           for (i = 0; i < len; i++)
             {
               data[i + 1] =
-                MHD__gnutls_cert_type2num (session->internals.
-                                           priorities.cert_type.priority[i]);
+                MHD__gnutls_cert_type2num (session->internals.priorities.
+                                           cert_type.priority[i]);
             }
           return len + 1;
         }
@@ -203,8 +203,8 @@
             }
 
           data[0] =
-            MHD__gnutls_cert_type2num (session->
-                                       security_parameters.cert_type);
+            MHD__gnutls_cert_type2num (session->security_parameters.
+                                       cert_type);
           return len;
         }
 

Modified: libmicrohttpd/src/daemon/https/tls/ext_max_record.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/ext_max_record.c 2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/ext_max_record.c 2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -121,8 +121,8 @@
             }
 
           data[0] =
-            (uint8_t) MHD_gtls_mre_record2num (session->internals.
-                                               proposed_record_size);
+            (uint8_t) MHD_gtls_mre_record2num (session->
+                                               internals.proposed_record_size);
           return len;
         }
 

Modified: libmicrohttpd/src/daemon/https/tls/ext_server_name.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/ext_server_name.c        2008-11-17 
07:49:16 UTC (rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/ext_server_name.c        2008-11-17 
07:50:59 UTC (rev 7932)
@@ -104,12 +104,12 @@
             case 0:            /* NAME_DNS */
               if (len <= MAX_SERVER_NAME_SIZE)
                 {
-                  memcpy (session->security_parameters.extensions.
-                          server_names[i].name, p, len);
-                  session->security_parameters.extensions.
-                    server_names[i].name_length = len;
-                  session->security_parameters.extensions.
-                    server_names[i].type = GNUTLS_NAME_DNS;
+                  memcpy (session->security_parameters.
+                          extensions.server_names[i].name, p, len);
+                  session->security_parameters.extensions.server_names[i].
+                    name_length = len;
+                  session->security_parameters.extensions.server_names[i].
+                    type = GNUTLS_NAME_DNS;
                   break;
                 }
             }
@@ -150,8 +150,8 @@
           /* count the total size
            */
           len =
-            session->security_parameters.extensions.server_names[i].
-            name_length;
+            session->security_parameters.extensions.
+            server_names[i].name_length;
 
           /* uint8_t + uint16_t + size
            */
@@ -170,14 +170,14 @@
            i < session->security_parameters.extensions.server_names_size; i++)
         {
 
-          switch (session->security_parameters.extensions.
-                  server_names[i].type)
+          switch (session->security_parameters.extensions.server_names[i].
+                  type)
             {
             case GNUTLS_NAME_DNS:
 
               len =
-                session->security_parameters.extensions.
-                server_names[i].name_length;
+                session->security_parameters.extensions.server_names[i].
+                name_length;
               if (len == 0)
                 break;
 
@@ -195,8 +195,8 @@
               p += 2;
 
               memcpy (p,
-                      session->security_parameters.extensions.
-                      server_names[0].name, len);
+                      session->security_parameters.extensions.server_names[0].
+                      name, len);
               p += len;
               break;
             default:

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_algorithms.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_algorithms.c      2008-11-17 
07:49:16 UTC (rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_algorithms.c      2008-11-17 
07:50:59 UTC (rev 7932)
@@ -1339,8 +1339,8 @@
   for (i = j = 0; i < SUPPORTED_COMPRESSION_METHODS; i++)
     {
       int tmp =
-        MHD_gtls_compression_get_num (session->internals.priorities.
-                                      compression.priority[i]);
+        MHD_gtls_compression_get_num (session->internals.
+                                      priorities.compression.priority[i]);
 
       /* remove private compression algorithms, if requested.
        */

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_auth.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_auth.c    2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_auth.c    2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -166,8 +166,9 @@
 
   return
     MHD_gtls_map_kx_get_cred (MHD_gtls_cipher_suite_get_kx_algo
-                              (&session->security_parameters.
-                               current_cipher_suite), server);
+                              (&session->
+                               security_parameters.current_cipher_suite),
+                              server);
 }
 
 /*

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_buffers.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_buffers.c 2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_buffers.c 2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -738,9 +738,9 @@
               session->internals.record_send_buffer_prev_size += n - left;
 
               retval =
-                MHD__gnutls_buffer_insert (&session->
-                                           internals.record_send_buffer,
-                                           &ptr[n - left], left);
+                MHD__gnutls_buffer_insert (&session->internals.
+                                           record_send_buffer, &ptr[n - left],
+                                           left);
               if (retval < 0)
                 {
                   MHD_gnutls_assert ();
@@ -948,8 +948,8 @@
               MHD_gnutls_assert ();
 
               retval =
-                MHD__gnutls_buffer_insert (&session->internals.
-                                           handshake_send_buffer,
+                MHD__gnutls_buffer_insert (&session->
+                                           internals.handshake_send_buffer,
                                            &ptr[n - left], left);
               if (retval < 0)
                 {
@@ -1051,8 +1051,9 @@
 
               session->internals.handshake_recv_buffer.data
                 =
-                MHD_gtls_realloc_fast (session->internals.
-                                       handshake_recv_buffer.data, dsize);
+                MHD_gtls_realloc_fast (session->
+                                       internals.handshake_recv_buffer.data,
+                                       dsize);
               if (session->internals.handshake_recv_buffer.data == NULL)
                 {
                   MHD_gnutls_assert ();
@@ -1103,13 +1104,9 @@
 
   if ((session->internals.max_handshake_data_buffer_size > 0) && ((length
                                                                    +
-                                                                   session->
-                                                                   internals.
-                                                                   
handshake_hash_buffer.
-                                                                   length) >
-                                                                  session->
-                                                                  internals.
-                                                                  
max_handshake_data_buffer_size))
+                                                                   
session->internals.handshake_hash_buffer.length)
+                                                                  >
+                                                                  
session->internals.max_handshake_data_buffer_size))
     {
       MHD_gnutls_assert ();
       return GNUTLS_E_MEMORY_ERROR;

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_cipher.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_cipher.c  2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_cipher.c  2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -302,15 +302,15 @@
   uint8_t type = _type;
   uint8_t major, minor;
   int hash_size =
-    MHD_gnutls_hash_get_algo_len (session->security_parameters.
-                                  write_mac_algorithm);
+    MHD_gnutls_hash_get_algo_len (session->
+                                  security_parameters.write_mac_algorithm);
   enum MHD_GNUTLS_Protocol ver;
   int blocksize =
-    MHD_gtls_cipher_get_block_size (session->security_parameters.
-                                    write_bulk_cipher_algorithm);
+    MHD_gtls_cipher_get_block_size (session->
+                                    
security_parameters.write_bulk_cipher_algorithm);
   cipher_type_t block_algo =
-    MHD_gtls_cipher_is_block (session->security_parameters.
-                              write_bulk_cipher_algorithm);
+    MHD_gtls_cipher_is_block (session->
+                              security_parameters.write_bulk_cipher_algorithm);
   opaque *data_ptr;
 
 
@@ -337,8 +337,9 @@
   if (td != GNUTLS_MAC_FAILED)
     {                           /* actually when the algorithm in not the NULL 
one */
       MHD_gnutls_hash (td,
-                       UINT64DATA (session->connection_state.
-                                   write_sequence_number), 8);
+                       UINT64DATA (session->
+                                   connection_state.write_sequence_number),
+                       8);
 
       MHD_gnutls_hash (td, &type, 1);
       if (ver >= MHD_GNUTLS_PROTOCOL_TLS1_0)
@@ -432,16 +433,16 @@
   uint8_t major, minor;
   enum MHD_GNUTLS_Protocol ver;
   int hash_size =
-    MHD_gnutls_hash_get_algo_len (session->security_parameters.
-                                  read_mac_algorithm);
+    MHD_gnutls_hash_get_algo_len (session->
+                                  security_parameters.read_mac_algorithm);
 
   ver = MHD__gnutls_protocol_get_version (session);
   minor = MHD_gtls_version_get_minor (ver);
   major = MHD_gtls_version_get_major (ver);
 
   blocksize =
-    MHD_gtls_cipher_get_block_size (session->security_parameters.
-                                    read_bulk_cipher_algorithm);
+    MHD_gtls_cipher_get_block_size (session->
+                                    
security_parameters.read_bulk_cipher_algorithm);
 
   /* initialize MAC
    */
@@ -465,9 +466,9 @@
     {
     case CIPHER_STREAM:
       if ((ret =
-           MHD_gtls_cipher_decrypt (session->connection_state.
-                                    read_cipher_state, ciphertext.data,
-                                    ciphertext.size)) < 0)
+           MHD_gtls_cipher_decrypt (session->
+                                    connection_state.read_cipher_state,
+                                    ciphertext.data, ciphertext.size)) < 0)
         {
           MHD_gnutls_assert ();
           return ret;
@@ -484,9 +485,9 @@
         }
 
       if ((ret =
-           MHD_gtls_cipher_decrypt (session->connection_state.
-                                    read_cipher_state, ciphertext.data,
-                                    ciphertext.size)) < 0)
+           MHD_gtls_cipher_decrypt (session->
+                                    connection_state.read_cipher_state,
+                                    ciphertext.data, ciphertext.size)) < 0)
         {
           MHD_gnutls_assert ();
           return ret;
@@ -544,8 +545,8 @@
   if (td != GNUTLS_MAC_FAILED)
     {
       MHD_gnutls_hash (td,
-                       UINT64DATA (session->connection_state.
-                                   read_sequence_number), 8);
+                       UINT64DATA (session->
+                                   connection_state.read_sequence_number), 8);
 
       MHD_gnutls_hash (td, &type, 1);
       if (ver >= MHD_GNUTLS_PROTOCOL_TLS1_0)

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_constate.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_constate.c        2008-11-17 
07:49:16 UTC (rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_constate.c        2008-11-17 
07:50:59 UTC (rev 7932)
@@ -105,10 +105,9 @@
     {                           /* TLS 1.0 */
       ret =
         MHD_gtls_PRF (session,
-                      (const unsigned char *) session->
-                      security_parameters.master_secret, TLS_MASTER_SIZE,
-                      keyexp, keyexp_length, rnd, 2 * TLS_RANDOM_SIZE,
-                      block_size, key_block);
+                      (const unsigned char *) session->security_parameters.
+                      master_secret, TLS_MASTER_SIZE, keyexp, keyexp_length,
+                      rnd, 2 * TLS_RANDOM_SIZE, block_size, key_block);
     }
 
   if (ret < 0)
@@ -507,35 +506,35 @@
     {
       rc = MHD_gtls_set_read_cipher (session,
                                      MHD_gtls_cipher_suite_get_cipher_algo
-                                     (&session->security_parameters.
-                                      current_cipher_suite));
+                                     (&session->
+                                      
security_parameters.current_cipher_suite));
       if (rc < 0)
         return rc;
       rc = MHD_gtls_set_read_mac (session,
                                   MHD_gtls_cipher_suite_get_mac_algo
-                                  (&session->security_parameters.
-                                   current_cipher_suite));
+                                  (&session->
+                                   security_parameters.current_cipher_suite));
       if (rc < 0)
         return rc;
 
       rc = MHD_gtls_set_kx (session,
                             MHD_gtls_cipher_suite_get_kx_algo
-                            (&session->security_parameters.
-                             current_cipher_suite));
+                            (&session->
+                             security_parameters.current_cipher_suite));
       if (rc < 0)
         return rc;
 
       rc = MHD_gtls_set_read_compression (session,
-                                          session->internals.
-                                          compression_method);
+                                          session->
+                                          internals.compression_method);
       if (rc < 0)
         return rc;
     }
   else
     {                           /* RESUME_TRUE */
       MHD__gnutls_cpy_read_security_parameters (&session->security_parameters,
-                                                &session->internals.
-                                                resumed_security_parameters);
+                                                &session->
+                                                
internals.resumed_security_parameters);
     }
 
 
@@ -546,8 +545,8 @@
   MHD__gnutls_handshake_log ("HSK[%x]: Cipher Suite: %s\n",
                              session,
                              MHD_gtls_cipher_suite_get_name
-                             (&session->security_parameters.
-                              current_cipher_suite));
+                             (&session->
+                              security_parameters.current_cipher_suite));
 
   if (MHD_gtls_compression_is_ok
       (session->security_parameters.read_compression_algorithm) != 0)
@@ -577,8 +576,8 @@
 
 
   mac_size =
-    MHD_gnutls_hash_get_algo_len (session->security_parameters.
-                                  read_mac_algorithm);
+    MHD_gnutls_hash_get_algo_len (session->
+                                  security_parameters.read_mac_algorithm);
 
   MHD__gnutls_handshake_log
     ("HSK[%x]: Initializing internal [read] cipher sessions\n", session);
@@ -589,8 +588,8 @@
       /* initialize cipher session
        */
       session->connection_state.read_cipher_state =
-        MHD_gtls_cipher_init (session->security_parameters.
-                              read_bulk_cipher_algorithm,
+        MHD_gtls_cipher_init (session->
+                              security_parameters.read_bulk_cipher_algorithm,
                               &session->cipher_specs.client_write_key,
                               &session->cipher_specs.client_write_IV);
       if (session->connection_state.read_cipher_state == GNUTLS_CIPHER_FAILED
@@ -621,8 +620,8 @@
 #if MHD_DEBUG_TLS
     case GNUTLS_CLIENT:
       session->connection_state.read_cipher_state =
-        MHD_gtls_cipher_init (session->security_parameters.
-                              read_bulk_cipher_algorithm,
+        MHD_gtls_cipher_init (session->
+                              security_parameters.read_bulk_cipher_algorithm,
                               &session->cipher_specs.server_write_key,
                               &session->cipher_specs.server_write_IV);
 
@@ -658,8 +657,8 @@
     }
 
   session->connection_state.read_compression_state =
-    MHD_gtls_comp_init (session->security_parameters.
-                        read_compression_algorithm, 1);
+    MHD_gtls_comp_init (session->
+                        security_parameters.read_compression_algorithm, 1);
 
   if (session->connection_state.read_compression_state == GNUTLS_COMP_FAILED)
     {
@@ -690,27 +689,27 @@
     {
       rc = MHD_gtls_set_write_cipher (session,
                                       MHD_gtls_cipher_suite_get_cipher_algo
-                                      (&session->security_parameters.
-                                       current_cipher_suite));
+                                      (&session->
+                                       
security_parameters.current_cipher_suite));
       if (rc < 0)
         return rc;
       rc = MHD_gtls_set_write_mac (session,
                                    MHD_gtls_cipher_suite_get_mac_algo
-                                   (&session->security_parameters.
-                                    current_cipher_suite));
+                                   (&session->
+                                    security_parameters.current_cipher_suite));
       if (rc < 0)
         return rc;
 
       rc = MHD_gtls_set_kx (session,
                             MHD_gtls_cipher_suite_get_kx_algo
-                            (&session->security_parameters.
-                             current_cipher_suite));
+                            (&session->
+                             security_parameters.current_cipher_suite));
       if (rc < 0)
         return rc;
 
       rc = MHD_gtls_set_write_compression (session,
-                                           session->internals.
-                                           compression_method);
+                                           session->
+                                           internals.compression_method);
       if (rc < 0)
         return rc;
     }
@@ -727,8 +726,8 @@
 
   MHD__gnutls_handshake_log ("HSK[%x]: Cipher Suite: %s\n", session,
                              MHD_gtls_cipher_suite_get_name
-                             (&session->security_parameters.
-                              current_cipher_suite));
+                             (&session->
+                              security_parameters.current_cipher_suite));
 
   if (MHD_gtls_compression_is_ok
       (session->security_parameters.write_compression_algorithm) != 0)
@@ -759,8 +758,8 @@
                           0);
 
   mac_size =
-    MHD_gnutls_hash_get_algo_len (session->security_parameters.
-                                  write_mac_algorithm);
+    MHD_gnutls_hash_get_algo_len (session->
+                                  security_parameters.write_mac_algorithm);
 
   MHD__gnutls_handshake_log
     ("HSK[%x]: Initializing internal [write] cipher sessions\n", session);
@@ -771,8 +770,8 @@
       /* initialize cipher session
        */
       session->connection_state.write_cipher_state =
-        MHD_gtls_cipher_init (session->security_parameters.
-                              write_bulk_cipher_algorithm,
+        MHD_gtls_cipher_init (session->
+                              security_parameters.write_bulk_cipher_algorithm,
                               &session->cipher_specs.server_write_key,
                               &session->cipher_specs.server_write_IV);
 
@@ -807,8 +806,8 @@
 #if MHD_DEBUG_TLS
     case GNUTLS_CLIENT:
       session->connection_state.write_cipher_state =
-        MHD_gtls_cipher_init (session->security_parameters.
-                              write_bulk_cipher_algorithm,
+        MHD_gtls_cipher_init (session->
+                              security_parameters.write_bulk_cipher_algorithm,
                               &session->cipher_specs.client_write_key,
                               &session->cipher_specs.client_write_IV);
 
@@ -844,8 +843,8 @@
 
 
   session->connection_state.write_compression_state =
-    MHD_gtls_comp_init (session->security_parameters.
-                        write_compression_algorithm, 0);
+    MHD_gtls_comp_init (session->
+                        security_parameters.write_compression_algorithm, 0);
 
   if (session->connection_state.write_compression_state == GNUTLS_COMP_FAILED)
     {

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_extensions.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_extensions.c      2008-11-17 
07:49:16 UTC (rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_extensions.c      2008-11-17 
07:50:59 UTC (rev 7932)
@@ -204,8 +204,9 @@
     {
       if (session->internals.extensions_sent_size < MAX_EXT_TYPES)
         {
-          session->internals.extensions_sent[session->internals.
-                                             extensions_sent_size] = type;
+          session->internals.extensions_sent[session->
+                                             internals.extensions_sent_size] =
+            type;
           session->internals.extensions_sent_size++;
         }
       else

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_handshake.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_handshake.c       2008-11-17 
07:49:16 UTC (rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_handshake.c       2008-11-17 
07:50:59 UTC (rev 7932)
@@ -119,8 +119,8 @@
    * hello message.
    */
   memcpy (session->security_parameters.current_cipher_suite.suite,
-          session->internals.resumed_security_parameters.
-          current_cipher_suite.suite, 2);
+          session->internals.resumed_security_parameters.current_cipher_suite.
+          suite, 2);
 
   session->internals.compression_method =
     session->internals.resumed_security_parameters.read_compression_algorithm;
@@ -132,8 +132,9 @@
     session->internals.resumed_security_parameters.entity;
 
   MHD_gtls_set_current_version (session,
-                                session->internals.
-                                resumed_security_parameters.version);
+                                session->
+                                internals.resumed_security_parameters.
+                                version);
 
   session->security_parameters.cert_type =
     session->internals.resumed_security_parameters.cert_type;
@@ -216,11 +217,13 @@
   MHD_gnutls_hash (td_sha, mesg, siz);
 
   MHD_gnutls_mac_deinit_ssl3_handshake (td_md5, ret,
-                                        session->security_parameters.
-                                        master_secret, TLS_MASTER_SIZE);
+                                        session->
+                                        security_parameters.master_secret,
+                                        TLS_MASTER_SIZE);
   MHD_gnutls_mac_deinit_ssl3_handshake (td_sha, &ret[16],
-                                        session->security_parameters.
-                                        master_secret, TLS_MASTER_SIZE);
+                                        session->
+                                        security_parameters.master_secret,
+                                        TLS_MASTER_SIZE);
 
   return 0;
 }
@@ -438,8 +441,8 @@
   else
     {
       MHD_gtls_generate_session_id (session->security_parameters.session_id,
-                                    &session->security_parameters.
-                                    session_id_size);
+                                    &session->
+                                    security_parameters.session_id_size);
 
       session->internals.resumed = RESUME_FALSE;
     }
@@ -796,9 +799,9 @@
    */
   if (MHD_gtls_get_kx_cred
       (session,
-       MHD_gtls_cipher_suite_get_kx_algo (&session->security_parameters.
-                                          current_cipher_suite), &err) == NULL
-      && err != 0)
+       MHD_gtls_cipher_suite_get_kx_algo (&session->
+                                          
security_parameters.current_cipher_suite),
+       &err) == NULL && err != 0)
     {
       MHD_gnutls_assert ();
       return GNUTLS_E_INSUFFICIENT_CREDENTIALS;
@@ -811,8 +814,8 @@
    */
   session->internals.auth_struct =
     MHD_gtls_kx_auth_struct (MHD_gtls_cipher_suite_get_kx_algo
-                             (&session->security_parameters.
-                              current_cipher_suite));
+                             (&session->
+                              security_parameters.current_cipher_suite));
   if (session->internals.auth_struct == NULL)
     {
 
@@ -861,8 +864,8 @@
 
               MHD__gnutls_handshake_log
                 ("HSK[%x]: Selected Compression Method: %s\n", session,
-                 MHD_gtls_compression_get_name (session->internals.
-                                                compression_method));
+                 MHD_gtls_compression_get_name (session->
+                                                internals.compression_method));
 
 
               return 0;
@@ -1026,8 +1029,8 @@
   if (session->internals.handshake_header_buffer.header_size ==
       handshake_header_size || (session->internals.v2_hello != 0
                                 && type == GNUTLS_HANDSHAKE_CLIENT_HELLO
-                                && session->internals.
-                                handshake_header_buffer.packet_length > 0))
+                                && session->internals.handshake_header_buffer.
+                                packet_length > 0))
     {
 
       *recv_type = session->internals.handshake_header_buffer.recv_type;
@@ -1070,11 +1073,13 @@
         MHD_gtls_handshake_io_recv_int (session, GNUTLS_HANDSHAKE,
                                         type,
                                         &dataptr
-                                        [session->internals.
-                                         handshake_header_buffer.header_size],
+                                        [session->
+                                         internals.handshake_header_buffer.
+                                         header_size],
                                         HANDSHAKE_HEADER_SIZE -
-                                        session->internals.
-                                        handshake_header_buffer.header_size);
+                                        session->
+                                        internals.handshake_header_buffer.
+                                        header_size);
       if (ret <= 0)
         {
           MHD_gnutls_assert ();
@@ -1257,11 +1262,12 @@
 
 
   ret = MHD__gnutls_handshake_hash_add_recvd (session, recv_type,
-                                              session->internals.
-                                              handshake_header_buffer.header,
-                                              session->internals.
-                                              
handshake_header_buffer.header_size,
-                                              dataptr, length32);
+                                              session->
+                                              
internals.handshake_header_buffer.
+                                              header,
+                                              session->
+                                              
internals.handshake_header_buffer.
+                                              header_size, dataptr, length32);
   if (ret < 0)
     {
       MHD_gnutls_assert ();
@@ -1355,8 +1361,8 @@
 
   MHD__gnutls_handshake_log ("HSK[%x]: Selected cipher suite: %s\n", session,
                              MHD_gtls_cipher_suite_get_name
-                             (&session->security_parameters.
-                              current_cipher_suite));
+                             (&session->
+                              security_parameters.current_cipher_suite));
 
 
   /* check if the credentials (username, public key etc.) are ok.
@@ -1379,8 +1385,8 @@
    */
   session->internals.auth_struct =
     MHD_gtls_kx_auth_struct (MHD_gtls_cipher_suite_get_kx_algo
-                             (&session->security_parameters.
-                              current_cipher_suite));
+                             (&session->
+                              security_parameters.current_cipher_suite));
 
   if (session->internals.auth_struct == NULL)
     {
@@ -1954,8 +1960,8 @@
       pos += 2;
 
       comp =
-        (uint8_t) MHD_gtls_compression_get_num (session->
-                                                internals.compression_method);
+        (uint8_t) MHD_gtls_compression_get_num (session->internals.
+                                                compression_method);
       data[pos++] = comp;
 
 

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_kx.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_kx.c      2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_kx.c      2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -65,13 +65,13 @@
                         MHD_gtls_bin2hex (PREMASTER.data, PREMASTER.size, buf,
                                           sizeof (buf)));
   MHD__gnutls_hard_log ("INT: CLIENT RANDOM[%d]: %s\n", 32,
-                        MHD_gtls_bin2hex (session->security_parameters.
-                                          client_random, 32, buf,
-                                          sizeof (buf)));
+                        MHD_gtls_bin2hex (session->
+                                          security_parameters.client_random,
+                                          32, buf, sizeof (buf)));
   MHD__gnutls_hard_log ("INT: SERVER RANDOM[%d]: %s\n", 32,
-                        MHD_gtls_bin2hex (session->security_parameters.
-                                          server_random, 32, buf,
-                                          sizeof (buf)));
+                        MHD_gtls_bin2hex (session->
+                                          security_parameters.server_random,
+                                          32, buf, sizeof (buf)));
 
   if (MHD__gnutls_protocol_get_version (session) == MHD_GNUTLS_PROTOCOL_SSL3)
     {
@@ -86,8 +86,8 @@
         MHD_gnutls_ssl3_generate_random (PREMASTER.data, PREMASTER.size,
                                          rnd, 2 * TLS_RANDOM_SIZE,
                                          TLS_MASTER_SIZE,
-                                         session->security_parameters.
-                                         master_secret);
+                                         session->
+                                         security_parameters.master_secret);
 
     }
   else if (session->security_parameters.extensions.oprfi_client_len > 0 &&
@@ -107,21 +107,25 @@
         }
 
       MHD__gnutls_hard_log ("INT: CLIENT OPRFI[%d]: %s\n",
-                            session->security_parameters.
-                            extensions.oprfi_server_len,
-                            MHD_gtls_bin2hex (session->security_parameters.
-                                              extensions.oprfi_client,
-                                              session->security_parameters.
-                                              extensions.oprfi_client_len,
-                                              buf, sizeof (buf)));
+                            session->security_parameters.extensions.
+                            oprfi_server_len,
+                            MHD_gtls_bin2hex (session->
+                                              security_parameters.extensions.
+                                              oprfi_client,
+                                              session->
+                                              security_parameters.extensions.
+                                              oprfi_client_len, buf,
+                                              sizeof (buf)));
       MHD__gnutls_hard_log ("INT: SERVER OPRFI[%d]: %s\n",
-                            session->security_parameters.
-                            extensions.oprfi_server_len,
-                            MHD_gtls_bin2hex (session->security_parameters.
-                                              extensions.oprfi_server,
-                                              session->security_parameters.
-                                              extensions.oprfi_server_len,
-                                              buf, sizeof (buf)));
+                            session->security_parameters.extensions.
+                            oprfi_server_len,
+                            MHD_gtls_bin2hex (session->
+                                              security_parameters.extensions.
+                                              oprfi_server,
+                                              session->
+                                              security_parameters.extensions.
+                                              oprfi_server_len, buf,
+                                              sizeof (buf)));
 
       memcpy (rnd, session->security_parameters.client_random,
               TLS_RANDOM_SIZE);
@@ -171,8 +175,9 @@
     return ret;
 
   MHD__gnutls_hard_log ("INT: MASTER SECRET: %s\n",
-                        MHD_gtls_bin2hex (session->security_parameters.
-                                          master_secret, TLS_MASTER_SIZE, buf,
+                        MHD_gtls_bin2hex (session->
+                                          security_parameters.master_secret,
+                                          TLS_MASTER_SIZE, buf,
                                           sizeof (buf)));
 
   return ret;
@@ -239,8 +244,8 @@
   int data_size = 0;
   int ret = 0;
 
-  if (session->internals.auth_struct->
-      MHD_gtls_gen_server_certificate_request == NULL)
+  if (session->internals.
+      auth_struct->MHD_gtls_gen_server_certificate_request == NULL)
     return 0;
 
   if (session->internals.send_cert_req <= 0)
@@ -252,8 +257,8 @@
   if (again == 0)
     {
       data_size =
-        session->internals.auth_struct->
-        MHD_gtls_gen_server_certificate_request (session, &data);
+        session->internals.
+        auth_struct->MHD_gtls_gen_server_certificate_request (session, &data);
 
       if (data_size < 0)
         {
@@ -352,8 +357,8 @@
   if (again == 0)
     {
       data_size =
-        session->internals.auth_struct->
-        MHD_gtls_gen_client_cert_vrfy (session, &data);
+        session->internals.
+        auth_struct->MHD_gtls_gen_client_cert_vrfy (session, &data);
       if (data_size < 0)
         {
           MHD_gnutls_assert ();
@@ -425,8 +430,8 @@
   int datasize;
   int ret = 0;
 
-  if (session->internals.auth_struct->
-      MHD_gtls_process_server_certificate_request != NULL)
+  if (session->internals.
+      auth_struct->MHD_gtls_process_server_certificate_request != NULL)
     {
 
       ret =
@@ -441,8 +446,10 @@
         return 0;               /* ignored */
 
       ret =
-        session->internals.auth_struct->
-        MHD_gtls_process_server_certificate_request (session, data, datasize);
+        session->internals.
+        auth_struct->MHD_gtls_process_server_certificate_request (session,
+                                                                  data,
+                                                                  datasize);
       MHD_gnutls_free (data);
       if (ret < 0)
         return ret;
@@ -513,8 +520,8 @@
           /* TLS 1.0 or SSL 3.0 with a valid certificate
            */
           data_size =
-            session->internals.auth_struct->
-            MHD_gtls_gen_client_certificate (session, &data);
+            session->internals.
+            auth_struct->MHD_gtls_gen_client_certificate (session, &data);
 
           if (data_size < 0)
             {
@@ -574,8 +581,8 @@
   if (again == 0)
     {
       data_size =
-        session->internals.auth_struct->
-        MHD_gtls_gen_server_certificate (session, &data);
+        session->internals.
+        auth_struct->MHD_gtls_gen_server_certificate (session, &data);
 
       if (data_size < 0)
         {
@@ -671,8 +678,9 @@
           return 0;
         }
       ret =
-        session->internals.auth_struct->
-        MHD_gtls_process_client_certificate (session, data, datasize);
+        session->internals.
+        auth_struct->MHD_gtls_process_client_certificate (session, data,
+                                                          datasize);
 
       MHD_gnutls_free (data);
       if (ret < 0 && ret != GNUTLS_E_NO_CERTIFICATE_FOUND)
@@ -716,8 +724,9 @@
         }
 
       ret =
-        session->internals.auth_struct->
-        MHD_gtls_process_server_certificate (session, data, datasize);
+        session->internals.
+        auth_struct->MHD_gtls_process_server_certificate (session, data,
+                                                          datasize);
       MHD_gnutls_free (data);
       if (ret < 0)
         {
@@ -768,8 +777,9 @@
         }
 
       ret =
-        session->internals.auth_struct->
-        MHD_gtls_process_client_cert_vrfy (session, data, datasize);
+        session->internals.
+        auth_struct->MHD_gtls_process_client_cert_vrfy (session, data,
+                                                        datasize);
       MHD_gnutls_free (data);
       if (ret < 0)
         return ret;

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_record.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_record.c  2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_record.c  2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -294,8 +294,8 @@
 
   MHD__gnutls_record_log
     ("REC[%x]: Sending Packet[%d] %s(%d) with length: %d\n", session,
-     (int) MHD_gtls_uint64touint32 (&session->connection_state.
-                                    write_sequence_number),
+     (int) MHD_gtls_uint64touint32 (&session->
+                                    connection_state.write_sequence_number),
      MHD__gnutls_packet2str (type), type, sizeofdata);
 
   if (sizeofdata > MAX_RECORD_SEND_SIZE)
@@ -860,13 +860,13 @@
 
   MHD__gnutls_record_log
     ("REC[%x]: Expected Packet[%d] %s(%d) with length: %d\n", session,
-     (int) MHD_gtls_uint64touint32 (&session->connection_state.
-                                    read_sequence_number),
+     (int) MHD_gtls_uint64touint32 (&session->
+                                    connection_state.read_sequence_number),
      MHD__gnutls_packet2str (type), type, sizeofdata);
   MHD__gnutls_record_log
     ("REC[%x]: Received Packet[%d] %s(%d) with length: %d\n", session,
-     (int) MHD_gtls_uint64touint32 (&session->connection_state.
-                                    read_sequence_number),
+     (int) MHD_gtls_uint64touint32 (&session->
+                                    connection_state.read_sequence_number),
      MHD__gnutls_packet2str (recv_type), recv_type, length);
 
   if (length > MAX_RECV_SIZE)
@@ -942,8 +942,8 @@
 
   MHD__gnutls_record_log
     ("REC[%x]: Decrypted Packet[%d] %s(%d) with length: %d\n", session,
-     (int) MHD_gtls_uint64touint32 (&session->connection_state.
-                                    read_sequence_number),
+     (int) MHD_gtls_uint64touint32 (&session->
+                                    connection_state.read_sequence_number),
      MHD__gnutls_packet2str (recv_type), recv_type, decrypted_length);
 
   /* increase sequence number

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_sig.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_sig.c     2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_sig.c     2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -75,8 +75,9 @@
         }
 
       MHD_gnutls_mac_deinit_ssl3_handshake (td_sha, &concat[16],
-                                            session->security_parameters.
-                                            master_secret, TLS_MASTER_SIZE);
+                                            session->
+                                            security_parameters.master_secret,
+                                            TLS_MASTER_SIZE);
     }
   else
     MHD_gnutls_hash_deinit (td_sha, &concat[16]);
@@ -94,8 +95,9 @@
 
       if (ver == MHD_GNUTLS_PROTOCOL_SSL3)
         MHD_gnutls_mac_deinit_ssl3_handshake (td_md5, concat,
-                                              session->security_parameters.
-                                              master_secret, TLS_MASTER_SIZE);
+                                              session->
+                                              
security_parameters.master_secret,
+                                              TLS_MASTER_SIZE);
       else
         MHD_gnutls_hash_deinit (td_md5, concat);
 
@@ -265,8 +267,8 @@
         return GNUTLS_E_INSUFFICIENT_CREDENTIALS;
 
       return (*session->internals.sign_func) (session,
-                                              session->internals.
-                                              sign_func_userdata,
+                                              session->
+                                              internals.sign_func_userdata,
                                               cert->cert_type, &cert->raw,
                                               hash_concat, signature);
     }
@@ -365,11 +367,13 @@
         }
 
       MHD_gnutls_mac_deinit_ssl3_handshake (td_md5, concat,
-                                            session->security_parameters.
-                                            master_secret, TLS_MASTER_SIZE);
+                                            session->
+                                            security_parameters.master_secret,
+                                            TLS_MASTER_SIZE);
       MHD_gnutls_mac_deinit_ssl3_handshake (td_sha, &concat[16],
-                                            session->security_parameters.
-                                            master_secret, TLS_MASTER_SIZE);
+                                            session->
+                                            security_parameters.master_secret,
+                                            TLS_MASTER_SIZE);
     }
   else
     {

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_state.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_state.c   2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_state.c   2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -806,8 +806,8 @@
   enum MHD_GNUTLS_CipherAlgorithm cipher;
 
   cipher =
-    MHD_gtls_cipher_suite_get_cipher_algo (&session->security_parameters.
-                                           current_cipher_suite);
+    MHD_gtls_cipher_suite_get_cipher_algo (&session->
+                                           
security_parameters.current_cipher_suite);
 
   if (MHD_gtls_cipher_get_export_flag (cipher) != 0)
     return 1;

Modified: libmicrohttpd/src/daemon/https/tls/gnutls_x509.c
===================================================================
--- libmicrohttpd/src/daemon/https/tls/gnutls_x509.c    2008-11-17 07:49:16 UTC 
(rev 7931)
+++ libmicrohttpd/src/daemon/https/tls/gnutls_x509.c    2008-11-17 07:50:59 UTC 
(rev 7932)
@@ -113,8 +113,8 @@
                                                1].params_size, &kid);
 
 
-  MHD__gnutls_x509_write_rsa_params (res->
-                                     cert_list[res->ncerts - 1][0].params,
+  MHD__gnutls_x509_write_rsa_params (res->cert_list[res->ncerts - 1][0].
+                                     params,
                                      res->cert_list[res->ncerts -
                                                     1][0].params_size, &cid);
 





reply via email to

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