FD.io VPP  v21.01.1
Vector Packet Processing
udp_local.h
Go to the documentation of this file.
1 /*
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:
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 #ifndef SRC_VNET_UDP_UDP_LOCAL_H_
17 #define SRC_VNET_UDP_UDP_LOCAL_H_
18 
19 #include <vnet/vnet.h>
20 
21 #define foreach_udp4_dst_port \
22 _ (53, dns) \
23 _ (67, dhcp_to_server) \
24 _ (68, dhcp_to_client) \
25 _ (500, ikev2) \
26 _ (2152, GTPU) \
27 _ (3784, bfd4) \
28 _ (3785, bfd_echo4) \
29 _ (4341, lisp_gpe) \
30 _ (4342, lisp_cp) \
31 _ (4500, ipsec) \
32 _ (4739, ipfix) \
33 _ (4789, vxlan) \
34 _ (4789, vxlan6) \
35 _ (48879, vxlan_gbp) \
36 _ (4790, VXLAN_GPE) \
37 _ (6633, vpath_3) \
38 _ (6081, geneve) \
39 _ (53053, dns_reply)
40 
41 
42 #define foreach_udp6_dst_port \
43 _ (53, dns6) \
44 _ (547, dhcpv6_to_server) \
45 _ (546, dhcpv6_to_client) \
46 _ (2152, GTPU6) \
47 _ (3784, bfd6) \
48 _ (3785, bfd_echo6) \
49 _ (4341, lisp_gpe6) \
50 _ (4342, lisp_cp6) \
51 _ (48879, vxlan6_gbp) \
52 _ (4790, VXLAN6_GPE) \
53 _ (6633, vpath6_3) \
54 _ (6081, geneve6) \
55 _ (8138, BIER) \
56 _ (53053, dns_reply6)
57 
58 typedef enum
59 {
60 #define _(n,f) UDP_DST_PORT_##f = n,
62 #undef _
64 
65 typedef enum
66 {
67 #define _(n,f) UDP6_DST_PORT_##f = n,
69 #undef _
71 
74  u32 node_index, u8 is_ip4);
76  udp_dst_port_t dst_port, u8 is_ip4);
78 
79 #endif /* SRC_VNET_UDP_UDP_LOCAL_H_ */
80 
81 /*
82  * fd.io coding-style-patch-verification: ON
83  *
84  * Local Variables:
85  * eval: (c-set-style "gnu")
86  * End:
87  */
u8 udp_is_valid_dst_port(udp_dst_port_t dst_port, u8 is_ip4)
Definition: udp_local.c:529
vl_api_ip_port_and_mask_t dst_port
Definition: flow_types.api:92
unsigned char u8
Definition: types.h:56
#define foreach_udp4_dst_port
Definition: udp_local.h:21
unsigned int u32
Definition: types.h:88
udp_dst_port_t
Definition: udp_local.h:58
void udp_unregister_dst_port(vlib_main_t *vm, udp_dst_port_t dst_port, u8 is_ip4)
Definition: udp_local.c:506
udp6_dst_port_t
Definition: udp_local.h:65
#define foreach_udp6_dst_port
Definition: udp_local.h:42
void udp_register_dst_port(vlib_main_t *vm, udp_dst_port_t dst_port, u32 node_index, u8 is_ip4)
Definition: udp_local.c:468