FD.io VPP  v21.01.1
Vector Packet Processing
ipsec_api.c File Reference
+ Include dependency graph for ipsec_api.c:

Go to the source code of this file.

Data Structures

struct  ipsec_dump_walk_ctx_t_
 
struct  ipsec_sa_dump_match_ctx_t_
 

Macros

#define vl_typedefs   /* define message structures */
 
#define vl_endianfun   /* define message structures */
 
#define vl_print(handle, ...)   vlib_cli_output (handle, __VA_ARGS__)
 
#define vl_printfun
 
#define foreach_vpe_api_msg
 
#define vl_msg_name_crc_list
 

Typedefs

typedef struct ipsec_dump_walk_ctx_t_ ipsec_dump_walk_ctx_t
 
typedef struct ipsec_sa_dump_match_ctx_t_ ipsec_sa_dump_match_ctx_t
 

Functions

static void vl_api_ipsec_spd_add_del_t_handler (vl_api_ipsec_spd_add_del_t *mp)
 
static void vl_api_ipsec_interface_add_del_spd_t_handler (vl_api_ipsec_interface_add_del_spd_t *mp)
 
static void vl_api_ipsec_tunnel_protect_update_t_handler (vl_api_ipsec_tunnel_protect_update_t *mp)
 
static void vl_api_ipsec_tunnel_protect_del_t_handler (vl_api_ipsec_tunnel_protect_del_t *mp)
 
static walk_rc_t send_ipsec_tunnel_protect_details (index_t itpi, void *arg)
 
static void vl_api_ipsec_tunnel_protect_dump_t_handler (vl_api_ipsec_tunnel_protect_dump_t *mp)
 
static int ipsec_spd_action_decode (vl_api_ipsec_spd_action_t in, ipsec_policy_action_t *out)
 
static void vl_api_ipsec_spd_entry_add_del_t_handler (vl_api_ipsec_spd_entry_add_del_t *mp)
 
static void vl_api_ipsec_sad_entry_add_del_t_handler (vl_api_ipsec_sad_entry_add_del_t *mp)
 
static void vl_api_ipsec_sad_entry_add_del_v2_t_handler (vl_api_ipsec_sad_entry_add_del_v2_t *mp)
 
static void send_ipsec_spds_details (ipsec_spd_t *spd, vl_api_registration_t *reg, u32 context)
 
static void vl_api_ipsec_spds_dump_t_handler (vl_api_ipsec_spds_dump_t *mp)
 
vl_api_ipsec_spd_action_t ipsec_spd_action_encode (ipsec_policy_action_t in)
 
static void send_ipsec_spd_details (ipsec_policy_t *p, vl_api_registration_t *reg, u32 context)
 
static void vl_api_ipsec_spd_dump_t_handler (vl_api_ipsec_spd_dump_t *mp)
 
static void send_ipsec_spd_interface_details (vl_api_registration_t *reg, u32 spd_index, u32 sw_if_index, u32 context)
 
static void vl_api_ipsec_spd_interface_dump_t_handler (vl_api_ipsec_spd_interface_dump_t *mp)
 
static u32 ipsec_tun_mk_input_sa_id (u32 ti)
 
static u32 ipsec_tun_mk_output_sa_id (u32 ti)
 
static void vl_api_ipsec_tunnel_if_add_del_t_handler (vl_api_ipsec_tunnel_if_add_del_t *mp)
 
static void vl_api_ipsec_itf_create_t_handler (vl_api_ipsec_itf_create_t *mp)
 
static void vl_api_ipsec_itf_delete_t_handler (vl_api_ipsec_itf_delete_t *mp)
 
static void vl_api_ipsec_itf_dump_t_handler (vl_api_ipsec_itf_dump_t *mp)
 
static walk_rc_t ipsec_sa_dump_match_sa (index_t itpi, void *arg)
 
static walk_rc_t send_ipsec_sa_details (ipsec_sa_t *sa, void *arg)
 
static void vl_api_ipsec_sa_dump_t_handler (vl_api_ipsec_sa_dump_t *mp)
 
static walk_rc_t send_ipsec_sa_v2_details (ipsec_sa_t *sa, void *arg)
 
static void vl_api_ipsec_sa_v2_dump_t_handler (vl_api_ipsec_sa_dump_t *mp)
 
static void vl_api_ipsec_tunnel_if_set_sa_t_handler (vl_api_ipsec_tunnel_if_set_sa_t *mp)
 
static void vl_api_ipsec_backend_dump_t_handler (vl_api_ipsec_backend_dump_t *mp)
 
static void vl_api_ipsec_select_backend_t_handler (vl_api_ipsec_select_backend_t *mp)
 
static void vl_api_ipsec_set_async_mode_t_handler (vl_api_ipsec_set_async_mode_t *mp)
 
static void setup_message_id_table (api_main_t *am)
 
static clib_error_tipsec_api_hookup (vlib_main_t *vm)
 
 VLIB_API_INIT_FUNCTION (ipsec_api_hookup)
 

Macro Definition Documentation

◆ foreach_vpe_api_msg

#define foreach_vpe_api_msg
Value:
_(IPSEC_SPD_ADD_DEL, ipsec_spd_add_del) \
_(IPSEC_INTERFACE_ADD_DEL_SPD, ipsec_interface_add_del_spd) \
_(IPSEC_SPD_ENTRY_ADD_DEL, ipsec_spd_entry_add_del) \
_(IPSEC_SAD_ENTRY_ADD_DEL, ipsec_sad_entry_add_del) \
_(IPSEC_SAD_ENTRY_ADD_DEL_V2, ipsec_sad_entry_add_del_v2) \
_(IPSEC_SA_DUMP, ipsec_sa_dump) \
_(IPSEC_SA_V2_DUMP, ipsec_sa_v2_dump) \
_(IPSEC_SPDS_DUMP, ipsec_spds_dump) \
_(IPSEC_SPD_DUMP, ipsec_spd_dump) \
_(IPSEC_SPD_INTERFACE_DUMP, ipsec_spd_interface_dump) \
_(IPSEC_ITF_CREATE, ipsec_itf_create) \
_(IPSEC_ITF_DELETE, ipsec_itf_delete) \
_(IPSEC_ITF_DUMP, ipsec_itf_dump) \
_(IPSEC_TUNNEL_IF_ADD_DEL, ipsec_tunnel_if_add_del) \
_(IPSEC_TUNNEL_IF_SET_SA, ipsec_tunnel_if_set_sa) \
_(IPSEC_SELECT_BACKEND, ipsec_select_backend) \
_(IPSEC_BACKEND_DUMP, ipsec_backend_dump) \
_(IPSEC_TUNNEL_PROTECT_UPDATE, ipsec_tunnel_protect_update) \
_(IPSEC_TUNNEL_PROTECT_DEL, ipsec_tunnel_protect_del) \
_(IPSEC_TUNNEL_PROTECT_DUMP, ipsec_tunnel_protect_dump) \
_(IPSEC_SET_ASYNC_MODE, ipsec_set_async_mode)
void ipsec_set_async_mode(u32 is_enabled)
Definition: ipsec.c:339
int ipsec_itf_delete(u32 sw_if_index)
Definition: ipsec_itf.c:328
int ipsec_itf_create(u32 user_instance, tunnel_mode_t mode, u32 *sw_if_indexp)
Definition: ipsec_itf.c:281

Definition at line 57 of file ipsec_api.c.

◆ vl_endianfun

#define vl_endianfun   /* define message structures */

Definition at line 45 of file ipsec_api.c.

◆ vl_msg_name_crc_list

#define vl_msg_name_crc_list

Definition at line 1217 of file ipsec_api.c.

◆ vl_print

#define vl_print (   handle,
  ... 
)    vlib_cli_output (handle, __VA_ARGS__)

Definition at line 50 of file ipsec_api.c.

◆ vl_printfun

#define vl_printfun

Definition at line 51 of file ipsec_api.c.

◆ vl_typedefs

#define vl_typedefs   /* define message structures */

Definition at line 41 of file ipsec_api.c.

Typedef Documentation

◆ ipsec_dump_walk_ctx_t

◆ ipsec_sa_dump_match_ctx_t

Function Documentation

◆ ipsec_api_hookup()

static clib_error_t* ipsec_api_hookup ( vlib_main_t vm)
static

Definition at line 1230 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ ipsec_sa_dump_match_sa()

static walk_rc_t ipsec_sa_dump_match_sa ( index_t  itpi,
void *  arg 
)
static

Definition at line 876 of file ipsec_api.c.

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

◆ ipsec_spd_action_decode()

static int ipsec_spd_action_decode ( vl_api_ipsec_spd_action_t  in,
ipsec_policy_action_t out 
)
static

Definition at line 252 of file ipsec_api.c.

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

◆ ipsec_spd_action_encode()

vl_api_ipsec_spd_action_t ipsec_spd_action_encode ( ipsec_policy_action_t  in)

Definition at line 527 of file ipsec_api.c.

+ Here is the caller graph for this function:

◆ ipsec_tun_mk_input_sa_id()

static u32 ipsec_tun_mk_input_sa_id ( u32  ti)
static

Definition at line 670 of file ipsec_api.c.

+ Here is the caller graph for this function:

◆ ipsec_tun_mk_output_sa_id()

static u32 ipsec_tun_mk_output_sa_id ( u32  ti)
static

Definition at line 676 of file ipsec_api.c.

+ Here is the caller graph for this function:

◆ send_ipsec_sa_details()

static walk_rc_t send_ipsec_sa_details ( ipsec_sa_t sa,
void *  arg 
)
static

Definition at line 904 of file ipsec_api.c.

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

◆ send_ipsec_sa_v2_details()

static walk_rc_t send_ipsec_sa_v2_details ( ipsec_sa_t sa,
void *  arg 
)
static

Definition at line 996 of file ipsec_api.c.

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

◆ send_ipsec_spd_details()

static void send_ipsec_spd_details ( ipsec_policy_t p,
vl_api_registration_t reg,
u32  context 
)
static

Definition at line 543 of file ipsec_api.c.

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

◆ send_ipsec_spd_interface_details()

static void send_ipsec_spd_interface_details ( vl_api_registration_t reg,
u32  spd_index,
u32  sw_if_index,
u32  context 
)
static

Definition at line 616 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ send_ipsec_spds_details()

static void send_ipsec_spds_details ( ipsec_spd_t spd,
vl_api_registration_t reg,
u32  context 
)
static

Definition at line 485 of file ipsec_api.c.

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

◆ send_ipsec_tunnel_protect_details()

static walk_rc_t send_ipsec_tunnel_protect_details ( index_t  itpi,
void *  arg 
)
static

Definition at line 185 of file ipsec_api.c.

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

◆ setup_message_id_table()

static void setup_message_id_table ( api_main_t am)
static

Definition at line 1222 of file ipsec_api.c.

+ Here is the caller graph for this function:

◆ vl_api_ipsec_backend_dump_t_handler()

static void vl_api_ipsec_backend_dump_t_handler ( vl_api_ipsec_backend_dump_t mp)
static

Definition at line 1116 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_interface_add_del_spd_t_handler()

static void vl_api_ipsec_interface_add_del_spd_t_handler ( vl_api_ipsec_interface_add_del_spd_t mp)
static

Definition at line 98 of file ipsec_api.c.

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

◆ vl_api_ipsec_itf_create_t_handler()

static void vl_api_ipsec_itf_create_t_handler ( vl_api_ipsec_itf_create_t mp)
static

Definition at line 833 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_itf_delete_t_handler()

static void vl_api_ipsec_itf_delete_t_handler ( vl_api_ipsec_itf_delete_t mp)
static

Definition at line 854 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_itf_dump_t_handler()

static void vl_api_ipsec_itf_dump_t_handler ( vl_api_ipsec_itf_dump_t mp)
static

Definition at line 865 of file ipsec_api.c.

◆ vl_api_ipsec_sa_dump_t_handler()

static void vl_api_ipsec_sa_dump_t_handler ( vl_api_ipsec_sa_dump_t mp)
static

Definition at line 974 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_sa_v2_dump_t_handler()

static void vl_api_ipsec_sa_v2_dump_t_handler ( vl_api_ipsec_sa_dump_t mp)
static

Definition at line 1069 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_sad_entry_add_del_t_handler()

static void vl_api_ipsec_sad_entry_add_del_t_handler ( vl_api_ipsec_sad_entry_add_del_t mp)
static

Definition at line 338 of file ipsec_api.c.

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

◆ vl_api_ipsec_sad_entry_add_del_v2_t_handler()

static void vl_api_ipsec_sad_entry_add_del_v2_t_handler ( vl_api_ipsec_sad_entry_add_del_v2_t mp)
static

Definition at line 408 of file ipsec_api.c.

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

◆ vl_api_ipsec_select_backend_t_handler()

static void vl_api_ipsec_select_backend_t_handler ( vl_api_ipsec_select_backend_t mp)
static

Definition at line 1161 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_set_async_mode_t_handler()

static void vl_api_ipsec_set_async_mode_t_handler ( vl_api_ipsec_set_async_mode_t mp)
static

Definition at line 1199 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_spd_add_del_t_handler()

static void vl_api_ipsec_spd_add_del_t_handler ( vl_api_ipsec_spd_add_del_t mp)
static

Definition at line 81 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_spd_dump_t_handler()

static void vl_api_ipsec_spd_dump_t_handler ( vl_api_ipsec_spd_dump_t mp)
static

Definition at line 578 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_spd_entry_add_del_t_handler()

static void vl_api_ipsec_spd_entry_add_del_t_handler ( vl_api_ipsec_spd_entry_add_del_t mp)
static

Definition at line 269 of file ipsec_api.c.

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

◆ vl_api_ipsec_spd_interface_dump_t_handler()

static void vl_api_ipsec_spd_interface_dump_t_handler ( vl_api_ipsec_spd_interface_dump_t mp)
static

Definition at line 633 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_spds_dump_t_handler()

static void vl_api_ipsec_spds_dump_t_handler ( vl_api_ipsec_spds_dump_t mp)
static

Definition at line 506 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_tunnel_if_add_del_t_handler()

static void vl_api_ipsec_tunnel_if_add_del_t_handler ( vl_api_ipsec_tunnel_if_add_del_t mp)
static

Definition at line 682 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_tunnel_if_set_sa_t_handler()

static void vl_api_ipsec_tunnel_if_set_sa_t_handler ( vl_api_ipsec_tunnel_if_set_sa_t mp)
static

Definition at line 1091 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_tunnel_protect_del_t_handler()

static void vl_api_ipsec_tunnel_protect_del_t_handler ( vl_api_ipsec_tunnel_protect_del_t mp)
static

Definition at line 154 of file ipsec_api.c.

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

◆ vl_api_ipsec_tunnel_protect_dump_t_handler()

static void vl_api_ipsec_tunnel_protect_dump_t_handler ( vl_api_ipsec_tunnel_protect_dump_t mp)
static

Definition at line 219 of file ipsec_api.c.

+ Here is the call graph for this function:

◆ vl_api_ipsec_tunnel_protect_update_t_handler()

static void vl_api_ipsec_tunnel_protect_update_t_handler ( vl_api_ipsec_tunnel_protect_update_t mp)
static

Definition at line 123 of file ipsec_api.c.

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

◆ VLIB_API_INIT_FUNCTION()

VLIB_API_INIT_FUNCTION ( ipsec_api_hookup  )
+ Here is the caller graph for this function: