diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/ip6tables.h | 8 | ||||
-rw-r--r-- | include/iptables.h | 10 | ||||
-rw-r--r-- | include/linux/netfilter/xt_set.h | 20 | ||||
-rw-r--r-- | include/xtables.h.in | 2 |
4 files changed, 28 insertions, 12 deletions
diff --git a/include/ip6tables.h b/include/ip6tables.h index ca0f9a05..e976361f 100644 --- a/include/ip6tables.h +++ b/include/ip6tables.h @@ -10,10 +10,10 @@ extern int do_command6(int argc, char *argv[], char **table, struct ip6tc_handle **handle); -extern int for_each_chain(int (*fn)(const ip6t_chainlabel, int, struct ip6tc_handle *), int verbose, int builtinstoo, struct ip6tc_handle *handle); -extern int flush_entries(const ip6t_chainlabel chain, int verbose, struct ip6tc_handle *handle); -extern int delete_chain(const ip6t_chainlabel chain, int verbose, struct ip6tc_handle *handle); -void print_rule(const struct ip6t_entry *e, struct ip6tc_handle *h, const char *chain, int counters); +extern int for_each_chain6(int (*fn)(const ip6t_chainlabel, int, struct ip6tc_handle *), int verbose, int builtinstoo, struct ip6tc_handle *handle); +extern int flush_entries6(const ip6t_chainlabel chain, int verbose, struct ip6tc_handle *handle); +extern int delete_chain6(const ip6t_chainlabel chain, int verbose, struct ip6tc_handle *handle); +void print_rule6(const struct ip6t_entry *e, struct ip6tc_handle *h, const char *chain, int counters); extern struct xtables_globals ip6tables_globals; diff --git a/include/iptables.h b/include/iptables.h index 84211c32..65b32909 100644 --- a/include/iptables.h +++ b/include/iptables.h @@ -7,15 +7,15 @@ #include <iptables/internal.h> /* Your shared library should call one of these. */ -extern int do_command(int argc, char *argv[], char **table, +extern int do_command4(int argc, char *argv[], char **table, struct iptc_handle **handle); -extern int delete_chain(const ipt_chainlabel chain, int verbose, +extern int delete_chain4(const ipt_chainlabel chain, int verbose, struct iptc_handle *handle); -extern int flush_entries(const ipt_chainlabel chain, int verbose, +extern int flush_entries4(const ipt_chainlabel chain, int verbose, struct iptc_handle *handle); -extern int for_each_chain(int (*fn)(const ipt_chainlabel, int, struct iptc_handle *), +extern int for_each_chain4(int (*fn)(const ipt_chainlabel, int, struct iptc_handle *), int verbose, int builtinstoo, struct iptc_handle *handle); -extern void print_rule(const struct ipt_entry *e, +extern void print_rule4(const struct ipt_entry *e, struct iptc_handle *handle, const char *chain, int counters); /* kernel revision handling */ diff --git a/include/linux/netfilter/xt_set.h b/include/linux/netfilter/xt_set.h index 3ad31378..4379ce9f 100644 --- a/include/linux/netfilter/xt_set.h +++ b/include/linux/netfilter/xt_set.h @@ -89,7 +89,7 @@ struct xt_set_info_target_v0 { struct xt_set_info_v0 del_set; }; -/* Revision 1: current interface to netfilter/iptables */ +/* Revision 1 match and target */ struct xt_set_info { ip_set_id_t index; @@ -98,13 +98,27 @@ struct xt_set_info { }; /* match and target infos */ -struct xt_set_info_match { +struct xt_set_info_match_v1 { struct xt_set_info match_set; }; -struct xt_set_info_target { +struct xt_set_info_target_v1 { struct xt_set_info add_set; struct xt_set_info del_set; }; +/* Revision 2 target */ + +enum ipset_cmd_flags { + IPSET_FLAG_BIT_EXIST = 0, + IPSET_FLAG_EXIST = (1 << IPSET_FLAG_BIT_EXIST), +}; + +struct xt_set_info_target_v2 { + struct xt_set_info add_set; + struct xt_set_info del_set; + u_int32_t flags; + u_int32_t timeout; +}; + #endif /*_XT_SET_H*/ diff --git a/include/xtables.h.in b/include/xtables.h.in index 0cd9f9f8..5563ecb9 100644 --- a/include/xtables.h.in +++ b/include/xtables.h.in @@ -432,6 +432,8 @@ extern void xtables_save_string(const char *value); # define _init _INIT # endif extern void init_extensions(void); + extern void init_extensions4(void); + extern void init_extensions6(void); #else # define _init __attribute__((constructor)) _INIT #endif |