Rusty Russell | 79dee07 | 2000-05-02 16:45:16 +0000 | [diff] [blame] | 1 | #ifndef _IP6TABLES_USER_H |
| 2 | #define _IP6TABLES_USER_H |
| 3 | |
Yasuyuki KOZAKAI | 0d502bc | 2007-07-24 05:52:07 +0000 | [diff] [blame^] | 4 | #include <xtables.h> |
| 5 | |
Rusty Russell | 79dee07 | 2000-05-02 16:45:16 +0000 | [diff] [blame] | 6 | #include "iptables_common.h" |
| 7 | #include "libiptc/libip6tc.h" |
| 8 | |
Martin Josefsson | 357d59d | 2004-12-27 19:49:28 +0000 | [diff] [blame] | 9 | #ifndef IP6T_LIB_DIR |
| 10 | #define IP6T_LIB_DIR "/usr/local/lib/iptables" |
| 11 | #endif |
| 12 | |
Patrick McHardy | 2452baf | 2006-04-28 08:10:08 +0000 | [diff] [blame] | 13 | #ifndef IPPROTO_SCTP |
| 14 | #define IPPROTO_SCTP 132 |
| 15 | #endif |
| 16 | #ifndef IPPROTO_DCCP |
| 17 | #define IPPROTO_DCCP 33 |
| 18 | #endif |
Patrick McHardy | 9561606 | 2007-01-11 09:08:22 +0000 | [diff] [blame] | 19 | #ifndef IPPROTO_UDPLITE |
| 20 | #define IPPROTO_UDPLITE 136 |
| 21 | #endif |
Patrick McHardy | 2452baf | 2006-04-28 08:10:08 +0000 | [diff] [blame] | 22 | |
Rémi Denis-Courmont | 0665217 | 2006-10-20 12:24:34 +0000 | [diff] [blame] | 23 | #ifndef IP6T_SO_GET_REVISION_MATCH /* Old kernel source. */ |
Yasuyuki KOZAKAI | 4ebfad0 | 2006-11-13 04:03:26 +0000 | [diff] [blame] | 24 | #define IP6T_SO_GET_REVISION_MATCH 68 |
| 25 | #define IP6T_SO_GET_REVISION_TARGET 69 |
Rémi Denis-Courmont | 0665217 | 2006-10-20 12:24:34 +0000 | [diff] [blame] | 26 | #endif /* IP6T_SO_GET_REVISION_MATCH Old kernel source */ |
| 27 | |
Yasuyuki KOZAKAI | 0d502bc | 2007-07-24 05:52:07 +0000 | [diff] [blame^] | 28 | #define ip6tables_rule_match xtables_rule_match |
| 29 | #define ip6tables_match xtables_match |
| 30 | #define ip6tables_target xtables_target |
| 31 | #define ip6t_tryload xt_tryload |
Rusty Russell | 79dee07 | 2000-05-02 16:45:16 +0000 | [diff] [blame] | 32 | |
Harald Welte | a8658ca | 2003-03-05 07:46:15 +0000 | [diff] [blame] | 33 | extern int line; |
| 34 | |
Rusty Russell | 79dee07 | 2000-05-02 16:45:16 +0000 | [diff] [blame] | 35 | /* Your shared library should call one of these. */ |
| 36 | extern void register_match6(struct ip6tables_match *me); |
| 37 | extern void register_target6(struct ip6tables_target *me); |
| 38 | |
Phil Oester | 58179b1 | 2006-07-20 17:00:19 +0000 | [diff] [blame] | 39 | extern int service_to_port(const char *name, const char *proto); |
Phil Oester | dbac8ad | 2006-07-20 17:01:54 +0000 | [diff] [blame] | 40 | extern u_int16_t parse_port(const char *port, const char *proto); |
Rusty Russell | 79dee07 | 2000-05-02 16:45:16 +0000 | [diff] [blame] | 41 | extern int do_command6(int argc, char *argv[], char **table, |
| 42 | ip6tc_handle_t *handle); |
Yasuyuki KOZAKAI | 9867e81 | 2005-06-22 12:24:21 +0000 | [diff] [blame] | 43 | extern void parse_interface(const char *arg, char *vianame, unsigned char *mask); |
| 44 | |
András Kis-Szabó | 764316a | 2001-02-26 17:31:20 +0000 | [diff] [blame] | 45 | extern int for_each_chain(int (*fn)(const ip6t_chainlabel, int, ip6tc_handle_t *), int verbose, int builtinstoo, ip6tc_handle_t *handle); |
| 46 | extern int flush_entries(const ip6t_chainlabel chain, int verbose, ip6tc_handle_t *handle); |
| 47 | extern int delete_chain(const ip6t_chainlabel chain, int verbose, ip6tc_handle_t *handle); |
| 48 | |
Rusty Russell | 79dee07 | 2000-05-02 16:45:16 +0000 | [diff] [blame] | 49 | #endif /*_IP6TABLES_USER_H*/ |