summaryrefslogtreecommitdiffstats
path: root/src/cmake/library.cmake
AgeCommit message (Expand)AuthorFilesLines
2021-04-30build: declare some CMake variables as advancedDamjan Marion1-0/+9
2021-04-02build: create _objs target for each libraryDamjan Marion1-3/+10
2021-02-08misc: support api generated dependency for multiarch sourceOle Troan1-1/+5
2020-11-25api: vat2 and json autogeneration for api messagesOle Troan1-0/+32
2020-11-05build: link time optimization for release buildsDamjan Marion1-1/+8
2020-10-15build: forward dependencies to arch-specific libsAloys Augustin1-1/+1
2020-05-08build: various improvementsDamjan Marion1-1/+1
2019-12-17build: export vapi generation in vpp-devOliver Giles1-1/+1
2019-09-25api: split api generated filesOle Troan1-0/+2
2019-07-25build: package .api files in vpp-devBenoît Ganne1-1/+1
2019-06-07build: add -Wall and -fno-common, fix reported issuesBenoît Ganne1-1/+0
2019-02-14Add -fno-common compile optionBenoît Ganne1-1/+1
2018-09-14cpack: add deb/rpm packaging to VPP moduleDamjan Marion1-1/+1
2018-09-14cmake: use VPP package in VOMDamjan Marion1-1/+3
2018-09-12Always use 'lib' instead of 'lib64'Damjan Marion1-1/+1
2018-09-07cmake: set packaging component for different filesDamjan Marion1-1/+5
2018-08-31cmake: detect vpp version, set soversion, pretty config printDamjan Marion1-0/+1
2018-08-30cmake: a bit of packaging workDamjan Marion1-4/+19
2018-08-28cmake: compile libs and plugins with -WallDamjan Marion1-0/+1
2018-08-27cmake: add vapi buildDamjan Marion1-1/+1
2018-08-27cmake: use lib64 for lib dirDamjan Marion1-1/+1
2018-08-26cmake: add add_vpp_library and add_vpp_executable macrosDamjan Marion1-0/+64
LS_DEBUG_LEVEL_SERVER 0 #define TLS_CHUNK_SIZE (1 << 14) #define TLS_CA_CERT_PATH "/etc/ssl/certs/ca-certificates.crt" #if TLS_DEBUG #define TLS_DBG(_lvl, _fmt, _args...) \ if (_lvl <= TLS_DEBUG) \ clib_warning (_fmt, ##_args) #else #define TLS_DBG(_lvl, _fmt, _args...) #endif /* *INDENT-OFF* */ typedef CLIB_PACKED (struct tls_cxt_id_ { u32 parent_app_wrk_index; union { session_handle_t app_session_handle; u32 parent_app_api_ctx; }; session_handle_t tls_session_handle; u32 ssl_ctx; u32 listener_ctx_index; u8 tcp_is_ip4; u8 tls_engine_id; }) tls_ctx_id_t; /* *INDENT-ON* */ STATIC_ASSERT (sizeof (tls_ctx_id_t) <= 42, "ctx id must be less than 42"); typedef struct tls_ctx_ { union { transport_connection_t connection; tls_ctx_id_t c_tls_ctx_id; }; #define parent_app_wrk_index c_tls_ctx_id.parent_app_wrk_index #define app_session_handle c_tls_ctx_id.app_session_handle #define tls_session_handle c_tls_ctx_id.tls_session_handle #define listener_ctx_index c_tls_ctx_id.listener_ctx_index #define tcp_is_ip4 c_tls_ctx_id.tcp_is_ip4 #define tls_ctx_engine c_tls_ctx_id.tls_engine_id #define tls_ssl_ctx c_tls_ctx_id.ssl_ctx #define tls_ctx_handle c_c_index /* 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 u8 is_passive_close; u8 resume; u8 *srv_hostname; } tls_ctx_t; typedef struct tls_main_ { u32 app_index; tls_ctx_t *listener_ctx_pool; tls_ctx_t *half_open_ctx_pool; clib_rwlock_t half_open_rwlock; u8 **rx_bufs; u8 **tx_bufs; /* * Config */ u8 use_test_cert_in_ca; char *ca_cert_path; } tls_main_t; typedef struct tls_engine_vft_ { u32 (*ctx_alloc) (void); void (*ctx_free) (tls_ctx_t * 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); int (*ctx_init_server) (tls_ctx_t * ctx); int (*ctx_read) (tls_ctx_t * ctx, session_t * tls_session); int (*ctx_write) (tls_ctx_t * ctx, session_t * app_session); u8 (*ctx_handshake_is_over) (tls_ctx_t * ctx); int (*ctx_start_listen) (tls_ctx_t * ctx); int (*ctx_stop_listen) (tls_ctx_t * ctx); } tls_engine_vft_t; tls_main_t *vnet_tls_get_main (void); void tls_register_engine (const tls_engine_vft_t * vft, tls_engine_type_t type); int tls_add_vpp_q_rx_evt (session_t * s); int tls_add_vpp_q_tx_evt (session_t * s); int tls_add_vpp_q_builtin_tx_evt (session_t * s); int tls_add_vpp_q_builtin_rx_evt (session_t * s); int tls_notify_app_accept (tls_ctx_t * ctx); int tls_notify_app_connected (tls_ctx_t * ctx, u8 is_failed); void tls_notify_app_enqueue (tls_ctx_t * ctx, session_t * app_session); #endif /* SRC_VNET_TLS_TLS_H_ */ /* * fd.io coding-style-patch-verification: ON * * Local Variables: * eval: (c-set-style "gnu") * End: */