FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
tls_openssl.c File Reference
+ Include dependency graph for tls_openssl.c:

Go to the source code of this file.

Macros

#define MAX_CRYPTO_LEN   64
 

Functions

static u32 openssl_ctx_alloc_w_thread (u32 thread_index)
 
static u32 openssl_ctx_alloc (void)
 
static void openssl_ctx_free (tls_ctx_t *ctx)
 
static void * openssl_ctx_detach (tls_ctx_t *ctx)
 
static u32 openssl_ctx_attach (u32 thread_index, void *ctx_ptr)
 
tls_ctx_topenssl_ctx_get (u32 ctx_index)
 
tls_ctx_topenssl_ctx_get_w_thread (u32 ctx_index, u8 thread_index)
 
static u32 openssl_listen_ctx_alloc (void)
 
static void openssl_listen_ctx_free (openssl_listen_ctx_t *lctx)
 
openssl_listen_ctx_topenssl_lctx_get (u32 lctx_index)
 
static int openssl_read_from_ssl_into_fifo (svm_fifo_t *f, SSL *ssl)
 
static int openssl_write_from_fifo_into_ssl (svm_fifo_t *f, SSL *ssl, u32 max_len)
 
static void openssl_handle_handshake_failure (tls_ctx_t *ctx)
 
int openssl_ctx_handshake_rx (tls_ctx_t *ctx, session_t *tls_session)
 
static void openssl_confirm_app_close (tls_ctx_t *ctx)
 
static int openssl_ctx_write_tls (tls_ctx_t *ctx, session_t *app_session, transport_send_params_t *sp)
 
static int openssl_ctx_write_dtls (tls_ctx_t *ctx, session_t *app_session, transport_send_params_t *sp)
 
static int openssl_ctx_write (tls_ctx_t *ctx, session_t *app_session, transport_send_params_t *sp)
 
static int openssl_ctx_read_tls (tls_ctx_t *ctx, session_t *tls_session)
 
static int openssl_ctx_read_dtls (tls_ctx_t *ctx, session_t *us)
 
static int openssl_ctx_read (tls_ctx_t *ctx, session_t *ts)
 
static int openssl_ctx_init_client (tls_ctx_t *ctx)
 
static int openssl_start_listen (tls_ctx_t *lctx)
 
static int openssl_stop_listen (tls_ctx_t *lctx)
 
static int openssl_ctx_init_server (tls_ctx_t *ctx)
 
static u8 openssl_handshake_is_over (tls_ctx_t *ctx)
 
static int openssl_transport_close (tls_ctx_t *ctx)
 
static int openssl_app_close (tls_ctx_t *ctx)
 
int tls_init_ca_chain (void)
 
int tls_openssl_set_ciphers (char *ciphers)
 
static clib_error_ttls_openssl_init (vlib_main_t *vm)
 
 VLIB_PLUGIN_REGISTER ()
 

Variables

openssl_main_t openssl_main
 
const static tls_engine_vft_t openssl_engine
 

Macro Definition Documentation

◆ MAX_CRYPTO_LEN

#define MAX_CRYPTO_LEN   64

Definition at line 31 of file tls_openssl.c.

Function Documentation

◆ openssl_app_close()

static int openssl_app_close ( tls_ctx_t ctx)
static

Definition at line 895 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_confirm_app_close()

static void openssl_confirm_app_close ( tls_ctx_t ctx)
static

Definition at line 364 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_ctx_alloc()

static u32 openssl_ctx_alloc ( void  )
static

Definition at line 54 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_alloc_w_thread()

static u32 openssl_ctx_alloc_w_thread ( u32  thread_index)
static

Definition at line 36 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_ctx_attach()

static u32 openssl_ctx_attach ( u32  thread_index,
void *  ctx_ptr 
)
static

Definition at line 94 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_detach()

static void* openssl_ctx_detach ( tls_ctx_t ctx)
static

Definition at line 83 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_free()

static void openssl_ctx_free ( tls_ctx_t ctx)
static

Definition at line 60 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_get()

tls_ctx_t* openssl_ctx_get ( u32  ctx_index)

Definition at line 117 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_get_w_thread()

tls_ctx_t* openssl_ctx_get_w_thread ( u32  ctx_index,
u8  thread_index 
)

Definition at line 126 of file tls_openssl.c.

+ Here is the caller graph for this function:

◆ openssl_ctx_handshake_rx()

int openssl_ctx_handshake_rx ( tls_ctx_t ctx,
session_t tls_session 
)

Definition at line 273 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_ctx_init_client()

static int openssl_ctx_init_client ( tls_ctx_t ctx)
static

Definition at line 600 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_init_server()

static int openssl_ctx_init_server ( tls_ctx_t ctx)
static

Definition at line 809 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_read()

static int openssl_ctx_read ( tls_ctx_t ctx,
session_t ts 
)
inlinestatic

Definition at line 591 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_read_dtls()

static int openssl_ctx_read_dtls ( tls_ctx_t ctx,
session_t us 
)
inlinestatic

Definition at line 530 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_ctx_read_tls()

static int openssl_ctx_read_tls ( tls_ctx_t ctx,
session_t tls_session 
)
inlinestatic

Definition at line 500 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_ctx_write()

static int openssl_ctx_write ( tls_ctx_t ctx,
session_t app_session,
transport_send_params_t sp 
)
inlinestatic

Definition at line 490 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_ctx_write_dtls()

static int openssl_ctx_write_dtls ( tls_ctx_t ctx,
session_t app_session,
transport_send_params_t sp 
)
static

Definition at line 429 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_ctx_write_tls()

static int openssl_ctx_write_tls ( tls_ctx_t ctx,
session_t app_session,
transport_send_params_t sp 
)
static

Definition at line 371 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_handle_handshake_failure()

static void openssl_handle_handshake_failure ( tls_ctx_t ctx)
static

Definition at line 244 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_handshake_is_over()

static u8 openssl_handshake_is_over ( tls_ctx_t ctx)
static

Definition at line 869 of file tls_openssl.c.

+ Here is the caller graph for this function:

◆ openssl_lctx_get()

openssl_listen_ctx_t* openssl_lctx_get ( u32  lctx_index)

Definition at line 153 of file tls_openssl.c.

+ Here is the caller graph for this function:

◆ openssl_listen_ctx_alloc()

static u32 openssl_listen_ctx_alloc ( void  )
static

Definition at line 134 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_listen_ctx_free()

static void openssl_listen_ctx_free ( openssl_listen_ctx_t lctx)
static

Definition at line 147 of file tls_openssl.c.

+ Here is the caller graph for this function:

◆ openssl_read_from_ssl_into_fifo()

static int openssl_read_from_ssl_into_fifo ( svm_fifo_t f,
SSL *  ssl 
)
static

Definition at line 159 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ openssl_start_listen()

static int openssl_start_listen ( tls_ctx_t lctx)
static

Definition at line 699 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_stop_listen()

static int openssl_stop_listen ( tls_ctx_t lctx)
static

Definition at line 791 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_transport_close()

static int openssl_transport_close ( tls_ctx_t ctx)
static

Definition at line 878 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ openssl_write_from_fifo_into_ssl()

static int openssl_write_from_fifo_into_ssl ( svm_fifo_t f,
SSL *  ssl,
u32  max_len 
)
static

Definition at line 194 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tls_init_ca_chain()

int tls_init_ca_chain ( void  )

Definition at line 930 of file tls_openssl.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tls_openssl_init()

static clib_error_t* tls_openssl_init ( vlib_main_t vm)
static

Definition at line 999 of file tls_openssl.c.

+ Here is the call graph for this function:

◆ tls_openssl_set_ciphers()

int tls_openssl_set_ciphers ( char *  ciphers)

Definition at line 978 of file tls_openssl.c.

+ Here is the caller graph for this function:

◆ VLIB_PLUGIN_REGISTER()

VLIB_PLUGIN_REGISTER ( )

Variable Documentation

◆ openssl_engine

const static tls_engine_vft_t openssl_engine
static
Initial value:
= {
.ctx_alloc = openssl_ctx_alloc,
.ctx_alloc_w_thread = openssl_ctx_alloc_w_thread,
.ctx_free = openssl_ctx_free,
.ctx_attach = openssl_ctx_attach,
.ctx_detach = openssl_ctx_detach,
.ctx_get = openssl_ctx_get,
.ctx_get_w_thread = openssl_ctx_get_w_thread,
.ctx_init_server = openssl_ctx_init_server,
.ctx_init_client = openssl_ctx_init_client,
.ctx_write = openssl_ctx_write,
.ctx_read = openssl_ctx_read,
.ctx_handshake_is_over = openssl_handshake_is_over,
.ctx_start_listen = openssl_start_listen,
.ctx_stop_listen = openssl_stop_listen,
.ctx_transport_close = openssl_transport_close,
.ctx_app_close = openssl_app_close,
}

Definition at line 910 of file tls_openssl.c.

◆ openssl_main

openssl_main_t openssl_main

Definition at line 33 of file tls_openssl.c.

openssl_start_listen
static int openssl_start_listen(tls_ctx_t *lctx)
Definition: tls_openssl.c:699
openssl_ctx_read
static int openssl_ctx_read(tls_ctx_t *ctx, session_t *ts)
Definition: tls_openssl.c:591
openssl_ctx_alloc_w_thread
static u32 openssl_ctx_alloc_w_thread(u32 thread_index)
Definition: tls_openssl.c:36
openssl_ctx_free
static void openssl_ctx_free(tls_ctx_t *ctx)
Definition: tls_openssl.c:60
openssl_transport_close
static int openssl_transport_close(tls_ctx_t *ctx)
Definition: tls_openssl.c:878
openssl_handshake_is_over
static u8 openssl_handshake_is_over(tls_ctx_t *ctx)
Definition: tls_openssl.c:869
openssl_ctx_init_client
static int openssl_ctx_init_client(tls_ctx_t *ctx)
Definition: tls_openssl.c:600
openssl_stop_listen
static int openssl_stop_listen(tls_ctx_t *lctx)
Definition: tls_openssl.c:791
openssl_ctx_init_server
static int openssl_ctx_init_server(tls_ctx_t *ctx)
Definition: tls_openssl.c:809
openssl_ctx_write
static int openssl_ctx_write(tls_ctx_t *ctx, session_t *app_session, transport_send_params_t *sp)
Definition: tls_openssl.c:490
openssl_ctx_attach
static u32 openssl_ctx_attach(u32 thread_index, void *ctx_ptr)
Definition: tls_openssl.c:94
openssl_ctx_detach
static void * openssl_ctx_detach(tls_ctx_t *ctx)
Definition: tls_openssl.c:83
openssl_ctx_get
tls_ctx_t * openssl_ctx_get(u32 ctx_index)
Definition: tls_openssl.c:117
openssl_ctx_alloc
static u32 openssl_ctx_alloc(void)
Definition: tls_openssl.c:54
openssl_ctx_get_w_thread
tls_ctx_t * openssl_ctx_get_w_thread(u32 ctx_index, u8 thread_index)
Definition: tls_openssl.c:126
openssl_app_close
static int openssl_app_close(tls_ctx_t *ctx)
Definition: tls_openssl.c:895