aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/tls/tls.h
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2020-11-19 13:38:26 -0800
committerDave Barach <openvpp@barachs.net>2021-02-09 21:33:19 +0000
commit4b47ee26cba610b26bbfc088736846541bee7be3 (patch)
treecb6aedb8a7ba69140bda4709dbff084d91ffff90 /src/vnet/tls/tls.h
parentda2305fb874a7cf6573267adb87166564e328396 (diff)
tls: dtls initial implementation
Type: feature Basic dtls transport protocol implementation that relies on openssl wire protocol implementation. Retries/timeouts not yet supported. To test using vcl test apps, first ensure all arp entries are properly resolved and subsequently: server: vcl_server -p dtls 1234 client: vcl_client -p dtls <server-ip> 1234 -U -N 2000000 -T 1460 -X Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I04b4516a8fe9ce85ba230bcdd891f33a900046ed
Diffstat (limited to 'src/vnet/tls/tls.h')
-rw-r--r--src/vnet/tls/tls.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/vnet/tls/tls.h b/src/vnet/tls/tls.h
index d950fe82629..2038fdff133 100644
--- a/src/vnet/tls/tls.h
+++ b/src/vnet/tls/tls.h
@@ -21,7 +21,7 @@
#ifndef SRC_VNET_TLS_TLS_H_
#define SRC_VNET_TLS_TLS_H_
-#define TLS_DEBUG 0
+#define TLS_DEBUG 0
#define TLS_DEBUG_LEVEL_CLIENT 0
#define TLS_DEBUG_LEVEL_SERVER 0
@@ -49,6 +49,7 @@ typedef struct tls_cxt_id_
u32 listener_ctx_index;
u8 tcp_is_ip4;
u8 tls_engine_id;
+ void *migrate_ctx;
} tls_ctx_id_t;
/* *INDENT-ON* */
@@ -73,14 +74,17 @@ typedef struct tls_ctx_
/* Temporary storage for session open opaque. Overwritten once
* underlying tcp connection is established */
#define parent_app_api_context c_tls_ctx_id.parent_app_api_ctx
+#define migration_ctx c_tls_ctx_id.migrate_ctx
u8 is_passive_close;
u8 resume;
u8 app_closed;
u8 no_app_session;
+ u8 is_migrated;
u8 *srv_hostname;
u32 evt_index;
u32 ckpair_index;
+ transport_proto_t tls_type;
} tls_ctx_t;
typedef struct tls_main_
@@ -104,7 +108,10 @@ typedef struct tls_main_
typedef struct tls_engine_vft_
{
u32 (*ctx_alloc) (void);
+ u32 (*ctx_alloc_w_thread) (u32 thread_index);
void (*ctx_free) (tls_ctx_t * ctx);
+ void *(*ctx_detach) (tls_ctx_t *ctx);
+ u32 (*ctx_attach) (u32 thread_index, void *ctx);
tls_ctx_t *(*ctx_get) (u32 ctx_index);
tls_ctx_t *(*ctx_get_w_thread) (u32 ctx_index, u8 thread_index);
int (*ctx_init_client) (tls_ctx_t * ctx);