2 * Copyright (c) 2020 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:
7 * http://www.apache.org/licenses/LICENSE-2.0
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.
16 option version = "1.0.0";
17 import "vnet/ip/ip_types.api";
18 import "vnet/interface_types.api";
19 import "plugins/nat/lib/nat_types.api";
21 /** \brief Enable/disable NAT66 feature on the interface
22 @param client_index - opaque cookie to identify the sender
23 @param context - sender context, to match reply w/ request
24 @param is_add - true if add, false if delete
25 @param flags - flag NAT_IS_INSIDE if interface is inside or
27 @param sw_if_index - software index of the interface
29 autoreply define nat66_add_del_interface {
33 vl_api_nat_config_flags_t flags;
34 vl_api_interface_index_t sw_if_index;
37 /** \brief Dump interfaces with NAT66 feature
38 @param client_index - opaque cookie to identify the sender
39 @param context - sender context, to match reply w/ request
41 define nat66_interface_dump {
46 /** \brief NAT66 interface details response
47 @param context - sender context, to match reply w/ request
48 @param flags - flag NAT_IS_INSIDE if interface is inside or
50 @param sw_if_index - software index of the interface
52 define nat66_interface_details {
54 vl_api_nat_config_flags_t flags;
55 vl_api_interface_index_t sw_if_index;
58 /** \brief Add/delete 1:1 NAT66
59 @param client_index - opaque cookie to identify the sender
60 @param context - sender context, to match reply w/ request
61 @param is_add - true if add, false if delete
62 @param local_ip_address - local IPv6 address
63 @param external_ip_address - external IPv6 address
64 @param vrf_id - VRF id of tenant
66 autoreply define nat66_add_del_static_mapping {
70 vl_api_ip6_address_t local_ip_address;
71 vl_api_ip6_address_t external_ip_address;
75 /** \brief Dump NAT66 static mappings
76 @param client_index - opaque cookie to identify the sender
77 @param context - sender context, to match reply w/ request
79 define nat66_static_mapping_dump {
84 /** \brief NAT66 static mapping details response
85 @param context - sender context, to match reply w/ request
86 @param local_ip_address - local IPv6 address
87 @param external_ip_address - external IPv6 address
88 @param vrf_id - VRF id of tenant
89 @param total_bytes - count of bytes sent through static mapping
90 @param total_pkts - count of pakets sent through static mapping
92 define nat66_static_mapping_details {
94 vl_api_ip6_address_t local_ip_address;
95 vl_api_ip6_address_t external_ip_address;