FD.io VPP  v20.05.1-6-gf53edbc3b
Vector Packet Processing
nat.api
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2016 Cisco and/or its affiliates.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at:
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 option version = "5.2.0";
17 import "vnet/ip/ip_types.api";
18 import "vnet/interface_types.api";
19 
20 /**
21  * @file nat.api
22  * @brief VPP control-plane API messages.
23  *
24  * This file defines VPP control-plane API messages which are generally
25  * called through a shared memory interface.
26  */
27 
28 /*
29  * Common NAT plugin APIs
30  */
31 
33 {
34  NAT_IS_NONE = 0x00,
40  NAT_IS_INSIDE = 0x20,
41  NAT_IS_STATIC = 0x40,
43 };
44 
45 /** \brief Control ping from client to api server request
46  @param client_index - opaque cookie to identify the sender
47  @param context - sender context, to match reply w/ request
48 */
49 define nat_control_ping
50 {
53 };
54 
55 /** \brief Control ping from the client to the server response
56  @param client_index - opaque cookie to identify the sender
57  @param context - sender context, to match reply w/ request
58  @param retval - return code for the request
59  @param vpe_pid - the pid of the vpe, returned by the server
60 */
61 define nat_control_ping_reply
62 {
67 };
68 
69 /** \brief Show NAT plugin startup config
70  @param client_index - opaque cookie to identify the sender
71  @param context - sender context, to match reply w/ request
72 */
73 define nat_show_config
74 {
77 };
78 
79 /** \brief Show NAT plugin startup config reply
80  @param context - sender context, to match reply w/ request
81  @param retval - return code for the request
82  @param static_mapping_only - if true dynamic translations disabled
83  @param static_mapping_connection_tracking - if true create session data
84  @param deterministic - if true deterministic mapping
85  @param endpoint_dependent - if true endpoint-dependent mode
86  @param out2in_dpo - if true out2in dpo mode
87  @param dslite_ce - if true DS-Lite is CE/B4 element, if false AFTR elemet
88  @param translation_buckets - number of translation hash buckets
89  @param translation_memory_size - translation hash memory size
90  @param user_buckets - number of user hash buckets
91  @param user_memory_size - user hash memory size
92  @param max_translations_per_user - maximum number of translations per user
93  @param outside_vrf_id - outside VRF id
94  @param inside_vrf_id - default inside VRF id
95  @param nat64_bib_buckets - number of NAT64 BIB hash buckets
96  @param nat64_bib_memory_size - memory size of NAT64 BIB hash
97  @param nat64_st_buckets - number of NAT64 session table hash buckets
98  @param nat64_st_memory_size - memory size of NAT64 session table hash
99 */
100 define nat_show_config_reply
101 {
109  bool dslite_ce;
121 };
122 
124 {
125  NAT_LOG_NONE = 0x00,
129  NAT_LOG_INFO = 0x04,
131 };
132 
133 /** \brief Run nat44 garbage collection
134  @param client_index - opaque cookie to identify the sender
135  @param context - sender context, to match reply w/ request
136 */
137 autoreply define nat44_session_cleanup {
140 };
141 
142 /** \brief NAT44 set session limit
143  @param client_index - opaque cookie to identify the sender
144  @param context - sender context, to match reply w/ request
145  @param session_limit - session limit
146  @param vrf_id - vrf id
147 */
148 autoreply define nat44_set_session_limit {
153 };
154 
155 /** \brief Set NAT logging level
156  @param client_index - opaque cookie to identify the sender
157  @param context - sender context, to match reply w/ request
158  @param log_level - logging level
159 */
160 autoreply define nat_set_log_level {
163  vl_api_nat_log_level_t log_level;
164 };
165 
166 /** \brief Set NAT workers
167  @param client_index - opaque cookie to identify the sender
168  @param context - sender context, to match reply w/ request
169  @param worker_mask - NAT workers mask
170 */
171 autoreply define nat_set_workers {
175 };
176 
177 /** \brief Dump NAT workers
178  @param client_index - opaque cookie to identify the sender
179  @param context - sender context, to match reply w/ request
180 */
181 define nat_worker_dump {
184 };
185 
186 /** \brief NAT workers details response
187  @param context - sender context, to match reply w/ request
188  @param worker_index - worker index
189  @param lcore_id - lcore ID
190  @param name - worker name
191 */
192 define nat_worker_details {
196  string name[64];
197 };
198 
199 /** \brief Enable/disable NAT IPFIX logging
200  @param client_index - opaque cookie to identify the sender
201  @param context - sender context, to match reply w/ request
202  @param domain_id - observation domain ID
203  @param src_port - source port number
204  @param enable - true if enable, false if disable
205 */
206 autoreply define nat_ipfix_enable_disable {
211  bool enable;
212 };
213 
214 /** \brief Set values of timeouts for NAT sessions (seconds)
215  @param client_index - opaque cookie to identify the sender
216  @param context - sender context, to match reply w/ request
217  @param udp - UDP timeout (default 300sec)
218  @param tcp_established - TCP established timeout (default 7440sec)
219  @param tcp_transitory - TCP transitory timeout (default 240sec)
220  @param icmp - ICMP timeout (default 60sec)
221 */
222 autoreply define nat_set_timeouts {
229 };
230 
231 /** \brief Get values of timeouts for NAT sessions (seconds)
232  @param client_index - opaque cookie to identify the sender
233  @param context - sender context, to match reply w/ request
234 */
235 define nat_get_timeouts {
238 };
239 
240 /** \brief Get values of timeouts for NAT sessions reply
241  @param context - sender context, to match reply w/ request
242  @param retval - return code
243  @param udp - UDP timeout
244  @param tcp_established - TCP established timeout
245  @param tcp_transitory - TCP transitory timeout
246  @param icmp - ICMP timeout
247 */
248 define nat_get_timeouts_reply {
255 };
256 
257 /** \brief Set address and port assignment algorithm
258  @param client_index - opaque cookie to identify the sender
259  @param context - sender context, to match reply w/ request
260  @param alg - address and port assignment algorithm:
261  0 - default, 1 - MAP-E, 2 - port range
262  (see nat_addr_and_port_alloc_alg_t in nat.h)
263  @param psid_offset - number of offset bits (valid only for MAP-E alg)
264  @param psid_length - length of PSID (valid only for MAP-E alg)
265  @param psid - Port Set Identifier (PSID) value (valid only for MAP-E alg)
266  @param start_port - beginning of the port range
267  @param end_port - end of the port range
268 */
269 autoreply define nat_set_addr_and_port_alloc_alg {
278 };
279 
280 /** \brief Get address and port assignment algorithm
281  @param client_index - opaque cookie to identify the sender
282  @param context - sender context, to match reply w/ request
283 */
284 define nat_get_addr_and_port_alloc_alg {
287 };
288 
289 /** \brief Get address and port assignment algorithm reply
290  @param context - sender context, to match reply w/ request
291  @param retval - return code
292  @param alg - address and port assignment algorithm:
293  0 - default, 1 - MAP-E, 2 - port range
294  (see nat_addr_and_port_alloc_alg_t in nat.h)
295  @param psid_offset - number of offset bits (valid only for MAP-E alg)
296  @param psid_length - length of PSID (valid only for MAP-E alg)
297  @param psid - Port Set Identifier (PSID) value (valid only for MAP-E alg)
298  @param start_port - beginning of the port range
299  @param end_port - end of the port range
300 */
301 define nat_get_addr_and_port_alloc_alg_reply {
310 };
311 
312 /** \brief Set TCP MSS rewriting configuration
313  @param client_index - opaque cookie to identify the sender
314  @param context - sender context, to match reply w/ request
315  @param mss_value - MSS value to be used for MSS rewriting
316  @param enable - if true enable MSS rewriting feature else disable
317 */
318 autoreply define nat_set_mss_clamping {
322  bool enable;
323 };
324 
325 /** \brief Get TCP MSS rewriting configuration
326  @param client_index - opaque cookie to identify the sender
327  @param context - sender context, to match reply w/ request
328 */
329 define nat_get_mss_clamping {
332 };
333 
334 /** \brief Get TCP MSS rewriting configuration reply
335  @param context - sender context, to match reply w/ request
336  @param retval - return code
337  @param mss_value - MSS value to be used for MSS rewriting
338  @param enable - if true enable MSS rewriting feature else disable
339 */
340 define nat_get_mss_clamping_reply {
344  bool enable;
345 };
346 
347 /** \brief Set HA listener (local settings)
348  @param client_index - opaque cookie to identify the sender
349  @param context - sender context, to match reply w/ request
350  @param ip_address - local IP4 address
351  @param port - local UDP port number
352  @param path_mtu - path MTU between local and failover
353 */
354 autoreply define nat_ha_set_listener {
357  vl_api_ip4_address_t ip_address;
360 };
361 
362 /** \brief Set HA failover (remote settings)
363  @param client_index - opaque cookie to identify the sender
364  @param context - sender context, to match reply w/ request
365  @param ip_address - failover IP4 address
366  @param port - failvoer UDP port number
367  @param session_refresh_interval - number of seconds after which to send
368  session counters refresh
369 */
370 autoreply define nat_ha_set_failover {
373  vl_api_ip4_address_t ip_address;
376 };
377 
378 /** \brief Get HA listener/local configuration
379  @param client_index - opaque cookie to identify the sender
380  @param context - sender context, to match reply w/ request
381 */
385 };
386 
387 /** \brief Get HA listener/local configuration reply
388  @param context - sender context, to match reply w/ request
389  @param retval - return code
390  @param ip_address - local IP4 address
391  @param port - local UDP port number
392  @param path_mtu - Path MTU between local and failover
393 */
394 define nat_ha_get_listener_reply {
397  vl_api_ip4_address_t ip_address;
400 };
401 
402 /** \brief Get HA failover/remote settings
403  @param client_index - opaque cookie to identify the sender
404  @param context - sender context, to match reply w/ request
405 */
409 };
410 
411 /** \brief Get HA failover/remote settings reply
412  @param context - sender context, to match reply w/ request
413  @param retval - return code
414  @param ip_address - failover IP4 address
415  @param port - failvoer UDP port number
416  @param session_refresh_interval - number of seconds after which to send
417  session counters refresh
418 */
419 define nat_ha_get_failover_reply {
422  vl_api_ip4_address_t ip_address;
425 };
426 
427 /** \brief Flush the current HA data (for testing)
428  @param client_index - opaque cookie to identify the sender
429  @param context - sender context, to match reply w/ request
430 */
431 autoreply define nat_ha_flush {
434 };
435 
436 /** \brief Resync HA (resend existing sessions to new failover)
437  @param client_index - opaque cookie to identify the sender
438  @param context - sender context, to match reply w/ request
439  @param want_resync_event - resync completed event sent to the sender via
440  nat_ha_resync_completed_event API message if
441  non-zero
442  @param pid - sender's pid
443 */
444 autoreply define nat_ha_resync
445 {
450 };
451 
452 /** \brief Tell client about a HA resync completion event
453  @param client_index - opaque cookie to identify the sender
454  @param pid - client pid registered to receive notification
455  @param missed_count - number of missed (not ACKed) messages
456 */
457 define nat_ha_resync_completed_event
458 {
462 };
463 
465  rpc nat_ha_resync returns nat_ha_resync_reply events nat_ha_resync_completed_event;
466 };
467 
468 /*
469  * NAT44 APIs
470  */
471 
472 /** \brief Del NAT44 user
473  @param client_index - opaque cookie to identify the sender
474  @param context - sender context, to match reply w/ request
475  @param ip_address - IPv4 address
476  @param fib_index - FIB index
477 */
478 autoreply define nat44_del_user {
481  vl_api_ip4_address_t ip_address;
483 };
484 
485 /** \brief Add/del NAT44 address range
486  @param client_index - opaque cookie to identify the sender
487  @param context - sender context, to match reply w/ request
488  @param first_ip_address - first IPv4 address
489  @param last_ip_address - last IPv4 address
490  @param vrf_id - VRF id of tenant, ~0 means independent of VRF
491  @param is_add - true if add, false if delete
492  @param flags - flag NAT_IS_TWICE_NAT if NAT address range for external hosts
493 
494 */
495 autoreply define nat44_add_del_address_range {
498  vl_api_ip4_address_t first_ip_address;
499  vl_api_ip4_address_t last_ip_address;
501  bool is_add;
502  vl_api_nat_config_flags_t flags;
503 };
504 
505 /** \brief Dump NAT44 addresses
506  @param client_index - opaque cookie to identify the sender
507  @param context - sender context, to match reply w/ request
508 */
509 define nat44_address_dump {
512 };
513 
514 /** \brief NAT44 address details response
515  @param context - sender context, to match reply w/ request
516  @param ip_address - IPv4 address
517  @param flags - flag NAT_IS_TWICE_NAT if NAT address range for external hosts
518  @param vrf_id - VRF id of tenant, ~0 means independent of VRF
519 */
520 define nat44_address_details {
522  vl_api_ip4_address_t ip_address;
523  vl_api_nat_config_flags_t flags;
525 };
526 
527 /** \brief Enable/disable NAT44 feature on the interface
528  @param client_index - opaque cookie to identify the sender
529  @param context - sender context, to match reply w/ request
530  @param is_add - true if add, false if delete
531  @param flags - flag NAT_IS_INSIDE if interface is inside else
532  interface is outside
533  @param sw_if_index - software index of the interface
534 */
535 autoreply define nat44_interface_add_del_feature {
538  bool is_add;
539  vl_api_nat_config_flags_t flags;
540  vl_api_interface_index_t sw_if_index;
541 };
542 
543 /** \brief Dump interfaces with NAT44 feature
544  @param client_index - opaque cookie to identify the sender
545  @param context - sender context, to match reply w/ request
546 */
547 define nat44_interface_dump {
550 };
551 
552 /** \brief NAT44 interface details response
553  @param context - sender context, to match reply w/ request
554  @param sw_if_index - software index of the interface
555  @param flags - flag NAT_IS_INSIDE if interface is inside,
556  flag NAT_IS_OUTSIDE if interface is outside
557  and if both flags are set the interface is
558  both inside and outside
559 */
560 define nat44_interface_details {
562  vl_api_nat_config_flags_t flags;
563  vl_api_interface_index_t sw_if_index;
564 };
565 
566 /** \brief Enable/disbale NAT44 as an interface output feature (postrouting
567  in2out translation)
568  @param client_index - opaque cookie to identify the sender
569  @param context - sender context, to match reply w/ request
570  @param is_add - true if add, false if delete
571  @param flags - flag NAT_IS_INSIDE if interface is inside else
572  interface is outside
573  @param sw_if_index - software index of the interface
574 */
575 autoreply define nat44_interface_add_del_output_feature {
578  bool is_add;
579  vl_api_nat_config_flags_t flags;
580  vl_api_interface_index_t sw_if_index;
581 };
582 
583 /** \brief Dump interfaces with NAT44 output feature
584  @param client_index - opaque cookie to identify the sender
585  @param context - sender context, to match reply w/ request
586 */
587 define nat44_interface_output_feature_dump {
590 };
591 
592 /** \brief NAT44 interface with output feature details response
593  @param context - sender context, to match reply w/ request
594  @param flags - flag NAT_IS_INSIDE if interface is inside else
595  interface is outside
596  @param sw_if_index - software index of the interface
597 */
598 define nat44_interface_output_feature_details {
600  vl_api_nat_config_flags_t flags;
601  vl_api_interface_index_t sw_if_index;
602 };
603 
604 /** \brief Add/delete NAT44 static mapping
605  @param client_index - opaque cookie to identify the sender
606  @param context - sender context, to match reply w/ request
607  @param is_add - true if add, false if delete
608  @param flags - flag NAT_IS_ADDR_ONLY if address only mapping,
609  flag nat_is_twice_nat if nat address range for external hosts,
610  flag NAT_IS_SELF_TWICE_NAT if translate external host address
611  and port whenever external host address equals local
612  address of internal host,
613  flag NAT_IS_OUT2IN_ONLY if rule match only out2in direction
614  @param local_ip_address - local IPv4 address
615  @param external_ip_address - external IPv4 address
616  @param protocol - IP protocol, used only if addr_only=0
617  @param local_port - local port number, used only if addr_only=0
618  @param external_port - external port number, used only if addr_only=0
619  @param external_sw_if_index - external interface (if set
620  external_ip_address is ignored, ~0 means not
621  used)
622  @param vfr_id - VRF ID
623  @param tag - opaque string tag
624 */
625 autoreply define nat44_add_del_static_mapping {
628  bool is_add;
629  vl_api_nat_config_flags_t flags;
630  vl_api_ip4_address_t local_ip_address;
631  vl_api_ip4_address_t external_ip_address;
635  vl_api_interface_index_t external_sw_if_index;
637  string tag[64];
638 };
639 
640 /** \brief Dump NAT44 static mappings
641  @param client_index - opaque cookie to identify the sender
642  @param context - sender context, to match reply w/ request
643 */
644 define nat44_static_mapping_dump {
647 };
648 
649 /** \brief NAT44 static mapping details response
650  @param context - sender context, to match reply w/ request
651  @param flags - flag NAT_ADDR_ONLY if address only mapping,
652  flag NAT_TWICE_NAT if NAT address range for external hosts,
653  flag NAT_SELF_TWICE_NAT if translate external host address
654  and port whenever external host address equals local
655  address of internal host,
656  flag NAT_OUT2IN_ONLY if rule match only out2in direction
657  @param local_ip_address - local IPv4 address
658  @param external_ip_address - external IPv4 address
659  @param protocol - IP protocol, valid only if no NAT_ADDR_ONLY flag
660  @param local_port - local port number, valid only if no NAT_ADDR_ONLY flag
661  @param external_port - external port number, valid only if no NAT_ADDR_ONLY flag
662  @param external_sw_if_index - external interface
663  @param vfr_id - VRF ID
664  @param tag - opaque string tag
665 */
666 define nat44_static_mapping_details {
668  vl_api_nat_config_flags_t flags;
669  vl_api_ip4_address_t local_ip_address;
670  vl_api_ip4_address_t external_ip_address;
674  vl_api_interface_index_t external_sw_if_index;
676  string tag[64];
677 };
678 
679 /** \brief Add/delete NAT44 identity mapping
680  @param client_index - opaque cookie to identify the sender
681  @param context - sender context, to match reply w/ request
682  @param is_add - true if add, false if delete
683  @param flags - flag NAT_ADDR_ONLY if address only mapping
684  @param ip_address - IPv4 address
685  @param protocol - IP protocol
686  @param port - port number
687  @param sw_if_index - interface (if set ip_address is ignored, ~0 means not
688  used)
689  @param vfr_id - VRF ID (if ~0 use default VRF)
690  @param tag - opaque string tag
691 */
692 autoreply define nat44_add_del_identity_mapping {
695  bool is_add;
696  vl_api_nat_config_flags_t flags;
697  vl_api_ip4_address_t ip_address;
700  vl_api_interface_index_t sw_if_index;
702  string tag[64];
703 };
704 
705 /** \brief Dump NAT44 identity mappings
706  @param client_index - opaque cookie to identify the sender
707  @param context - sender context, to match reply w/ request
708 */
709 define nat44_identity_mapping_dump {
712 };
713 
714 /** \brief NAT44 identity mapping details response
715  @param context - sender context, to match reply w/ request
716  @param flags - flag NAT_ADDR_ONLY if address only mapping
717  @param ip_address - IPv4 address
718  @param protocol - IP protocol
719  @param port - port number
720  @param sw_if_index - interface
721  @param vfr_id - VRF ID
722  @param tag - opaque string tag
723 */
724 define nat44_identity_mapping_details {
726  vl_api_nat_config_flags_t flags;
727  vl_api_ip4_address_t ip_address;
730  vl_api_interface_index_t sw_if_index;
732  string tag[64];
733 };
734 
735 /** \brief Add/delete NAT44 pool address from specific interfce
736  @param client_index - opaque cookie to identify the sender
737  @param context - sender context, to match reply w/ request
738  @param is_add - true if add, false if delete
739  @param sw_if_index - software index of the interface
740  @param flags - flag NAT_TWICE_NAT if NAT address range for external hosts
741 */
742 autoreply define nat44_add_del_interface_addr {
745  bool is_add;
746  vl_api_interface_index_t sw_if_index;
747  vl_api_nat_config_flags_t flags;
748 };
749 
750 /** \brief Dump NAT44 pool addresses interfaces
751  @param client_index - opaque cookie to identify the sender
752  @param context - sender context, to match reply w/ request
753 */
754 define nat44_interface_addr_dump {
757 };
758 
759 /** \brief NAT44 pool addresses interfaces details response
760  @param context - sender context, to match reply w/ request
761  @param sw_if_index - software index of the interface
762  @param flags - flag NAT_TWICE_NAT if NAT address range for external hosts
763 
764 */
765 define nat44_interface_addr_details {
767  vl_api_interface_index_t sw_if_index;
768  vl_api_nat_config_flags_t flags;
769 };
770 
771 /** \brief Dump NAT44 users
772  @param client_index - opaque cookie to identify the sender
773  @param context - sender context, to match reply w/ request
774 */
775 define nat44_user_dump {
778 };
779 
780 /** \brief NAT44 users response
781  @param context - sender context, to match reply w/ request
782  @vrf_id - VRF ID
783  @param ip_address - IPv4 address
784  @param nsessions - number of dynamic sessions
785  @param nstaticsessions - number of static sessions
786 */
787 define nat44_user_details {
790  vl_api_ip4_address_t ip_address;
793 };
794 
795 /** \brief NAT44 user's sessions
796  @param client_index - opaque cookie to identify the sender
797  @param context - sender context, to match reply w/ request
798  @param ip_address - IPv4 address of the user to dump
799  @param vrf_id - VRF_ID
800 */
801 define nat44_user_session_dump {
804  vl_api_ip4_address_t ip_address;
806 };
807 
808 /** \brief NAT44 user's sessions response
809  @param context - sender context, to match reply w/ request
810  @param outside_ip_address - outside IPv4 address
811  @param outside_port - outside port
812  @param inside_ip_address - inside IPv4 address
813  @param inside_port - inside port
814  @param protocol - protocol
815  @param flags - flag NAT_IS_STATIC if session is static,
816  flag NAT_IS_TWICE_NAT if session is twice-nat,
817  flag NAT_IS_EXT_HOST_VALID if external host address
818  and port are valid
819  @param last_heard - last heard timer
820  @param total_bytes - count of bytes sent through session
821  @param total_pkts - count of pakets sent through session
822  @param ext_host_address - external host IPv4 address
823  @param ext_host_port - external host port
824  @param ext_host_nat_address - post-NAT external host IPv4 address (valid
825  only if twice-nat session)
826  @param ext_host_nat_port - post-NAT external host port (valid only if
827  twice-nat session)
828 */
829 define nat44_user_session_details {
831  vl_api_ip4_address_t outside_ip_address;
833  vl_api_ip4_address_t inside_ip_address;
836  vl_api_nat_config_flags_t flags;
840  vl_api_ip4_address_t ext_host_address;
842  vl_api_ip4_address_t ext_host_nat_address;
844 };
845 
846 /** \brief NAT44 load-balancing address and port pair
847  @param addr - IPv4 address of the internal node
848  @param port - L4 port number of the internal node
849  @param probability - probability of the internal node to be randomly matched
850  @param vrf_id - VRF id
851 */
853  vl_api_ip4_address_t addr;
857 };
858 
859 /** \brief Add/delete NAT44 load-balancing static mapping rule
860  @param client_index - opaque cookie to identify the sender
861  @param context - sender context, to match reply w/ request
862  @param is_add - true if add, false if delete
863  @param flags - flag NAT_TWICE_NAT if NAT address range for external hosts,
864  flag NAT_SELF_TWICE_NAT if translate external host address
865  and port whenever external host address equals local
866  address of internal host,
867  flag NAT_OUT2IN_ONLY if rule match only out2in direction
868  @param external_addr - external IPv4 address of the service
869  @param external_port - external L4 port number of the service
870  @param protocol - IP protocol number of the service
871  @param affinity - if 0 disabled, otherwise client IP affinity sticky time
872  in seconds
873  @param local_num - number of local network nodes
874  @param locals - local network nodes
875  @param tag - opaque string tag
876 */
877 autoreply manual_endian define nat44_add_del_lb_static_mapping {
880  bool is_add;
881  vl_api_nat_config_flags_t flags;
882  vl_api_ip4_address_t external_addr;
886  string tag[64];
888  vl_api_nat44_lb_addr_port_t locals[local_num];
889 };
890 
891 /** \brief Add/delete NAT44 load-balancing static mapping rule backend
892  @param client_index - opaque cookie to identify the sender
893  @param context - sender context, to match reply w/ request
894  @param is_add - true if add, false if delete
895  @param external_addr - external IPv4 address of the service
896  @param external_port - external L4 port number of the service
897  @param protocol - IP protocol number of the service
898  @param local - local network node
899 */
903  bool is_add;
904  vl_api_ip4_address_t external_addr;
907  vl_api_nat44_lb_addr_port_t local;
908 };
909 
910 /** \brief Dump NAT44 load-balancing static mapping rules
911  @param client_index - opaque cookie to identify the sender
912  @param context - sender context, to match reply w/ request
913 */
914 define nat44_lb_static_mapping_dump {
917 };
918 
919 /** \brief NAT44 load-balancing static mapping rule details response
920  @param context - sender context, to match reply w/ request
921  @param external_addr - external IPv4 address of the service
922  @param external_port - external L4 port number of the service
923  @param protocol - IP protocol number of the service
924  @param flags - flag NAT_TWICE_NAT if NAT address range for external hosts,
925  flag NAT_SELF_TWICE_NAT if translate external host address
926  and port whenever external host address equals local
927  address of internal host,
928  flag NAT_OUT2IN_ONLY if rule match only out2in direction
929  @param affinity - if 0 disabled, otherwise client IP affinity sticky time
930  in seconds
931  @param local_num - number of local network nodes
932  @param locals - local network nodes
933  @param tag - opaque string tag
934 */
935 manual_endian define nat44_lb_static_mapping_details {
937  vl_api_ip4_address_t external_addr;
940  vl_api_nat_config_flags_t flags;
942  string tag[64];
944  vl_api_nat44_lb_addr_port_t locals[local_num];
945 };
946 
947 /** \brief Delete NAT44 session
948  @param client_index - opaque cookie to identify the sender
949  @param context - sender context, to match reply w/ request
950  @param ip_address - IPv4 address
951  @param protocol - IP protocol
952  @param port - port number
953  @param vfr_id - VRF ID
954  @param flags - flag NAT_IS_INSIDE if interface is inside or
955  interface is outside,
956  flag NAT_IS_EXT_HOST_VALID if external host address and
957  port are valid
958  @param ext_host_address - external host IPv4 address
959  @param ext_host_port - external host port
960 */
961 autoreply define nat44_del_session {
964  vl_api_ip4_address_t address;
968  vl_api_nat_config_flags_t flags;
969  vl_api_ip4_address_t ext_host_address;
971 };
972 
973 /** \brief Enable/disable forwarding for NAT44
974  Forward packets which don't match existing translation
975  or static mapping instead of dropping them.
976  @param client_index - opaque cookie to identify the sender
977  @param context - sender context, to match reply w/ request
978  @param enable - true for enable, false for disable
979 */
980 autoreply define nat44_forwarding_enable_disable {
983  bool enable;
984 };
985 
986 /** \brief Check if forwarding is enabled or disabled
987  @param client_index - opaque cookie to identify the sender
988  @param context - sender context, to match reply w/ request
989 */
990 define nat44_forwarding_is_enabled {
993 };
994 
995 /** \brief Response to check if forwarding is enabled or disabled
996  @param context - sender context, to match reply w/ request
997  @param enabled - true if enabled, false if disabled
998 */
999 define nat44_forwarding_is_enabled_reply {
1001  bool enabled;
1002 };
1003 
1004 
1005 /*
1006  * Deterministic NAT (CGN) APIs
1007  */
1008 
1009 /** \brief Add/delete NAT deterministic mapping
1010  @param client_index - opaque cookie to identify the sender
1011  @param context - sender context, to match reply w/ request
1012  @param is_add - true if add, false if delete
1013  @param in_addr - inside IPv4 address
1014  @param in_plen - inside IPv4 address prefix length
1015  @param out_addr - outside IPv4 address
1016  @param out_plen - outside IPv4 address prefix length
1017 */
1018 autoreply define nat_det_add_del_map {
1021  bool is_add;
1022  vl_api_ip4_address_t in_addr;
1024  vl_api_ip4_address_t out_addr;
1026 };
1027 
1028 /** \brief Get outside address and port range from inside address
1029  @param client_index - opaque cookie to identify the sender
1030  @param context - sender context, to match reply w/ request
1031  @param in_addr - inside IP address
1032 */
1033 define nat_det_forward {
1036  vl_api_ip4_address_t in_addr;
1037 };
1038 
1039 /** \brief Get outside address and port range from inside address
1040  @param context - sender context, to match reply w/ request
1041  @param retval - return code
1042  @param out_port_lo - outside port range start
1043  @param out_port_hi - outside port range end
1044  @param out_addr - outside IPv4 address
1045 */
1046 define nat_det_forward_reply {
1051  vl_api_ip4_address_t out_addr;
1052 };
1053 
1054 /** \brief Get inside address from outside address and port
1055  @param client_index - opaque cookie to identify the sender
1056  @param context - sender context, to match reply w/ request
1057  @param out_port - outside port
1058  @param out_addr - outside IPv4 address
1059 */
1060 define nat_det_reverse {
1064  vl_api_ip4_address_t out_addr;
1065 };
1066 
1067 /** \brief Get inside address from outside address and port reply
1068  @param context - sender context, to match reply w/ request
1069  @param retval - return code
1070  @param in_addr - inside IP address
1071 */
1072 define nat_det_reverse_reply {
1075  vl_api_ip4_address_t in_addr;
1076 };
1077 
1078 /** \brief Dump NAT deterministic mappings
1079  @param client_index - opaque cookie to identify the sender
1080  @param context - sender context, to match reply w/ request
1081 */
1082 define nat_det_map_dump {
1085 };
1086 
1087 /** \brief NAT users response
1088  @param context - sender context, to match reply w/ request
1089  @param in_addr - inside IPv4 address
1090  @param in_plen - inside IPv4 address prefix length
1091  @param out_addr - outside IPv4 address
1092  @param out_plen - outside IPv4 address prefix length
1093  @param sharing_ratio - outside to inside address sharing ratio
1094  @param ports_per_host - number of ports available to a host
1095  @param ses_num - number of sessions belonging to this mapping
1096 */
1097 define nat_det_map_details {
1099  vl_api_ip4_address_t in_addr;
1101  vl_api_ip4_address_t out_addr;
1106 };
1107 
1108 /** \brief Close deterministic NAT session by outside address and port
1109  @param client_index - opaque cookie to identify the sender
1110  @param context - sender context, to match reply w/ request
1111  @param out_addr - outside IPv4 address
1112  @param out_port - outside port
1113  @param ext_addr - external host IPv4 address
1114  @param ext_port - external host port
1115 */
1116 autoreply define nat_det_close_session_out {
1119  vl_api_ip4_address_t out_addr;
1121  vl_api_ip4_address_t ext_addr;
1123 };
1124 
1125 /** \brief Close deterministic NAT session by inside address and port
1126  @param client_index - opaque cookie to identify the sender
1127  @param context - sender context, to match reply w/ request
1128  @param in_addr - inside IP address
1129  @param in_port - inside port
1130  @param ext_addr - external host IP address
1131  @param ext_port - external host port
1132 */
1133 autoreply define nat_det_close_session_in {
1136  vl_api_ip4_address_t in_addr;
1138  vl_api_ip4_address_t ext_addr;
1140 };
1141 
1142 /** \brief Dump determinstic NAT sessions
1143  @param client_index - opaque cookie to identify the sender
1144  @param context - sender context, to match reply w/ request
1145  @param user_addr - address of an inside user whose sessions to dump
1146 */
1147 define nat_det_session_dump {
1150  vl_api_ip4_address_t user_addr;
1151 };
1152 
1153 /** \brief Deterministic NAT sessions reply
1154  @param context - sender context, to match reply w/ request
1155  @param in_port - inside port
1156  @param ext_addr - external host IPv4 address
1157  @param ext_port - external host port
1158  @param out_port - outside NAT port
1159  @param state - session state
1160  @param expire - session expiration timestamp
1161 */
1162 define nat_det_session_details {
1165  vl_api_ip4_address_t ext_addr;
1170 };
1171 
1172 /*
1173  * NAT64 APIs
1174  */
1175 
1176 /** \brief Add/delete address range to NAT64 pool
1177  @param client_index - opaque cookie to identify the sender
1178  @param context - sender context, to match reply w/ request
1179  @param start_addr - start IPv4 address of the range
1180  @param end_addr - end IPv4 address of the range
1181  @param vrf_id - VRF id of tenant, ~0 means independent of VRF
1182  @param is_add - true if add, false if delete
1183 */
1184 autoreply define nat64_add_del_pool_addr_range {
1187  vl_api_ip4_address_t start_addr;
1188  vl_api_ip4_address_t end_addr;
1190  bool is_add;
1191 };
1192 
1193 /** \brief Dump NAT64 pool addresses
1194  @param client_index - opaque cookie to identify the sender
1195  @param context - sender context, to match reply w/ request
1196 */
1197 define nat64_pool_addr_dump {
1200 };
1201 
1202 /** \brief NAT64 pool address details response
1203  @param context - sender context, to match reply w/ request
1204  @param address - IPv4 address
1205  @param vfr_id - VRF id of tenant, ~0 means independent of VRF
1206 */
1207 define nat64_pool_addr_details {
1209  vl_api_ip4_address_t address;
1211 };
1212 
1213 /** \brief Enable/disable NAT64 feature on the interface
1214  @param client_index - opaque cookie to identify the sender
1215  @param context - sender context, to match reply w/ request
1216  @param is_add - true if add, false if delete
1217  @param flags - flag NAT_IS_INSIDE if interface is inside else
1218  interface is outside
1219  @param sw_if_index - index of the interface
1220 */
1221 autoreply define nat64_add_del_interface {
1224  bool is_add;
1225  vl_api_nat_config_flags_t flags;
1226  vl_api_interface_index_t sw_if_index;
1227 };
1228 
1229 /** \brief Dump interfaces with NAT64 feature
1230  @param client_index - opaque cookie to identify the sender
1231  @param context - sender context, to match reply w/ request
1232 */
1233 define nat64_interface_dump {
1236 };
1237 
1238 /** \brief NAT64 interface details response
1239  @param context - sender context, to match reply w/ request
1240  @param flags - flag NAT_IS_INSIDE if interface is inside,
1241  flag NAT_IS_OUTSIDE if interface is outside
1242  and if both flags are set the interface is
1243  both inside and outside
1244  @param sw_if_index - index of the interface
1245 */
1246 define nat64_interface_details {
1248  vl_api_nat_config_flags_t flags;
1249  vl_api_interface_index_t sw_if_index;
1250 };
1251 
1252 /** \brief Add/delete NAT64 static BIB entry
1253  @param client_index - opaque cookie to identify the sender
1254  @param context - sender context, to match reply w/ request
1255  @param i_addr - inside IPv6 address
1256  @param o_addr - outside IPv4 address
1257  @param i_port - inside port number
1258  @param o_port - outside port number
1259  @param vrf_id - VRF id of tenant
1260  @param proto - protocol number
1261  @param is_add - true if add, false if delete
1262 */
1263  autoreply define nat64_add_del_static_bib {
1266  vl_api_ip6_address_t i_addr;
1267  vl_api_ip4_address_t o_addr;
1272  bool is_add;
1273 };
1274 
1275 /** \brief Dump NAT64 BIB
1276  @param client_index - opaque cookie to identify the sender
1277  @param context - sender context, to match reply w/ request
1278  @param proto - protocol of the BIB: 255 - all BIBs
1279  6 - TCP BIB
1280  17 - UDP BIB
1281  1/58 - ICMP BIB
1282  otherwise - "unknown" protocol BIB
1283 */
1284 define nat64_bib_dump {
1288 };
1289 
1290 /** \brief NAT64 BIB details response
1291  @param context - sender context, to match reply w/ request
1292  @param i_addr - inside IPv6 address
1293  @param o_addr - outside IPv4 address
1294  @param i_port - inside port number
1295  @param o_port - outside port number
1296  @param vrf_id - VRF id of tenant
1297  @param proto - protocol number
1298  @param flags - flag NAT_IS_STATIC if BIB entry is static
1299  or BIB entry is dynamic
1300  @param ses_num - number of sessions associated with the BIB entry
1301 */
1302 define nat64_bib_details {
1304  vl_api_ip6_address_t i_addr;
1305  vl_api_ip4_address_t o_addr;
1310  vl_api_nat_config_flags_t flags;
1312 };
1313 
1314 /** \brief Dump NAT64 session table
1315  @param client_index - opaque cookie to identify the sender
1316  @param context - sender context, to match reply w/ request
1317  @param proto - protocol of the session table: 255 - all STs
1318  6 - TCP ST
1319  17 - UDP ST
1320  1/58 - ICMP ST
1321  otherwise - "unknown" proto ST
1322 */
1323 define nat64_st_dump {
1327 };
1328 
1329 /** \brief NAT64 session table details response
1330  @param context - sender context, to match reply w/ request
1331  @param il_addr - inside IPv6 address of the local host
1332  @param ol_addr - outside IPv4 address of the local host
1333  @param il_port - inside port number id of the local host/inside ICMP id
1334  @param ol_port - outside port number of the local host/outside ICMP id
1335  @param ir_addr - inside IPv6 address of the remote host
1336  @param or_addr - outside IPv4 address of the remote host
1337  @param r_port - port number of the remote host (not used for ICMP)
1338  @param vrf_id - VRF id of tenant
1339  @param proto - protocol number
1340 */
1341 define nat64_st_details {
1343  vl_api_ip6_address_t il_addr;
1344  vl_api_ip4_address_t ol_addr;
1347  vl_api_ip6_address_t ir_addr;
1348  vl_api_ip4_address_t or_addr;
1352 };
1353 
1354 /** \brief Add/del NAT64 prefix
1355  @param client_index - opaque cookie to identify the sender
1356  @param context - sender context, to match reply w/ request
1357  @param prefix - NAT64 prefix
1358  @param vrf_id - VRF id of tenant
1359  @param is_add - true if add, false if delete
1360 */
1361 autoreply define nat64_add_del_prefix {
1364  vl_api_ip6_prefix_t prefix;
1366  bool is_add;
1367 };
1368 
1369 /** \brief Dump NAT64 prefix
1370  @param client_index - opaque cookie to identify the sender
1371  @param context - sender context, to match reply w/ request
1372 */
1373 define nat64_prefix_dump {
1376 };
1377 
1378 /** \brief Dump NAT64 prefix details response
1379  @param context - sender context, to match reply w/ request
1380  @param prefix - NAT64 prefix
1381  @param vrf_id - VRF id of tenant
1382 */
1383 define nat64_prefix_details {
1385  vl_api_ip6_prefix_t prefix;
1387 };
1388 
1389 /** \brief Add/delete NAT64 pool address from specific interfce
1390  @param client_index - opaque cookie to identify the sender
1391  @param context - sender context, to match reply w/ request
1392  @param is_add - true if add, false if delete
1393  @param sw_if_index - software index of the interface
1394 */
1395 autoreply define nat64_add_del_interface_addr {
1398  bool is_add;
1399  vl_api_interface_index_t sw_if_index;
1400 };
1401 
1402 /*
1403  * NAT66 APIs
1404  */
1405 /** \brief Enable/disable NAT66 feature on the interface
1406  @param client_index - opaque cookie to identify the sender
1407  @param context - sender context, to match reply w/ request
1408  @param is_add - true if add, false if delete
1409  @param flags - flag NAT_IS_INSIDE if interface is inside or
1410  interface is outside,
1411  @param sw_if_index - software index of the interface
1412 */
1413 autoreply define nat66_add_del_interface {
1416  bool is_add;
1417  vl_api_nat_config_flags_t flags;
1418  vl_api_interface_index_t sw_if_index;
1419 };
1420 
1421 /** \brief Dump interfaces with NAT66 feature
1422  @param client_index - opaque cookie to identify the sender
1423  @param context - sender context, to match reply w/ request
1424 */
1425 define nat66_interface_dump {
1428 };
1429 
1430 /** \brief NAT66 interface details response
1431  @param context - sender context, to match reply w/ request
1432  @param flags - flag NAT_IS_INSIDE if interface is inside or
1433  interface is outside,
1434  @param sw_if_index - software index of the interface
1435 */
1436 define nat66_interface_details {
1438  vl_api_nat_config_flags_t flags;
1439  vl_api_interface_index_t sw_if_index;
1440 };
1441 
1442 /** \brief Add/delete 1:1 NAT66
1443  @param client_index - opaque cookie to identify the sender
1444  @param context - sender context, to match reply w/ request
1445  @param is_add - true if add, false if delete
1446  @param local_ip_address - local IPv6 address
1447  @param external_ip_address - external IPv6 address
1448  @param vrf_id - VRF id of tenant
1449 */
1450 autoreply define nat66_add_del_static_mapping {
1453  bool is_add;
1454  vl_api_ip6_address_t local_ip_address;
1455  vl_api_ip6_address_t external_ip_address;
1457 };
1458 
1459 /** \brief Dump NAT66 static mappings
1460  @param client_index - opaque cookie to identify the sender
1461  @param context - sender context, to match reply w/ request
1462 */
1463 define nat66_static_mapping_dump {
1466 };
1467 
1468 /** \brief NAT66 static mapping details response
1469  @param context - sender context, to match reply w/ request
1470  @param local_ip_address - local IPv6 address
1471  @param external_ip_address - external IPv6 address
1472  @param vrf_id - VRF id of tenant
1473  @param total_bytes - count of bytes sent through static mapping
1474  @param total_pkts - count of pakets sent through static mapping
1475 */
1476 define nat66_static_mapping_details {
1478  vl_api_ip6_address_t local_ip_address;
1479  vl_api_ip6_address_t external_ip_address;
1483 };
vl_api_ip4_address_t ext_host_address
Definition: nat.api:840
vl_api_ip4_address_t ext_addr
Definition: nat.api:1138
vl_api_interface_index_t sw_if_index
Definition: nat.api:746
vl_api_ip4_address_t out_addr
Definition: nat.api:1051
vl_api_nat_config_flags_t flags
Definition: nat.api:1438
vl_api_ip4_address_t external_addr
Definition: nat.api:937
int nat44_del_session(snat_main_t *sm, ip4_address_t *addr, u16 port, nat_protocol_t proto, u32 vrf_id, int is_in)
Delete NAT44 session.
Definition: nat.c:4392
vl_api_interface_index_t external_sw_if_index
Definition: nat.api:635
vl_api_interface_index_t sw_if_index
Definition: nat.api:540
vl_api_ip4_address_t external_addr
Definition: nat.api:882
vl_api_ip4_address_t out_addr
Definition: nat.api:1024
unsigned long u64
Definition: types.h:89
int nat64_add_del_interface(u32 sw_if_index, u8 is_inside, u8 is_add)
Enable/disable NAT64 feature on the interface.
Definition: nat64.c:414
vl_api_nat_config_flags_t flags
Definition: nat.api:696
vl_api_nat_config_flags_t flags
Definition: nat.api:1310
vl_api_nat_config_flags_t flags
Definition: nat.api:562
vl_api_ip6_address_t external_ip_address
Definition: nat.api:1479
vl_api_ip4_address_t local_ip_address
Definition: nat.api:630
vl_api_ip4_address_t ip_address
Definition: nat.api:422
vl_api_ip6_prefix_t prefix
Definition: nat.api:1385
vl_api_nat_config_flags_t flags
Definition: nat.api:539
vl_api_ip4_address_t first_ip_address
Definition: nat.api:498
vl_api_ip4_address_t or_addr
Definition: nat.api:1348
vl_api_ip4_address_t ip_address
Definition: nat.api:727
vhost_vring_addr_t addr
Definition: vhost_user.h:254
vl_api_nat_config_flags_t flags
Definition: nat.api:768
unsigned char u8
Definition: types.h:56
vl_api_ip4_address_t out_addr
Definition: nat.api:1064
nat_log_level
Definition: nat.api:123
vl_api_interface_index_t sw_if_index
Definition: nat.api:1399
vl_api_nat_config_flags_t flags
Definition: nat.api:1225
vl_api_ip6_address_t ir_addr
Definition: nat.api:1347
int nat_ha_resync(u32 client_index, u32 pid, nat_ha_resync_event_cb_t event_callback)
Resync HA (resend existing sessions to new failover)
vl_api_ip4_address_t o_addr
Definition: nat.api:1267
vl_api_nat_config_flags_t flags
Definition: nat.api:726
u8 probability
Definition: nat.api:855
vl_api_ip6_address_t i_addr
Definition: nat.api:1266
nat_config_flags
Definition: nat.api:32
option version
Definition: nat.api:16
unsigned int u32
Definition: types.h:88
vl_api_ip4_address_t ip_address
Definition: nat.api:804
vl_api_ip6_address_t local_ip_address
Definition: nat.api:1454
vl_api_ip4_address_t ext_addr
Definition: nat.api:1165
vl_api_nat_config_flags_t flags
Definition: nat.api:968
vl_api_nat_config_flags_t flags
Definition: nat.api:836
int nat44_set_session_limit(u32 session_limit, u32 vrf_id)
Set NAT44 session limit (session limit, vrf id)
Definition: nat.c:333
vl_api_nat_config_flags_t flags
Definition: nat.api:502
service
Definition: nat.api:464
vl_api_nat_config_flags_t flags
Definition: nat.api:881
vl_api_nat_config_flags_t flags
Definition: nat.api:668
vl_api_nat_config_flags_t flags
Definition: nat.api:940
unsigned short u16
Definition: types.h:57
vl_api_ip4_address_t external_ip_address
Definition: nat.api:670
void nat_ha_get_listener(ip4_address_t *addr, u16 *port, u32 *path_mtu)
Get HA listener/local configuration.
Definition: nat_ha.c:385
void nat_ha_flush(u8 is_resync)
Flush the current HA data (for testing)
Definition: nat_ha.c:682
vl_api_ip6_address_t i_addr
Definition: nat.api:1304
vl_api_ip4_address_t ext_host_nat_address
Definition: nat.api:842
vl_api_ip4_address_t outside_ip_address
Definition: nat.api:831
vl_api_ip4_address_t address
Definition: nat.api:964
vl_api_ip4_address_t ip_address
Definition: nat.api:481
vl_api_ip4_address_t in_addr
Definition: nat.api:1136
vl_api_ip6_address_t il_addr
Definition: nat.api:1343
vl_api_ip6_address_t external_ip_address
Definition: nat.api:1455
vl_api_ip4_address_t last_ip_address
Definition: nat.api:499
vl_api_interface_index_t sw_if_index
Definition: nat.api:1249
vl_api_ip4_address_t ip_address
Definition: nat.api:522
vl_api_ip4_address_t ext_addr
Definition: nat.api:1121
vl_api_interface_index_t sw_if_index
Definition: nat.api:1418
vl_api_ip4_address_t ip_address
Definition: nat.api:357
int nat64_add_del_prefix(ip6_address_t *prefix, u8 plen, u32 vrf_id, u8 is_add)
Add/delete NAT64 prefix.
Definition: nat64.c:974
u16 port
Definition: nat.api:854
vl_api_ip4_address_t out_addr
Definition: nat.api:1119
vl_api_ip4_address_t ol_addr
Definition: nat.api:1344
vl_api_nat_config_flags_t flags
Definition: nat.api:747
vl_api_nat_config_flags_t flags
Definition: nat.api:1417
vl_api_ip4_address_t ext_host_address
Definition: nat.api:969
string name[64]
Definition: ip.api:44
vl_api_ip4_address_t in_addr
Definition: nat.api:1036
int nat_ha_set_listener(ip4_address_t *addr, u16 port, u32 path_mtu)
Set HA listener (local settings)
Definition: nat_ha.c:352
signed int i32
Definition: types.h:77
int nat_ha_set_failover(ip4_address_t *addr, u16 port, u32 session_refresh_interval)
Set HA failover (remote settings)
Definition: nat_ha.c:395
vl_api_ip4_address_t in_addr
Definition: nat.api:1099
typedef nat44_lb_addr_port
NAT44 load-balancing address and port pair.
Definition: nat.api:852
vl_api_ip4_address_t o_addr
Definition: nat.api:1305
vl_api_nat_config_flags_t flags
Definition: nat.api:629
vl_api_interface_index_t sw_if_index
Definition: nat.api:730
int nat44_lb_static_mapping_add_del_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)
Definition: nat.c:1578
vl_api_ip4_address_t start_addr
Definition: nat.api:1187
vl_api_interface_index_t external_sw_if_index
Definition: nat.api:674
vl_api_interface_index_t sw_if_index
Definition: nat.api:563
vl_api_interface_index_t sw_if_index
Definition: nat.api:1226
vl_api_interface_index_t sw_if_index
Definition: nat.api:1439
vl_api_ip4_address_t ip_address
Definition: nat.api:697
vl_api_interface_index_t sw_if_index
Definition: nat.api:767
vl_api_ip4_address_t ip_address
Definition: nat.api:790
vl_api_ip4_address_t end_addr
Definition: nat.api:1188
void nat_ha_get_failover(ip4_address_t *addr, u16 *port, u32 *session_refresh_interval)
Get HA failover/remote settings.
Definition: nat_ha.c:410
vl_api_ip4_address_t ip_address
Definition: nat.api:373
vl_api_interface_index_t sw_if_index
Definition: nat.api:700
vl_api_ip4_address_t external_ip_address
Definition: nat.api:631
vl_api_ip4_address_t inside_ip_address
Definition: nat.api:833
vl_api_ip6_prefix_t prefix
Definition: nat.api:1364
vl_api_ip4_address_t address
Definition: nat.api:1209
int nat44_add_del_lb_static_mapping(ip4_address_t e_addr, u16 e_port, nat_protocol_t proto, nat44_lb_addr_port_t *locals, u8 is_add, twice_nat_type_t twice_nat, u8 out2in_only, u8 *tag, u32 affinity)
Add/delete static mapping with load-balancing (multiple backends)
Definition: nat.c:1325
vl_api_nat_config_flags_t flags
Definition: nat.api:523
u32 vrf_id
Definition: nat.api:856
vl_api_ip4_address_t local_ip_address
Definition: nat.api:669
vl_api_ip4_address_t user_addr
Definition: nat.api:1150
vl_api_ip4_address_t in_addr
Definition: nat.api:1075
vl_api_nat_log_level_t log_level
Definition: nat.api:163
vl_api_interface_index_t sw_if_index
Definition: nat.api:601
vl_api_interface_index_t sw_if_index
Definition: nat.api:580
vl_api_ip4_address_t in_addr
Definition: nat.api:1022
vl_api_ip4_address_t out_addr
Definition: nat.api:1101
vl_api_nat44_lb_addr_port_t local
Definition: nat.api:907
vl_api_ip6_address_t local_ip_address
Definition: nat.api:1478
vl_api_nat_config_flags_t flags
Definition: nat.api:1248
vl_api_ip4_address_t ip_address
Definition: nat.api:397