summaryrefslogtreecommitdiff
path: root/lib/gnutls_extensions.h
diff options
context:
space:
mode:
authorNikos <nmav@crystal.(none)>2007-12-16 10:22:00 +0200
committerNikos <nmav@crystal.(none)>2007-12-16 10:31:17 +0200
commit4da68f7a0d2b81577a1be10d0fe67290e0c6a031 (patch)
treed29c87d2e99a7eebcd3742784143af90ab01b317 /lib/gnutls_extensions.h
parent598709ed8e4198e3f8d74cddc8a5f0de91adab07 (diff)
downloadgnutls-4da68f7a0d2b81577a1be10d0fe67290e0c6a031.tar.gz
Changes for post_client_hello_function(). The extensions are now parsed in a
callback friendly way. Extensions are now split to APPLICATION and TLS layer. The APPLICATION layer extensions are parsed before the callback function is called and the others afterwards. This allows the callback to change the behavior of the TLS layer parsers by using the data of the APPLICATION layer extensions. Currently the only application layer extension is defined to be the server name indication extension.
Diffstat (limited to 'lib/gnutls_extensions.h')
-rw-r--r--lib/gnutls_extensions.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/gnutls_extensions.h b/lib/gnutls_extensions.h
index 3a7ee2f6c3..c305846c14 100644
--- a/lib/gnutls_extensions.h
+++ b/lib/gnutls_extensions.h
@@ -25,7 +25,7 @@
#include <gnutls_int.h>
const char *_gnutls_extension_get_name (uint16_t type);
-int _gnutls_parse_extensions (gnutls_session_t, const opaque *, int);
+int _gnutls_parse_extensions (gnutls_session_t, tls_ext_parse_type_t, const opaque *, int);
int _gnutls_gen_extensions (gnutls_session_t session, opaque * data,
size_t data_size);
@@ -33,12 +33,13 @@ typedef int (*ext_recv_func) (gnutls_session_t, const opaque *, size_t); /* recv
typedef int (*ext_send_func) (gnutls_session_t, opaque *, size_t); /* send data */
ext_send_func _gnutls_ext_func_send (uint16_t type);
-ext_recv_func _gnutls_ext_func_recv (uint16_t type);
+ext_recv_func _gnutls_ext_func_recv (uint16_t type, tls_ext_parse_type_t);
typedef struct
{
const char *name;
uint16_t type;
+ tls_ext_parse_type_t parse_type;
ext_recv_func gnutls_ext_func_recv;
ext_send_func gnutls_ext_func_send;
} gnutls_extension_entry;