|
FD.io VPP
v21.10.1-2-g0a485f517
Vector Packet Processing
|
Go to the documentation of this file.
30 #define NAT44_ED_EXPECTED_ARGUMENT "expected required argument(s)"
41 u8 enable_set = 0, enable = 0, mode_set = 0;
48 if (!mode_set &&
unformat (line_input,
"static-mapping-only"))
51 c.static_mapping_only = 1;
52 if (
unformat (line_input,
"connection-tracking"))
54 c.connection_tracking = 1;
57 else if (
unformat (line_input,
"inside-vrf %u", &
c.inside_vrf));
58 else if (
unformat (line_input,
"outside-vrf %u", &
c.outside_vrf));
59 else if (
unformat (line_input,
"sessions %u", &
c.sessions));
63 if (
unformat (line_input,
"disable"))
65 else if (
unformat (line_input,
"enable"))
147 case VNET_API_ERROR_INVALID_WORKER:
150 case VNET_API_ERROR_FEATURE_DISABLED:
152 "Supported only if 2 or more workes available.");
227 u8 enable_set = 0, enable = 0;
234 if (
unformat (line_input,
"domain %d", &domain_id))
238 else if (!enable_set)
241 if (
unformat (line_input,
"disable"))
243 else if (
unformat (line_input,
"enable"))
283 else if (
unformat (input,
"verbose"))
322 if (
unformat (line_input,
"disable"))
324 else if (
unformat (line_input,
"%d", &mss))
361 u32 start_host_order, end_host_order;
375 if (
unformat (line_input,
"%U - %U",
383 else if (
unformat (line_input,
"twice-nat"))
385 else if (
unformat (line_input,
"del"))
401 start_host_order = clib_host_to_net_u32 (
start_addr.as_u32);
402 end_host_order = clib_host_to_net_u32 (
end_addr.as_u32);
404 if (end_host_order < start_host_order)
410 count = (end_host_order - start_host_order) + 1;
432 case VNET_API_ERROR_VALUE_EXIST:
435 case VNET_API_ERROR_NO_SUCH_ENTRY:
438 case VNET_API_ERROR_UNSPECIFIED:
468 clib_dlist_remove_head (tsm->lru_pool, tsm->n##_lru_head_index); \
469 if (~0 != oldest_index) \
471 oldest_elt = pool_elt_at_index (tsm->lru_pool, oldest_index); \
472 s = pool_elt_at_index (tsm->sessions, oldest_elt->value); \
473 sess_timeout_time = \
474 s->last_heard + (f64) nat44_session_get_timeout (sm, s); \
475 vlib_cli_output (vm, d " LRU min session timeout %llu (now %llu)", \
476 sess_timeout_time, now); \
477 clib_dlist_addhead (tsm->lru_pool, tsm->n##_lru_head_index, \
480 _ (tcp_estab,
"established tcp");
481 _ (tcp_trans,
"transitory tcp");
483 _ (unk_proto,
"unknown protocol");
500 u64 sess_timeout_time = 0;
502 u32 udp_sessions = 0;
503 u32 tcp_sessions = 0;
504 u32 icmp_sessions = 0;
508 u32 transitory_wait_closed = 0;
509 u32 transitory_closed = 0;
524 sess_timeout_time = s->last_heard +
526 if (
now >= sess_timeout_time)
529 switch (s->nat_proto)
531 case NAT_PROTOCOL_ICMP:
534 case NAT_PROTOCOL_TCP:
538 if (s->tcp_closed_timestamp)
540 if (
now >= s->tcp_closed_timestamp)
546 ++transitory_wait_closed;
554 case NAT_PROTOCOL_UDP:
569 sess_timeout_time = s->last_heard +
571 if (
now >= sess_timeout_time)
574 switch (s->nat_proto)
576 case NAT_PROTOCOL_ICMP:
579 case NAT_PROTOCOL_TCP:
583 if (s->tcp_closed_timestamp)
585 if (
now >= s->tcp_closed_timestamp)
591 ++transitory_wait_closed;
599 case NAT_PROTOCOL_UDP:
615 transitory_wait_closed);
639 #define _(N, i, n, s) \
640 vlib_cli_output (vm, " %d busy %s ports", ap->busy_##n##_ports, s);
653 #define _(N, i, n, s) \
654 vlib_cli_output (vm, " %d busy %s ports", ap->busy_##n##_ports, s);
669 u32 *inside_sw_if_indices = 0;
670 u32 *outside_sw_if_indices = 0;
671 u8 is_output_feature = 0;
672 int i,
rv, is_del = 0;
688 else if (
unformat (line_input,
"output-feature"))
689 is_output_feature = 1;
690 else if (
unformat (line_input,
"del"))
700 if (
vec_len (inside_sw_if_indices))
702 for (
i = 0;
i <
vec_len (inside_sw_if_indices);
i++)
705 if (is_output_feature)
718 is_del ?
"del" :
"add",
737 is_del ?
"del" :
"add",
746 if (
vec_len (outside_sw_if_indices))
748 for (
i = 0;
i <
vec_len (outside_sw_if_indices);
i++)
751 if (is_output_feature)
764 is_del ?
"del" :
"add",
783 is_del ?
"del" :
"add",
845 u8 l_port_set = 0, e_port_set = 0;
870 else if (
unformat (line_input,
"external %U %u",
877 else if (
unformat (line_input,
"external %U",
891 else if (
unformat (line_input,
"self-twice-nat"))
895 else if (
unformat (line_input,
"twice-nat"))
899 else if (
unformat (line_input,
"out2in-only"))
903 else if (
unformat (line_input,
"del"))
915 if (l_port_set != e_port_set)
927 l_port = clib_host_to_net_u16 (l_port);
928 e_port = clib_host_to_net_u16 (e_port);
949 case VNET_API_ERROR_INVALID_VALUE:
952 case VNET_API_ERROR_NO_SUCH_ENTRY:
958 case VNET_API_ERROR_NO_SUCH_FIB:
961 case VNET_API_ERROR_VALUE_EXIST:
984 int rv, is_add = 1, port_set = 0;
999 else if (
unformat (line_input,
"external %U",
1011 else if (
unformat (line_input,
"del"))
1029 port = clib_host_to_net_u16 (
port);
1048 case VNET_API_ERROR_INVALID_VALUE:
1051 case VNET_API_ERROR_NO_SUCH_ENTRY:
1057 case VNET_API_ERROR_NO_SUCH_FIB:
1060 case VNET_API_ERROR_VALUE_EXIST:
1094 if (
unformat (line_input,
"local %U:%u probability %u",
1098 local.addr = l_addr;
1099 local.port = (
u16) l_port;
1103 else if (
unformat (line_input,
"local %U:%u vrf %u probability %u",
1108 local.addr = l_addr;
1109 local.port = (
u16) l_port;
1122 else if (
unformat (line_input,
"twice-nat"))
1126 else if (
unformat (line_input,
"self-twice-nat"))
1130 else if (
unformat (line_input,
"out2in-only"))
1134 else if (
unformat (line_input,
"del"))
1138 else if (
unformat (line_input,
"affinity %u", &affinity))
1163 flags, 0, affinity);
1172 case VNET_API_ERROR_INVALID_VALUE:
1175 case VNET_API_ERROR_NO_SUCH_ENTRY:
1181 case VNET_API_ERROR_VALUE_EXIST:
1214 if (
unformat (line_input,
"local %U:%u probability %u",
1217 else if (
unformat (line_input,
"local %U:%u vrf %u probability %u",
1227 else if (
unformat (line_input,
"del"))
1237 if (!l_port || !e_port)
1254 case VNET_API_ERROR_INVALID_VALUE:
1258 case VNET_API_ERROR_NO_SUCH_ENTRY:
1261 case VNET_API_ERROR_VALUE_EXIST:
1264 case VNET_API_ERROR_UNSPECIFIED:
1317 else if (
unformat (line_input,
"twice-nat"))
1321 else if (
unformat (line_input,
"del"))
1438 if (
unformat (line_input,
"%u", &session_limit))
1484 else if (
unformat (line_input,
"in"))
1489 else if (
unformat (line_input,
"out"))
1496 else if (
unformat (line_input,
"external-host %U:%u",
1508 clib_host_to_net_u16 (eh_port),
1536 u8 enable_set = 0, enable = 0;
1546 if (
unformat (line_input,
"disable"))
1548 else if (
unformat (line_input,
"enable"))
1583 else if (
unformat (line_input,
"tcp-established %u",
1585 else if (
unformat (line_input,
"tcp-transitory %u",
1588 else if (
unformat (line_input,
"reset"))
1625 u32 frame_queue_nelts = 0;
1632 if (
unformat (line_input,
"%u", &frame_queue_nelts))
1641 if (!frame_queue_nelts)
1672 .short_help =
"nat44 <enable [sessions <max-number>] [static-mapping-only "
1673 "connection-tracking] [inside-vrf <vrf-id>] "
1674 "[outside-vrf <vrf-id>]>|disable",
1686 .path =
"set nat workers",
1688 .short_help =
"set nat workers <workers-list>",
1702 .path =
"show nat workers",
1703 .short_help =
"show nat workers",
1717 .path =
"set nat timeout",
1720 "set nat timeout [udp <sec> | tcp-established <sec> "
1721 "tcp-transitory <sec> | icmp <sec> | reset]",
1736 .path =
"show nat timeouts",
1737 .short_help =
"show nat timeouts",
1748 .path =
"set nat frame-queue-nelts",
1750 .short_help =
"set nat frame-queue-nelts <number>",
1761 .path =
"nat set logging level",
1763 .short_help =
"nat set logging level <level>",
1776 .path =
"nat ipfix logging",
1778 .short_help =
"nat ipfix logging disable|<enable [domain <domain-id>] "
1779 "[src-port <port>]>",
1793 .path =
"nat mss-clamping",
1794 .short_help =
"nat mss-clamping <mss-value>|disable",
1805 .path =
"show nat mss-clamping",
1806 .short_help =
"show nat mss-clamping",
1817 .path =
"show nat44 hash tables",
1818 .short_help =
"show nat44 hash tables [detail|verbose]",
1834 .path =
"nat44 add address",
1835 .short_help =
"nat44 add address <ip4-range-start> [- <ip4-range-end>] "
1836 "[tenant-vrf <vrf-id>] [twice-nat] [del]",
1848 .path =
"show nat44 summary",
1849 .short_help =
"show nat44 summary",
1878 .path =
"show nat44 addresses",
1879 .short_help =
"show nat44 addresses",
1894 .path =
"set interface nat44",
1896 .short_help =
"set interface nat44 in <intfc> out <intfc> [output-feature] "
1911 .path =
"show nat44 interfaces",
1912 .short_help =
"show nat44 interfaces",
1936 .path =
"nat44 add static mapping",
1939 "nat44 add static mapping tcp|udp|icmp local <addr> [<port|icmp-echo-id>] "
1940 "external <addr> [<port|icmp-echo-id>] [vrf <table-id>] [twice-nat|self-twice-nat] "
1941 "[out2in-only] [exact <pool-addr>] [del]",
1958 .path =
"nat44 add identity mapping",
1960 .short_help =
"nat44 add identity mapping <ip4-addr>|external <interface> "
1961 "[<protocol> <port>] [vrf <table-id>] [del]",
1975 .path =
"nat44 add load-balancing static mapping",
1978 "nat44 add load-balancing static mapping protocol tcp|udp "
1979 "external <addr>:<port> local <addr>:<port> [vrf <table-id>] "
1980 "probability <n> [twice-nat|self-twice-nat] [out2in-only] "
1981 "[affinity <timeout-seconds>] [del]",
1994 .path =
"nat44 add load-balancing back-end",
1997 "nat44 add load-balancing back-end protocol tcp|udp "
1998 "external <addr>:<port> local <addr>:<port> [vrf <table-id>] "
1999 "probability <n> [del]",
2018 .path =
"show nat44 static mappings",
2019 .short_help =
"show nat44 static mappings",
2032 .path =
"nat44 add interface address",
2033 .short_help =
"nat44 add interface address <interface> [twice-nat] [del]",
2049 .path =
"show nat44 interface address",
2050 .short_help =
"show nat44 interface address",
2061 .path =
"show nat44 sessions",
2062 .short_help =
"show nat44 sessions",
2073 .path =
"set nat44 session limit",
2074 .short_help =
"set nat44 session limit <limit> [vrf <table-id>]",
2088 .path =
"nat44 del session",
2089 .short_help =
"nat44 del session in|out <addr>:<port> tcp|udp|icmp [vrf <id>] [external-host <addr>:<port>]",
2106 .path =
"nat44 forwarding",
2107 .short_help =
"nat44 forwarding enable|disable",
static bool nat44_ed_is_interface_outside(snat_interface_t *i)
Check if NAT interface is outside.
snat_static_map_resolve_t * to_resolve
struct nat_timeouts_t::@742 tcp
int snat_set_workers(uword *bitmap)
int nat44_update_session_limit(u32 session_limit, u32 vrf_id)
Update NAT44 session limit flushing all data (session limit, vrf id)
static vlib_cli_command_t set_workers_command
(constructor) VLIB_CLI_COMMAND (set_workers_command)
static clib_error_t * nat_show_timeouts_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
int nat44_ed_del_static_mapping(ip4_address_t l_addr, ip4_address_t e_addr, u16 l_port, u16 e_port, nat_protocol_t proto, u32 vrf_id, u32 sw_if_index, u32 flags)
int nat44_ed_add_output_interface(u32 sw_if_index)
static vlib_cli_command_t snat_forwarding_set_command
(constructor) VLIB_CLI_COMMAND (snat_forwarding_set_command)
snat_static_mapping_t * static_mappings
vl_api_address_t end_addr
snat_address_t * twice_nat_addresses
#define nat_log_info(...)
static vlib_cli_command_t nat44_show_hash
(constructor) VLIB_CLI_COMMAND (nat44_show_hash)
static clib_error_t * add_address_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t nat44_set_session_limit_command
(constructor) VLIB_CLI_COMMAND (nat44_set_session_limit_command)
int nat44_ed_add_static_mapping(ip4_address_t l_addr, ip4_address_t e_addr, u16 l_port, u16 e_port, nat_protocol_t proto, u32 vrf_id, u32 sw_if_index, u32 flags, ip4_address_t pool_addr, u8 *tag)
unformat_function_t unformat_nat_protocol
static vlib_cli_command_t set_interface_snat_command
(constructor) VLIB_CLI_COMMAND (set_interface_snat_command)
static u32 nat44_session_get_timeout(snat_main_t *sm, snat_session_t *s)
int nat44_ed_del_session(snat_main_t *sm, ip4_address_t *addr, u16 port, ip4_address_t *eh_addr, u16 eh_port, u8 proto, u32 vrf_id, int is_in)
Delete NAT44 endpoint-dependent session.
static clib_error_t * nat44_ed_enable_disable_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t nat44_show_addresses_command
(constructor) VLIB_CLI_COMMAND (nat44_show_addresses_command)
snat_interface_t * interfaces
#define clib_error_return(e, args...)
clib_bihash_16_8_t affinity_hash
#define NAT_SM_FLAG_ADDR_ONLY
static vlib_cli_command_t set_frame_queue_nelts_command
(constructor) VLIB_CLI_COMMAND (set_frame_queue_nelts_command)
static clib_error_t * nat_set_mss_clamping_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
vlib_main_t * vm
X-connect all packets from the HOST to the PHY.
static vlib_cli_command_t nat44_show_summary_command
(constructor) VLIB_CLI_COMMAND (nat44_show_summary_command)
static vlib_cli_command_t snat_ipfix_logging_enable_disable_command
(constructor) VLIB_CLI_COMMAND (snat_ipfix_logging_enable_disable_command)
NAT port/address allocation lib.
static vlib_cli_command_t snat_add_interface_address_command
(constructor) VLIB_CLI_COMMAND (snat_add_interface_address_command)
int nat44_ed_add_lb_static_mapping(ip4_address_t e_addr, u16 e_port, nat_protocol_t proto, nat44_lb_addr_port_t *locals, u32 flags, u8 *tag, u32 affinity)
static void nat44_show_lru_summary(vlib_main_t *vm, snat_main_per_thread_data_t *tsm, u64 now, u64 sess_timeout_time)
snat_address_t * addresses
vl_api_address_t start_addr
clib_bihash_8_8_t static_mapping_by_external
vlib_worker_thread_t * vlib_worker_threads
format_function_t format_snat_static_mapping
int nat44_ed_add_interface(u32 sw_if_index, u8 is_inside)
#define NAT_SM_FLAG_OUT2IN_ONLY
static vlib_cli_command_t add_lb_static_mapping_command
(constructor) VLIB_CLI_COMMAND (add_lb_static_mapping_command)
#define NAT_SM_FLAG_IDENTITY_NAT
static clib_error_t * add_lb_static_mapping_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t set_timeout_command
(constructor) VLIB_CLI_COMMAND (set_timeout_command)
#define pool_foreach(VAR, POOL)
Iterate through pool.
static clib_error_t * set_timeout_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
#define vec_len(v)
Number of elements in vector (rvalue-only, NULL tolerant)
snat_main_per_thread_data_t * per_thread_data
int nat44_ed_del_output_interface(u32 sw_if_index)
#define vec_add1(V, E)
Add 1 element to end of vector (unspecified alignment).
clib_bihash_16_8_t flow_hash
int nat44_ed_del_interface_address(u32 sw_if_index, u8 twice_nat)
#define vec_elt_at_index(v, i)
Get vector value at index i checking that i is in bounds.
static clib_error_t * nat44_show_addresses_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
vnet_main_t * vnet_get_main(void)
u32 ft_table_id
Table ID (hash key) for this FIB.
static_always_inline u8 nat_proto_to_ip_proto(nat_protocol_t nat_proto)
static vlib_cli_command_t nat44_del_session_command
(constructor) VLIB_CLI_COMMAND (nat44_del_session_command)
static unsigned char * print(const cJSON *const item, cJSON_bool format, const internal_hooks *const hooks)
#define vec_foreach_index(var, v)
Iterate over vector indices.
#define clib_bitmap_free(v)
Free a bitmap.
static clib_error_t * nat44_show_hash_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
#define NAT_SM_FLAG_TWICE_NAT
static vlib_cli_command_t add_lb_backend_command
(constructor) VLIB_CLI_COMMAND (add_lb_backend_command)
#define NAT_SM_FLAG_EXACT_ADDRESS
static clib_error_t * snat_add_interface_address_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t nat_set_mss_clamping_command
(constructor) VLIB_CLI_COMMAND (nat_set_mss_clamping_command)
static clib_error_t * add_lb_backend_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
vl_api_ip_port_and_mask_t src_port
static clib_error_t * set_frame_queue_nelts_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t nat44_show_static_mappings_command
(constructor) VLIB_CLI_COMMAND (nat44_show_static_mappings_command)
#define VLIB_CLI_COMMAND(x,...)
format_function_t format_snat_static_map_to_resolve
static vlib_cli_command_t nat44_show_sessions_command
(constructor) VLIB_CLI_COMMAND (nat44_show_sessions_command)
static vlib_cli_command_t nat_show_timeouts_command
(constructor) VLIB_CLI_COMMAND (nat_show_timeouts_command)
int nat44_ed_add_del_lb_static_mapping_local(ip4_address_t e_addr, u16 e_port, ip4_address_t l_addr, u16 l_port, nat_protocol_t proto, u32 vrf_id, u8 probability, u8 is_add)
snat_session_t * sessions
static clib_error_t * add_identity_mapping_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
int nat44_plugin_enable(nat44_config_t c)
int nat44_ed_add_address(ip4_address_t *addr, u32 vrf_id, u8 twice_nat)
void vlib_cli_output(vlib_main_t *vm, char *fmt,...)
int nat44_ed_set_frame_queue_nelts(u32 frame_queue_nelts)
static vlib_cli_command_t nat44_ed_enable_disable_command
(constructor) VLIB_CLI_COMMAND (nat44_ed_enable_disable_command)
static vlib_cli_command_t add_address_command
(constructor) VLIB_CLI_COMMAND (add_address_command)
static void increment_v4_address(ip4_address_t *a)
static vlib_cli_command_t nat44_show_interfaces_command
(constructor) VLIB_CLI_COMMAND (nat44_show_interfaces_command)
int nat44_ed_del_lb_static_mapping(ip4_address_t e_addr, u16 e_port, nat_protocol_t proto, u32 flags)
#define NAT44_ED_EXPECTED_ARGUMENT
#define vec_free(V)
Free vector's memory (no header).
NAT plugin client-IP based session affinity for load-balancing.
static clib_error_t * nat44_show_interfaces_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t nat_show_mss_clamping_command
(constructor) VLIB_CLI_COMMAND (nat_show_mss_clamping_command)
int nat_ipfix_logging_enable_disable(int enable, u32 domain_id, u16 src_port)
Enable/disable NAT plugin IPFIX logging.
static clib_error_t * nat44_del_session_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
u32 * max_translations_per_fib
static clib_error_t * set_workers_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
format_function_t format_vnet_sw_if_index_name
unformat_function_t unformat_vnet_sw_interface
static_always_inline void nat_reset_timeouts(nat_timeouts_t *timeouts)
fib_table_t * fib_table_get(fib_node_index_t index, fib_protocol_t proto)
Get a pointer to a FIB table.
static bool nat44_ed_is_interface_inside(snat_interface_t *i)
Check if NAT interface is inside.
static clib_error_t * nat44_show_static_mappings_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
u32 * auto_add_sw_if_indices
static clib_error_t * snat_set_log_level_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
#define vec_foreach(var, vec)
Vector iterator.
clib_bihash_8_8_t static_mapping_by_local
static vlib_cli_command_t nat_show_workers_command
(constructor) VLIB_CLI_COMMAND (nat_show_workers_command)
static clib_error_t * nat44_show_summary_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static uword pool_elts(void *v)
Number of active elements in a pool.
static clib_error_t * snat_feature_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static clib_error_t * nat44_set_session_limit_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static clib_error_t * snat_ipfix_logging_enable_disable_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static clib_error_t * nat_show_mss_clamping_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t add_static_mapping_command
(constructor) VLIB_CLI_COMMAND (add_static_mapping_command)
static vlib_cli_command_t snat_set_log_level_command
(constructor) VLIB_CLI_COMMAND (snat_set_log_level_command)
#define NAT_SM_FLAG_SWITCH_ADDRESS
clib_memset(h->entries, 0, sizeof(h->entries[0]) *entries)
#define NAT_SM_FLAG_SELF_TWICE_NAT
int nat44_plugin_disable()
static vlib_cli_command_t add_identity_mapping_command
(constructor) VLIB_CLI_COMMAND (add_identity_mapping_command)
static f64 vlib_time_now(vlib_main_t *vm)
static clib_error_t * nat_show_workers_commnad_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static vlib_cli_command_t nat44_show_interface_address_command
(constructor) VLIB_CLI_COMMAND (nat44_show_interface_address_command)
vl_api_interface_index_t sw_if_index
int nat44_ed_del_interface(u32 sw_if_index, u8 is_inside)
static clib_error_t * snat_forwarding_set_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static clib_error_t * add_static_mapping_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static clib_error_t * nat44_show_sessions_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
int nat44_ed_add_interface_address(u32 sw_if_index, u8 twice_nat)
__clib_export uword unformat_bitmap_list(unformat_input_t *input, va_list *va)
unformat a list of bit ranges into a bitmap (eg "0-3,5-7,11" )
int nat44_ed_del_address(ip4_address_t addr, u8 delete_sm, u8 twice_nat)
u32 * auto_add_sw_if_indices_twice_nat
format_function_t format_snat_session
nat_affinity_main_t nat_affinity_main
static clib_error_t * nat44_show_interface_address_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
snat_interface_t * output_feature_interfaces
vl_api_wireguard_peer_flags_t flags