19 #include <nat/nat66/nat66.api_enum.h> 20 #include <nat/nat66/nat66.api_types.h> 23 #define REPLY_MSG_ID_BASE nm->msg_id_base 35 vl_api_nat66_add_del_interface_reply_t *rmp;
54 vl_api_nat66_add_del_static_mapping_reply_t *rmp;
55 ip6_address_t l_addr, e_addr;
63 clib_net_to_host_u32 (mp->
vrf_id),
66 REPLY_MACRO (VL_API_NAT66_ADD_DEL_STATIC_MAPPING_REPLY);
163 #include <nat/nat66/nat66.api.c>
vl_api_nat_config_flags_t flags
clib_memset(h->entries, 0, sizeof(h->entries[0]) *entries)
static void vl_api_send_msg(vl_api_registration_t *rp, u8 *elem)
static int nat66_api_interface_walk(nat66_interface_t *i, void *arg)
vl_api_ip6_address_t external_ip_address
Combined counter to hold both packets and byte differences.
Dump NAT66 static mappings.
void * vl_msg_api_alloc(int nbytes)
#define clib_memcpy(d, s, n)
#define nat66_interface_is_inside(i)
NAT66 interface details response.
vl_api_registration_t * rp
clib_error_t * nat66_plugin_api_hookup(vlib_main_t *vm)
vl_api_ip6_address_t local_ip_address
static void vl_api_nat66_add_del_interface_t_handler(vl_api_nat66_add_del_interface_t *mp)
void nat66_static_mappings_walk(nat66_static_mapping_walk_fn_t fn, void *ctx)
counter_t packets
packet counter
Enable/disable NAT66 feature on the interface.
vl_api_ip6_address_t external_ip_address
An API client registration, only in vpp/vlib.
static void setup_message_id_table(api_main_t *am)
#define BAD_SW_IF_INDEX_LABEL
vl_api_interface_index_t sw_if_index
int nat66_interface_add_del(u32 sw_if_index, u8 is_inside, u8 is_add)
u32 ft_table_id
Table ID (hash key) for this FIB.
static void vlib_get_combined_counter(const vlib_combined_counter_main_t *cm, u32 index, vlib_counter_t *result)
Get the value of a combined counter, never called in the speed path Scrapes the entire set of per-thr...
struct nat66_api_walk_ctx_t_ nat66_api_walk_ctx_t
sll srl srl sll sra u16x4 i
NAT66 static mapping details response.
vl_api_nat_config_flags_t flags
static vl_api_registration_t * vl_api_client_index_to_registration(u32 index)
static void vl_api_nat66_add_del_static_mapping_t_handler(vl_api_nat66_add_del_static_mapping_t *mp)
static void vl_api_nat66_static_mapping_dump_t_handler(vl_api_nat66_static_mapping_dump_t *mp)
counter_t bytes
byte counter
vlib_combined_counter_main_t session_counters
Session counters.
static int nat66_api_static_mapping_walk(nat66_static_mapping_t *m, void *arg)
void nat66_interfaces_walk(nat66_interface_walk_fn_t fn, void *ctx)
Dump interfaces with NAT66 feature.
vl_api_interface_index_t sw_if_index
fib_table_t * fib_table_get(fib_node_index_t index, fib_protocol_t proto)
Get a pointer to a FIB table.
int nat66_static_mapping_add_del(ip6_address_t *l_addr, ip6_address_t *e_addr, u32 vrf_id, u8 is_add)
nat66_static_mapping_t * sm
Static mapping pool.
static void vl_api_nat66_interface_dump_t_handler(vl_api_nat66_interface_dump_t *mp)
NAT66 global declarations.
vl_api_ip6_address_t local_ip_address
#define VALIDATE_SW_IF_INDEX(mp)
A protocol Independent FIB table.