FD.io VPP  v21.10.1-2-g0a485f517
Vector Packet Processing
quic.c File Reference
+ Include dependency graph for quic.c:

Go to the source code of this file.

Macros

#define quic_error(n, s)   s,
 
#define DEFAULT_MAX_PACKETS_PER_KEY   16777216
 

Functions

static void quic_update_timer (quic_ctx_t *ctx)
 
static void quic_check_quic_session_connected (quic_ctx_t *ctx)
 
static int quic_reset_connection (u64 udp_session_handle, quic_rx_packet_ctx_t *pctx)
 
static void quic_proto_on_close (u32 ctx_index, u32 thread_index)
 
static void quic_crypto_context_make_key_from_ctx (clib_bihash_kv_24_8_t *kv, quic_ctx_t *ctx)
 
static void quic_crypto_context_make_key_from_crctx (clib_bihash_kv_24_8_t *kv, crypto_context_t *crctx)
 
static void quic_crypto_context_free_if_needed (crypto_context_t *crctx, u8 thread_index)
 
static int quic_app_cert_key_pair_delete_callback (app_cert_key_pair_t *ckpair)
 
static crypto_context_tquic_crypto_context_alloc (u8 thread_index)
 
static crypto_context_tquic_crypto_context_get (u32 cr_index, u32 thread_index)
 
static clib_error_tquic_list_crypto_context_command_fn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static clib_error_tquic_set_max_packets_per_key_fn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static clib_error_tquic_set_cc_fn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static void quic_release_crypto_context (u32 crypto_context_index, u8 thread_index)
 
static int quic_init_crypto_context (crypto_context_t *crctx, quic_ctx_t *ctx)
 
static int quic_acquire_crypto_context (quic_ctx_t *ctx)
 
static u32 quic_ctx_alloc (u32 thread_index)
 
static void quic_ctx_free (quic_ctx_t *ctx)
 
static quic_ctx_tquic_ctx_get (u32 ctx_index, u32 thread_index)
 
static quic_ctx_tquic_ctx_get_if_valid (u32 ctx_index, u32 thread_index)
 
quic_ctx_tquic_get_conn_ctx (quicly_conn_t *conn)
 
static void quic_store_conn_ctx (quicly_conn_t *conn, quic_ctx_t *ctx)
 
static int quic_ctx_is_stream (quic_ctx_t *ctx)
 
static int quic_ctx_is_listener (quic_ctx_t *ctx)
 
static int quic_ctx_is_conn (quic_ctx_t *ctx)
 
static session_tget_stream_session_and_ctx_from_stream (quicly_stream_t *stream, quic_ctx_t **ctx)
 
static void quic_make_connection_key (clib_bihash_kv_16_8_t *kv, const quicly_cid_plaintext_t *id)
 
static int quic_sendable_packet_count (session_t *udp_session)
 
static quicly_context_t * quic_get_quicly_ctx_from_ctx (quic_ctx_t *ctx)
 
static quicly_context_t * quic_get_quicly_ctx_from_udp (u64 udp_session_handle)
 
static void quic_set_udp_tx_evt (session_t *udp_session)
 
static void quic_stop_ctx_timer (quic_ctx_t *ctx)
 
static void quic_ack_rx_data (session_t *stream_session)
 
static void quic_disconnect_transport (quic_ctx_t *ctx)
 
static void quic_connection_delete (quic_ctx_t *ctx)
 
void quic_increment_counter (u8 evt, u8 val)
 
static void quic_connection_closed (quic_ctx_t *ctx)
 Called when quicly return an error This function interacts tightly with quic_proto_on_close. More...
 
static int quic_send_datagram (session_t *udp_session, struct iovec *packet, quicly_address_t *dest, quicly_address_t *src)
 
static int quic_send_packets (quic_ctx_t *ctx)
 
static void quic_on_stream_destroy (quicly_stream_t *stream, int err)
 
static void quic_on_stop_sending (quicly_stream_t *stream, int err)
 
static void quic_on_receive_reset (quicly_stream_t *stream, int err)
 
static void quic_on_receive (quicly_stream_t *stream, size_t off, const void *src, size_t len)
 
void quic_fifo_egress_shift (quicly_stream_t *stream, size_t delta)
 
void quic_fifo_egress_emit (quicly_stream_t *stream, size_t off, void *dst, size_t *len, int *wrote_all)
 
static int quic_on_stream_open (quicly_stream_open_t *self, quicly_stream_t *stream)
 
static void quic_on_closed_by_remote (quicly_closed_by_remote_t *self, quicly_conn_t *conn, int code, uint64_t frame_type, const char *reason, size_t reason_len)
 
static int64_t quic_get_thread_time (u8 thread_index)
 
static int64_t quic_get_time (quicly_now_t *self)
 
static u32 quic_set_time_now (u32 thread_index)
 
static void quic_update_time (f64 now, u8 thread_index)
 
static void quic_timer_expired (u32 conn_index)
 
static void quic_expired_timers_dispatch (u32 *expired_timers)
 
static int quic_connect_stream (session_t *quic_session, session_endpoint_cfg_t *sep)
 
static int quic_connect_connection (session_endpoint_cfg_t *sep)
 
static int quic_connect (transport_endpoint_cfg_t *tep)
 
static u32 quic_start_listen (u32 quic_listen_session_index, transport_endpoint_t *tep)
 
static u32 quic_stop_listen (u32 lctx_index)
 
static transport_connection_tquic_connection_get (u32 ctx_index, u32 thread_index)
 
static transport_connection_tquic_listener_get (u32 listener_index)
 
static u8format_quic_ctx (u8 *s, va_list *args)
 
static u8format_quic_connection (u8 *s, va_list *args)
 
static u8format_quic_half_open (u8 *s, va_list *args)
 
static u8format_quic_listener (u8 *s, va_list *args)
 
static void quic_build_sockaddr (struct sockaddr *sa, socklen_t *salen, ip46_address_t *addr, u16 port, u8 is_ip4)
 
static void quic_on_quic_session_connected (quic_ctx_t *ctx)
 
static void quic_update_conn_ctx (quicly_conn_t *conn, quicly_context_t *quicly_context)
 
static void quic_receive_connection (void *arg)
 
static void quic_transfer_connection (u32 ctx_index, u32 dest_thread)
 
static int quic_udp_session_connected_callback (u32 quic_app_index, u32 ctx_index, session_t *udp_session, session_error_t err)
 
static void quic_udp_session_disconnect_callback (session_t *s)
 
static void quic_udp_session_cleanup_callback (session_t *udp_session, session_cleanup_ntf_t ntf)
 
static void quic_udp_session_reset_callback (session_t *s)
 
static void quic_udp_session_migrate_callback (session_t *s, session_handle_t new_sh)
 
int quic_udp_session_accepted_callback (session_t *udp_session)
 
static int quic_add_segment_callback (u32 client_index, u64 seg_handle)
 
static int quic_del_segment_callback (u32 client_index, u64 seg_handle)
 
static int quic_custom_app_rx_callback (transport_connection_t *tc)
 
static int quic_custom_tx_callback (void *s, transport_send_params_t *sp)
 
static int quic_find_packet_ctx (quic_rx_packet_ctx_t *pctx, u32 caller_thread_index)
 
static void quic_accept_connection (quic_rx_packet_ctx_t *pctx)
 
static int quic_process_one_rx_packet (u64 udp_session_handle, svm_fifo_t *f, u32 fifo_offset, quic_rx_packet_ctx_t *pctx)
 
static int quic_udp_session_rx_callback (session_t *udp_session)
 
static void quic_common_get_transport_endpoint (quic_ctx_t *ctx, transport_endpoint_t *tep, u8 is_lcl)
 
static void quic_get_transport_listener_endpoint (u32 listener_index, transport_endpoint_t *tep, u8 is_lcl)
 
static void quic_get_transport_endpoint (u32 ctx_index, u32 thread_index, transport_endpoint_t *tep, u8 is_lcl)
 
static void quic_register_cipher_suite (crypto_engine_type_t type, ptls_cipher_suite_t **ciphers)
 
static void quic_update_fifo_size ()
 
static clib_error_tquic_init (vlib_main_t *vm)
 
static clib_error_tquic_plugin_crypto_command_fn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static clib_error_tquic_plugin_set_fifo_size_command_fn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static u64 quic_get_counter_value (u32 event_code)
 
static void quic_show_aggregated_stats (vlib_main_t *vm)
 
static u8quic_format_quicly_conn_id (u8 *s, va_list *args)
 
static u8quic_format_quicly_stream_id (u8 *s, va_list *args)
 
static u8quic_format_listener_ctx (u8 *s, va_list *args)
 
static u8quic_format_connection_ctx (u8 *s, va_list *args)
 
static u8quic_format_stream_ctx (u8 *s, va_list *args)
 
static clib_error_tquic_show_connections_command_fn (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
 VLIB_PLUGIN_REGISTER ()
 
static clib_error_tquic_config_fn (vlib_main_t *vm, unformat_input_t *input)
 
static uword quic_node_fn (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
 

Variables

quicly_crypto_engine_t quic_crypto_engine
 
static char * quic_error_strings []
 
quic_main_t quic_main
 
static quicly_stream_open_t on_stream_open = { quic_on_stream_open }
 
static quicly_closed_by_remote_t on_closed_by_remote
 
static quicly_now_t quicly_vpp_now_cb = { quic_get_time }
 
static const quicly_stream_callbacks_t quic_stream_callbacks
 
static session_cb_vft_t quic_app_cb_vft
 
static const transport_proto_vft_t quic_proto
 
u64 quic_fifosize = 0
 
static vlib_cli_command_t quic_plugin_crypto_command
 (constructor) VLIB_CLI_COMMAND (quic_plugin_crypto_command) More...
 
static vlib_cli_command_t quic_plugin_set_fifo_size_command
 (constructor) VLIB_CLI_COMMAND (quic_plugin_set_fifo_size_command) More...
 
static vlib_cli_command_t quic_show_ctx_command
 (constructor) VLIB_CLI_COMMAND (quic_show_ctx_command) More...
 
static vlib_cli_command_t quic_list_crypto_context_command
 (constructor) VLIB_CLI_COMMAND (quic_list_crypto_context_command) More...
 
static vlib_cli_command_t quic_set_max_packets_per_key
 (constructor) VLIB_CLI_COMMAND (quic_set_max_packets_per_key) More...
 
static vlib_cli_command_t quic_set_cc
 (constructor) VLIB_CLI_COMMAND (quic_set_cc) More...
 
vlib_node_registration_t quic_input_node
 (constructor) VLIB_REGISTER_NODE (quic_input_node) More...
 

Macro Definition Documentation

◆ DEFAULT_MAX_PACKETS_PER_KEY

#define DEFAULT_MAX_PACKETS_PER_KEY   16777216

Definition at line 44 of file quic.c.

◆ quic_error

#define quic_error (   n,
 
)    s,

Function Documentation

◆ format_quic_connection()

static u8* format_quic_connection ( u8 s,
va_list *  args 
)
static

Definition at line 1579 of file quic.c.

+ Here is the call graph for this function:

◆ format_quic_ctx()

static u8* format_quic_ctx ( u8 s,
va_list *  args 
)
static

Definition at line 1547 of file quic.c.

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

◆ format_quic_half_open()

static u8* format_quic_half_open ( u8 s,
va_list *  args 
)
static

Definition at line 1590 of file quic.c.

+ Here is the call graph for this function:

◆ format_quic_listener()

static u8* format_quic_listener ( u8 s,
va_list *  args 
)
static

Definition at line 1602 of file quic.c.

+ Here is the call graph for this function:

◆ get_stream_session_and_ctx_from_stream()

static session_t* get_stream_session_and_ctx_from_stream ( quicly_stream_t *  stream,
quic_ctx_t **  ctx 
)
inlinestatic

Definition at line 460 of file quic.c.

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

◆ quic_accept_connection()

static void quic_accept_connection ( quic_rx_packet_ctx_t pctx)
static

Definition at line 2066 of file quic.c.

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

◆ quic_ack_rx_data()

static void quic_ack_rx_data ( session_t stream_session)
static

Definition at line 532 of file quic.c.

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

◆ quic_acquire_crypto_context()

static int quic_acquire_crypto_context ( quic_ctx_t ctx)
static

Definition at line 332 of file quic.c.

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

◆ quic_add_segment_callback()

static int quic_add_segment_callback ( u32  client_index,
u64  seg_handle 
)
static

Definition at line 1939 of file quic.c.

◆ quic_app_cert_key_pair_delete_callback()

static int quic_app_cert_key_pair_delete_callback ( app_cert_key_pair_t ckpair)
static

Definition at line 95 of file quic.c.

+ Here is the call graph for this function:

◆ quic_build_sockaddr()

static void quic_build_sockaddr ( struct sockaddr *  sa,
socklen_t *  salen,
ip46_address_t *  addr,
u16  port,
u8  is_ip4 
)
inlinestatic

Definition at line 1615 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_check_quic_session_connected()

static void quic_check_quic_session_connected ( quic_ctx_t ctx)
static

Definition at line 1685 of file quic.c.

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

◆ quic_common_get_transport_endpoint()

static void quic_common_get_transport_endpoint ( quic_ctx_t ctx,
transport_endpoint_t tep,
u8  is_lcl 
)
inlinestatic

Definition at line 2382 of file quic.c.

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

◆ quic_config_fn()

static clib_error_t* quic_config_fn ( vlib_main_t vm,
unformat_input_t input 
)
static

Definition at line 2948 of file quic.c.

+ Here is the call graph for this function:

◆ quic_connect()

static int quic_connect ( transport_endpoint_cfg_t tep)
static

Definition at line 1366 of file quic.c.

+ Here is the call graph for this function:

◆ quic_connect_connection()

static int quic_connect_connection ( session_endpoint_cfg_t sep)
static

Definition at line 1306 of file quic.c.

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

◆ quic_connect_stream()

static int quic_connect_stream ( session_t quic_session,
session_endpoint_cfg_t sep 
)
static

Definition at line 1195 of file quic.c.

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

◆ quic_connection_closed()

static void quic_connection_closed ( quic_ctx_t ctx)
static

Called when quicly return an error This function interacts tightly with quic_proto_on_close.

Definition at line 613 of file quic.c.

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

◆ quic_connection_delete()

static void quic_connection_delete ( quic_ctx_t ctx)
static

Definition at line 570 of file quic.c.

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

◆ quic_connection_get()

static transport_connection_t* quic_connection_get ( u32  ctx_index,
u32  thread_index 
)
static

Definition at line 1530 of file quic.c.

+ Here is the call graph for this function:

◆ quic_crypto_context_alloc()

static crypto_context_t* quic_crypto_context_alloc ( u8  thread_index)
static

Definition at line 120 of file quic.c.

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

◆ quic_crypto_context_free_if_needed()

static void quic_crypto_context_free_if_needed ( crypto_context_t crctx,
u8  thread_index 
)
static

Definition at line 81 of file quic.c.

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

◆ quic_crypto_context_get()

static crypto_context_t* quic_crypto_context_get ( u32  cr_index,
u32  thread_index 
)
static

Definition at line 135 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_crypto_context_make_key_from_crctx()

static void quic_crypto_context_make_key_from_crctx ( clib_bihash_kv_24_8_t kv,
crypto_context_t crctx 
)
inlinestatic

Definition at line 70 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_crypto_context_make_key_from_ctx()

static void quic_crypto_context_make_key_from_ctx ( clib_bihash_kv_24_8_t kv,
quic_ctx_t ctx 
)
inlinestatic

Definition at line 60 of file quic.c.

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

◆ quic_ctx_alloc()

static u32 quic_ctx_alloc ( u32  thread_index)
static

Definition at line 386 of file quic.c.

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

◆ quic_ctx_free()

static void quic_ctx_free ( quic_ctx_t ctx)
static

Definition at line 402 of file quic.c.

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

◆ quic_ctx_get()

static quic_ctx_t* quic_ctx_get ( u32  ctx_index,
u32  thread_index 
)
static

Definition at line 413 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_ctx_get_if_valid()

static quic_ctx_t* quic_ctx_get_if_valid ( u32  ctx_index,
u32  thread_index 
)
static

Definition at line 419 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_ctx_is_conn()

static int quic_ctx_is_conn ( quic_ctx_t ctx)
inlinestatic

Definition at line 454 of file quic.c.

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

◆ quic_ctx_is_listener()

static int quic_ctx_is_listener ( quic_ctx_t ctx)
inlinestatic

Definition at line 448 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_ctx_is_stream()

static int quic_ctx_is_stream ( quic_ctx_t ctx)
inlinestatic

Definition at line 442 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_custom_app_rx_callback()

static int quic_custom_app_rx_callback ( transport_connection_t tc)
static

Definition at line 1953 of file quic.c.

+ Here is the call graph for this function:

◆ quic_custom_tx_callback()

static int quic_custom_tx_callback ( void *  s,
transport_send_params_t sp 
)
static

Definition at line 1969 of file quic.c.

+ Here is the call graph for this function:

◆ quic_del_segment_callback()

static int quic_del_segment_callback ( u32  client_index,
u64  seg_handle 
)
static

Definition at line 1946 of file quic.c.

◆ quic_disconnect_transport()

static void quic_disconnect_transport ( quic_ctx_t ctx)
static

Definition at line 556 of file quic.c.

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

◆ quic_expired_timers_dispatch()

static void quic_expired_timers_dispatch ( u32 expired_timers)
static

Definition at line 1183 of file quic.c.

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

◆ quic_fifo_egress_emit()

void quic_fifo_egress_emit ( quicly_stream_t *  stream,
size_t  off,
void *  dst,
size_t *  len,
int *  wrote_all 
)

Definition at line 930 of file quic.c.

+ Here is the call graph for this function:

◆ quic_fifo_egress_shift()

void quic_fifo_egress_shift ( quicly_stream_t *  stream,
size_t  delta 
)

Definition at line 907 of file quic.c.

+ Here is the call graph for this function:

◆ quic_find_packet_ctx()

static int quic_find_packet_ctx ( quic_rx_packet_ctx_t pctx,
u32  caller_thread_index 
)
inlinestatic

Definition at line 2021 of file quic.c.

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

◆ quic_format_connection_ctx()

static u8* quic_format_connection_ctx ( u8 s,
va_list *  args 
)
static

Definition at line 2778 of file quic.c.

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

◆ quic_format_listener_ctx()

static u8* quic_format_listener_ctx ( u8 s,
va_list *  args 
)
static

Definition at line 2770 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_format_quicly_conn_id()

static u8* quic_format_quicly_conn_id ( u8 s,
va_list *  args 
)
static

Definition at line 2752 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_format_quicly_stream_id()

static u8* quic_format_quicly_stream_id ( u8 s,
va_list *  args 
)
static

Definition at line 2760 of file quic.c.

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

◆ quic_format_stream_ctx()

static u8* quic_format_stream_ctx ( u8 s,
va_list *  args 
)
static

Definition at line 2826 of file quic.c.

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

◆ quic_get_conn_ctx()

quic_ctx_t* quic_get_conn_ctx ( quicly_conn_t *  conn)

Definition at line 427 of file quic.c.

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

◆ quic_get_counter_value()

static u64 quic_get_counter_value ( u32  event_code)
inlinestatic

Definition at line 2651 of file quic.c.

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

◆ quic_get_quicly_ctx_from_ctx()

static quicly_context_t* quic_get_quicly_ctx_from_ctx ( quic_ctx_t ctx)
static

Definition at line 488 of file quic.c.

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

◆ quic_get_quicly_ctx_from_udp()

static quicly_context_t* quic_get_quicly_ctx_from_udp ( u64  udp_session_handle)
static

Definition at line 498 of file quic.c.

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

◆ quic_get_thread_time()

static int64_t quic_get_thread_time ( u8  thread_index)
static

Definition at line 1076 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_get_time()

static int64_t quic_get_time ( quicly_now_t *  self)
static

Definition at line 1082 of file quic.c.

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

◆ quic_get_transport_endpoint()

static void quic_get_transport_endpoint ( u32  ctx_index,
u32  thread_index,
transport_endpoint_t tep,
u8  is_lcl 
)
static

Definition at line 2411 of file quic.c.

+ Here is the call graph for this function:

◆ quic_get_transport_listener_endpoint()

static void quic_get_transport_listener_endpoint ( u32  listener_index,
transport_endpoint_t tep,
u8  is_lcl 
)
static

Definition at line 2394 of file quic.c.

+ Here is the call graph for this function:

◆ quic_increment_counter()

void quic_increment_counter ( u8  evt,
u8  val 
)

Definition at line 602 of file quic.c.

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

◆ quic_init()

static clib_error_t* quic_init ( vlib_main_t vm)
static

Definition at line 2492 of file quic.c.

+ Here is the call graph for this function:

◆ quic_init_crypto_context()

static int quic_init_crypto_context ( crypto_context_t crctx,
quic_ctx_t ctx 
)
static

Definition at line 228 of file quic.c.

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

◆ quic_list_crypto_context_command_fn()

static clib_error_t* quic_list_crypto_context_command_fn ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 144 of file quic.c.

+ Here is the call graph for this function:

◆ quic_listener_get()

static transport_connection_t* quic_listener_get ( u32  listener_index)
static

Definition at line 1538 of file quic.c.

+ Here is the call graph for this function:

◆ quic_make_connection_key()

static void quic_make_connection_key ( clib_bihash_kv_16_8_t kv,
const quicly_cid_plaintext_t *  id 
)
inlinestatic

Definition at line 471 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_node_fn()

static uword quic_node_fn ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t frame 
)
static

Definition at line 2995 of file quic.c.

◆ quic_on_closed_by_remote()

static void quic_on_closed_by_remote ( quicly_closed_by_remote_t *  self,
quicly_conn_t *  conn,
int  code,
uint64_t  frame_type,
const char *  reason,
size_t  reason_len 
)
static

Definition at line 1058 of file quic.c.

+ Here is the call graph for this function:

◆ quic_on_quic_session_connected()

static void quic_on_quic_session_connected ( quic_ctx_t ctx)
static

Definition at line 1637 of file quic.c.

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

◆ quic_on_receive()

static void quic_on_receive ( quicly_stream_t *  stream,
size_t  off,
const void *  src,
size_t  len 
)
static

Definition at line 829 of file quic.c.

+ Here is the call graph for this function:

◆ quic_on_receive_reset()

static void quic_on_receive_reset ( quicly_stream_t *  stream,
int  err 
)
static

Definition at line 814 of file quic.c.

+ Here is the call graph for this function:

◆ quic_on_stop_sending()

static void quic_on_stop_sending ( quicly_stream_t *  stream,
int  err 
)
static

Definition at line 799 of file quic.c.

+ Here is the call graph for this function:

◆ quic_on_stream_destroy()

static void quic_on_stream_destroy ( quicly_stream_t *  stream,
int  err 
)
static

Definition at line 780 of file quic.c.

+ Here is the call graph for this function:

◆ quic_on_stream_open()

static int quic_on_stream_open ( quicly_stream_open_t *  self,
quicly_stream_t *  stream 
)
static

Definition at line 974 of file quic.c.

+ Here is the call graph for this function:

◆ quic_plugin_crypto_command_fn()

static clib_error_t* quic_plugin_crypto_command_fn ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 2588 of file quic.c.

+ Here is the call graph for this function:

◆ quic_plugin_set_fifo_size_command_fn()

static clib_error_t* quic_plugin_set_fifo_size_command_fn ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 2619 of file quic.c.

+ Here is the call graph for this function:

◆ quic_process_one_rx_packet()

static int quic_process_one_rx_packet ( u64  udp_session_handle,
svm_fifo_t f,
u32  fifo_offset,
quic_rx_packet_ctx_t pctx 
)
static

Definition at line 2184 of file quic.c.

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

◆ quic_proto_on_close()

static void quic_proto_on_close ( u32  ctx_index,
u32  thread_index 
)
static

Definition at line 1381 of file quic.c.

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

◆ quic_receive_connection()

static void quic_receive_connection ( void *  arg)
static

Definition at line 1716 of file quic.c.

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

◆ quic_register_cipher_suite()

static void quic_register_cipher_suite ( crypto_engine_type_t  type,
ptls_cipher_suite_t **  ciphers 
)
static

Definition at line 2464 of file quic.c.

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

◆ quic_release_crypto_context()

static void quic_release_crypto_context ( u32  crypto_context_index,
u8  thread_index 
)
static

Definition at line 219 of file quic.c.

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

◆ quic_reset_connection()

static int quic_reset_connection ( u64  udp_session_handle,
quic_rx_packet_ctx_t pctx 
)
static

Definition at line 2145 of file quic.c.

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

◆ quic_send_datagram()

static int quic_send_datagram ( session_t udp_session,
struct iovec *  packet,
quicly_address_t *  dest,
quicly_address_t *  src 
)
static

Definition at line 652 of file quic.c.

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

◆ quic_send_packets()

static int quic_send_packets ( quic_ctx_t ctx)
static

Definition at line 711 of file quic.c.

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

◆ quic_sendable_packet_count()

static int quic_sendable_packet_count ( session_t udp_session)
static

Definition at line 479 of file quic.c.

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

◆ quic_set_cc_fn()

static clib_error_t* quic_set_cc_fn ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 190 of file quic.c.

+ Here is the call graph for this function:

◆ quic_set_max_packets_per_key_fn()

static clib_error_t* quic_set_max_packets_per_key_fn ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 164 of file quic.c.

+ Here is the call graph for this function:

◆ quic_set_time_now()

static u32 quic_set_time_now ( u32  thread_index)
static

Definition at line 1089 of file quic.c.

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

◆ quic_set_udp_tx_evt()

static void quic_set_udp_tx_evt ( session_t udp_session)
inlinestatic

Definition at line 507 of file quic.c.

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

◆ quic_show_aggregated_stats()

static void quic_show_aggregated_stats ( vlib_main_t vm)
static

Definition at line 2680 of file quic.c.

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

◆ quic_show_connections_command_fn()

static clib_error_t* quic_show_connections_command_fn ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 2849 of file quic.c.

+ Here is the call graph for this function:

◆ quic_start_listen()

static u32 quic_start_listen ( u32  quic_listen_session_index,
transport_endpoint_t tep 
)
static

Definition at line 1444 of file quic.c.

+ Here is the call graph for this function:

◆ quic_stop_ctx_timer()

static void quic_stop_ctx_timer ( quic_ctx_t ctx)
inlinestatic

Definition at line 518 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_stop_listen()

static u32 quic_stop_listen ( u32  lctx_index)
static

Definition at line 1509 of file quic.c.

+ Here is the call graph for this function:

◆ quic_store_conn_ctx()

static void quic_store_conn_ctx ( quicly_conn_t *  conn,
quic_ctx_t ctx 
)
static

Definition at line 435 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_timer_expired()

static void quic_timer_expired ( u32  conn_index)
static

Definition at line 1109 of file quic.c.

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

◆ quic_transfer_connection()

static void quic_transfer_connection ( u32  ctx_index,
u32  dest_thread 
)
static

Definition at line 1760 of file quic.c.

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

◆ quic_udp_session_accepted_callback()

int quic_udp_session_accepted_callback ( session_t udp_session)

Definition at line 1900 of file quic.c.

+ Here is the call graph for this function:

◆ quic_udp_session_cleanup_callback()

static void quic_udp_session_cleanup_callback ( session_t udp_session,
session_cleanup_ntf_t  ntf 
)
static

Definition at line 1860 of file quic.c.

+ Here is the call graph for this function:

◆ quic_udp_session_connected_callback()

static int quic_udp_session_connected_callback ( u32  quic_app_index,
u32  ctx_index,
session_t udp_session,
session_error_t  err 
)
static

Definition at line 1783 of file quic.c.

+ Here is the call graph for this function:

◆ quic_udp_session_disconnect_callback()

static void quic_udp_session_disconnect_callback ( session_t s)
static

Definition at line 1854 of file quic.c.

◆ quic_udp_session_migrate_callback()

static void quic_udp_session_migrate_callback ( session_t s,
session_handle_t  new_sh 
)
static

Definition at line 1882 of file quic.c.

+ Here is the call graph for this function:

◆ quic_udp_session_reset_callback()

static void quic_udp_session_reset_callback ( session_t s)
static

Definition at line 1876 of file quic.c.

◆ quic_udp_session_rx_callback()

static int quic_udp_session_rx_callback ( session_t udp_session)
static

Definition at line 2263 of file quic.c.

+ Here is the call graph for this function:

◆ quic_update_conn_ctx()

static void quic_update_conn_ctx ( quicly_conn_t *  conn,
quicly_context_t *  quicly_context 
)
inlinestatic

Definition at line 1703 of file quic.c.

+ Here is the caller graph for this function:

◆ quic_update_fifo_size()

static void quic_update_fifo_size ( )
static

Definition at line 2474 of file quic.c.

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

◆ quic_update_time()

static void quic_update_time ( f64  now,
u8  thread_index 
)
static

Definition at line 1099 of file quic.c.

+ Here is the call graph for this function:

◆ quic_update_timer()

static void quic_update_timer ( quic_ctx_t ctx)
static

Definition at line 1120 of file quic.c.

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

◆ VLIB_PLUGIN_REGISTER()

VLIB_PLUGIN_REGISTER ( )

Variable Documentation

◆ on_closed_by_remote

static quicly_closed_by_remote_t on_closed_by_remote
static
Initial value:

Definition at line 54 of file quic.c.

◆ on_stream_open

static quicly_stream_open_t on_stream_open = { quic_on_stream_open }
static

Definition at line 53 of file quic.c.

◆ quic_app_cb_vft

session_cb_vft_t quic_app_cb_vft
static
Initial value:
= {
.session_accept_callback = quic_udp_session_accepted_callback,
.session_disconnect_callback = quic_udp_session_disconnect_callback,
.session_connected_callback = quic_udp_session_connected_callback,
.session_reset_callback = quic_udp_session_reset_callback,
.session_migrate_callback = quic_udp_session_migrate_callback,
.add_segment_callback = quic_add_segment_callback,
.del_segment_callback = quic_del_segment_callback,
.builtin_app_rx_callback = quic_udp_session_rx_callback,
.session_cleanup_callback = quic_udp_session_cleanup_callback,
.app_cert_key_pair_delete_callback = quic_app_cert_key_pair_delete_callback,
}

Definition at line 2420 of file quic.c.

◆ quic_crypto_engine

quicly_crypto_engine_t quic_crypto_engine

Definition at line 547 of file quic_crypto.c.

◆ quic_error_strings

char* quic_error_strings[]
static
Initial value:
= {
#define quic_error(n,s)
}

Definition at line 38 of file quic.c.

◆ quic_fifosize

u64 quic_fifosize = 0

Definition at line 2617 of file quic.c.

◆ quic_input_node

vlib_node_registration_t quic_input_node
Initial value:
=
{
.function = quic_node_fn,
.name = "quic-input",
.vector_size = sizeof (u32),
.error_strings = quic_error_strings,
}

(constructor) VLIB_REGISTER_NODE (quic_input_node)

Definition at line 3002 of file quic.c.

◆ quic_list_crypto_context_command

vlib_cli_command_t quic_list_crypto_context_command
static
Initial value:
=
{
.path = "show quic crypto context",
.short_help = "list quic crypto contextes",
}

(constructor) VLIB_CLI_COMMAND (quic_list_crypto_context_command)

Definition at line 2922 of file quic.c.

◆ quic_main

quic_main_t quic_main

Definition at line 46 of file quic.c.

◆ quic_plugin_crypto_command

vlib_cli_command_t quic_plugin_crypto_command
static
Initial value:
= {
.path = "quic set crypto api",
.short_help = "quic set crypto api [picotls|vpp]",
}

(constructor) VLIB_CLI_COMMAND (quic_plugin_crypto_command)

Definition at line 2905 of file quic.c.

◆ quic_plugin_set_fifo_size_command

vlib_cli_command_t quic_plugin_set_fifo_size_command
static
Initial value:
=
{
.path = "quic set fifo-size",
.short_help = "quic set fifo-size N[K|M|G] (default 64K)",
}

(constructor) VLIB_CLI_COMMAND (quic_plugin_set_fifo_size_command)

Definition at line 2910 of file quic.c.

◆ quic_proto

const transport_proto_vft_t quic_proto
static
Initial value:
= {
.connect = quic_connect,
.start_listen = quic_start_listen,
.stop_listen = quic_stop_listen,
.get_connection = quic_connection_get,
.get_listener = quic_listener_get,
.update_time = quic_update_time,
.format_connection = format_quic_connection,
.format_half_open = format_quic_half_open,
.format_listener = format_quic_listener,
.get_transport_endpoint = quic_get_transport_endpoint,
.get_transport_listener_endpoint = quic_get_transport_listener_endpoint,
.transport_options = {
.name = "quic",
.short_name = "Q",
.service_type = TRANSPORT_SERVICE_APP,
},
}

Definition at line 2433 of file quic.c.

◆ quic_set_cc

vlib_cli_command_t quic_set_cc
static
Initial value:
= {
.path = "set quic cc",
.short_help = "set quic cc [reno|cubic]",
.function = quic_set_cc_fn,
}

(constructor) VLIB_CLI_COMMAND (quic_set_cc)

Definition at line 2934 of file quic.c.

◆ quic_set_max_packets_per_key

vlib_cli_command_t quic_set_max_packets_per_key
static
Initial value:
=
{
.path = "set quic max_packets_per_key",
.short_help = "set quic max_packets_per_key 16777216",
}

(constructor) VLIB_CLI_COMMAND (quic_set_max_packets_per_key)

Definition at line 2928 of file quic.c.

◆ quic_show_ctx_command

vlib_cli_command_t quic_show_ctx_command
static
Initial value:
=
{
.path = "show quic",
.short_help = "show quic",
}

(constructor) VLIB_CLI_COMMAND (quic_show_ctx_command)

Definition at line 2916 of file quic.c.

◆ quic_stream_callbacks

const quicly_stream_callbacks_t quic_stream_callbacks
static
Initial value:
= {
.on_destroy = quic_on_stream_destroy,
.on_send_shift = quic_fifo_egress_shift,
.on_send_emit = quic_fifo_egress_emit,
.on_send_stop = quic_on_stop_sending,
.on_receive = quic_on_receive,
.on_receive_reset = quic_on_receive_reset
}

Definition at line 964 of file quic.c.

◆ quicly_vpp_now_cb

static quicly_now_t quicly_vpp_now_cb = { quic_get_time }
static

Definition at line 55 of file quic.c.

format_quic_listener
static u8 * format_quic_listener(u8 *s, va_list *args)
Definition: quic.c:1602
quic_node_fn
static uword quic_node_fn(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
Definition: quic.c:2995
quic_udp_session_cleanup_callback
static void quic_udp_session_cleanup_callback(session_t *udp_session, session_cleanup_ntf_t ntf)
Definition: quic.c:1860
quic_plugin_crypto_command_fn
static clib_error_t * quic_plugin_crypto_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
Definition: quic.c:2588
quic_get_transport_endpoint
static void quic_get_transport_endpoint(u32 ctx_index, u32 thread_index, transport_endpoint_t *tep, u8 is_lcl)
Definition: quic.c:2411
format_quic_connection
static u8 * format_quic_connection(u8 *s, va_list *args)
Definition: quic.c:1579
quic_set_cc_fn
static clib_error_t * quic_set_cc_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
Definition: quic.c:190
quic_fifo_egress_emit
void quic_fifo_egress_emit(quicly_stream_t *stream, size_t off, void *dst, size_t *len, int *wrote_all)
Definition: quic.c:930
quic_udp_session_connected_callback
static int quic_udp_session_connected_callback(u32 quic_app_index, u32 ctx_index, session_t *udp_session, session_error_t err)
Definition: quic.c:1783
VLIB_NODE_TYPE_INTERNAL
@ VLIB_NODE_TYPE_INTERNAL
Definition: node.h:72
quic_set_max_packets_per_key_fn
static clib_error_t * quic_set_max_packets_per_key_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
Definition: quic.c:164
quic_stop_listen
static u32 quic_stop_listen(u32 lctx_index)
Definition: quic.c:1509
format_quic_half_open
static u8 * format_quic_half_open(u8 *s, va_list *args)
Definition: quic.c:1590
quic_udp_session_disconnect_callback
static void quic_udp_session_disconnect_callback(session_t *s)
Definition: quic.c:1854
quic_udp_session_accepted_callback
int quic_udp_session_accepted_callback(session_t *udp_session)
Definition: quic.c:1900
quic_custom_app_rx_callback
static int quic_custom_app_rx_callback(transport_connection_t *tc)
Definition: quic.c:1953
quic_plugin_set_fifo_size_command_fn
static clib_error_t * quic_plugin_set_fifo_size_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
Definition: quic.c:2619
quic_on_receive
static void quic_on_receive(quicly_stream_t *stream, size_t off, const void *src, size_t len)
Definition: quic.c:829
quic_udp_session_migrate_callback
static void quic_udp_session_migrate_callback(session_t *s, session_handle_t new_sh)
Definition: quic.c:1882
quic_listener_get
static transport_connection_t * quic_listener_get(u32 listener_index)
Definition: quic.c:1538
quic_custom_tx_callback
static int quic_custom_tx_callback(void *s, transport_send_params_t *sp)
Definition: quic.c:1969
ARRAY_LEN
#define ARRAY_LEN(x)
Definition: clib.h:70
TRANSPORT_SERVICE_APP
@ TRANSPORT_SERVICE_APP
app transport service
Definition: transport_types.h:41
quic_udp_session_reset_callback
static void quic_udp_session_reset_callback(session_t *s)
Definition: quic.c:1876
quic_on_stop_sending
static void quic_on_stop_sending(quicly_stream_t *stream, int err)
Definition: quic.c:799
quic_on_closed_by_remote
static void quic_on_closed_by_remote(quicly_closed_by_remote_t *self, quicly_conn_t *conn, int code, uint64_t frame_type, const char *reason, size_t reason_len)
Definition: quic.c:1058
quic_show_connections_command_fn
static clib_error_t * quic_show_connections_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
Definition: quic.c:2849
TRANSPORT_TX_INTERNAL
@ TRANSPORT_TX_INTERNAL
apps acting as transports
Definition: transport_types.h:32
quic_on_stream_destroy
static void quic_on_stream_destroy(quicly_stream_t *stream, int err)
Definition: quic.c:780
quic_start_listen
static u32 quic_start_listen(u32 quic_listen_session_index, transport_endpoint_t *tep)
Definition: quic.c:1444
quic_error_strings
static char * quic_error_strings[]
Definition: quic.c:38
u32
unsigned int u32
Definition: types.h:88
quic_app_cert_key_pair_delete_callback
static int quic_app_cert_key_pair_delete_callback(app_cert_key_pair_t *ckpair)
Definition: quic.c:95
quic_on_receive_reset
static void quic_on_receive_reset(quicly_stream_t *stream, int err)
Definition: quic.c:814
quic_connect
static int quic_connect(transport_endpoint_cfg_t *tep)
Definition: quic.c:1366
quic_get_transport_listener_endpoint
static void quic_get_transport_listener_endpoint(u32 listener_index, transport_endpoint_t *tep, u8 is_lcl)
Definition: quic.c:2394
quic_list_crypto_context_command_fn
static clib_error_t * quic_list_crypto_context_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
Definition: quic.c:144
quic_udp_session_rx_callback
static int quic_udp_session_rx_callback(session_t *udp_session)
Definition: quic.c:2263
quic_add_segment_callback
static int quic_add_segment_callback(u32 client_index, u64 seg_handle)
Definition: quic.c:1939
quic_fifo_egress_shift
void quic_fifo_egress_shift(quicly_stream_t *stream, size_t delta)
Definition: quic.c:907
quic_update_time
static void quic_update_time(f64 now, u8 thread_index)
Definition: quic.c:1099
quic_proto_on_close
static void quic_proto_on_close(u32 ctx_index, u32 thread_index)
Definition: quic.c:1381
quic_connection_get
static transport_connection_t * quic_connection_get(u32 ctx_index, u32 thread_index)
Definition: quic.c:1530
type
vl_api_fib_path_type_t type
Definition: fib_types.api:123
quic_del_segment_callback
static int quic_del_segment_callback(u32 client_index, u64 seg_handle)
Definition: quic.c:1946