linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git] / include / linux / netfilter_ipv4 / ipt_multiport.h
index 55fe85e..e6b6fff 100644 (file)
@@ -1,15 +1,30 @@
 #ifndef _IPT_MULTIPORT_H
 #define _IPT_MULTIPORT_H
+#include <linux/netfilter_ipv4/ip_tables.h>
 
-#include <linux/netfilter/xt_multiport.h>
+enum ipt_multiport_flags
+{
+       IPT_MULTIPORT_SOURCE,
+       IPT_MULTIPORT_DESTINATION,
+       IPT_MULTIPORT_EITHER
+};
 
-#define IPT_MULTIPORT_SOURCE           XT_MULTIPORT_SOURCE
-#define IPT_MULTIPORT_DESTINATION      XT_MULTIPORT_DESTINATION
-#define IPT_MULTIPORT_EITHER           XT_MULTIPORT_EITHER
+#define IPT_MULTI_PORTS        15
 
-#define IPT_MULTI_PORTS                        XT_MULTI_PORTS
-
-#define ipt_multiport                  xt_multiport
-#define ipt_multiport_v1               xt_multiport_v1
+/* Must fit inside union ipt_matchinfo: 16 bytes */
+struct ipt_multiport
+{
+       u_int8_t flags;                         /* Type of comparison */
+       u_int8_t count;                         /* Number of ports */
+       u_int16_t ports[IPT_MULTI_PORTS];       /* Ports */
+};
 
+struct ipt_multiport_v1
+{
+       u_int8_t flags;                         /* Type of comparison */
+       u_int8_t count;                         /* Number of ports */
+       u_int16_t ports[IPT_MULTI_PORTS];       /* Ports */
+       u_int8_t pflags[IPT_MULTI_PORTS];       /* Port flags */
+       u_int8_t invert;                        /* Invert flag */
+};
 #endif /*_IPT_MULTIPORT_H*/