1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
5 #include <linux/types.h>
6 #include <linux/netfilter/ipset/ip_set.h>
8 /* Revision 0 interface: backward compatible with netfilter/iptables */
11 * Option flags for kernel operations (xt_set_info_v0)
13 #define IPSET_SRC 0x01 /* Source match/add */
14 #define IPSET_DST 0x02 /* Destination match/add */
15 #define IPSET_MATCH_INV 0x04 /* Inverse matching */
17 struct xt_set_info_v0 {
20 __u32 flags[IPSET_DIM_MAX + 1];
22 __u32 __flags[IPSET_DIM_MAX];
29 /* match and target infos */
30 struct xt_set_info_match_v0 {
31 struct xt_set_info_v0 match_set;
34 struct xt_set_info_target_v0 {
35 struct xt_set_info_v0 add_set;
36 struct xt_set_info_v0 del_set;
39 /* Revision 1 match and target */
47 /* match and target infos */
48 struct xt_set_info_match_v1 {
49 struct xt_set_info match_set;
52 struct xt_set_info_target_v1 {
53 struct xt_set_info add_set;
54 struct xt_set_info del_set;
57 /* Revision 2 target */
59 struct xt_set_info_target_v2 {
60 struct xt_set_info add_set;
61 struct xt_set_info del_set;
66 /* Revision 3 match */
68 struct xt_set_info_match_v3 {
69 struct xt_set_info match_set;
70 struct ip_set_counter_match0 packets;
71 struct ip_set_counter_match0 bytes;
75 /* Revision 3 target */
77 struct xt_set_info_target_v3 {
78 struct xt_set_info add_set;
79 struct xt_set_info del_set;
80 struct xt_set_info map_set;
85 /* Revision 4 match */
87 struct xt_set_info_match_v4 {
88 struct xt_set_info match_set;
89 struct ip_set_counter_match packets;
90 struct ip_set_counter_match bytes;