[netfilter-cvslog] r7021 - in trunk/iptables: extensions include/linux/netfilter

kaber at trash.net kaber at trash.net
Wed Sep 5 15:47:05 CEST 2007


Author: kaber at trash.net
Date: 2007-09-05 15:47:05 +0200 (Wed, 05 Sep 2007)
New Revision: 7021

Added:
   trunk/iptables/include/linux/netfilter/xt_statistic.h
Removed:
   trunk/iptables/extensions/.statistic-testx
Modified:
   trunk/iptables/extensions/Makefile
Log:
Build statistic match unconditionally


Deleted: trunk/iptables/extensions/.statistic-testx
===================================================================
--- trunk/iptables/extensions/.statistic-testx	2007-09-05 13:46:02 UTC (rev 7020)
+++ trunk/iptables/extensions/.statistic-testx	2007-09-05 13:47:05 UTC (rev 7021)
@@ -1,2 +0,0 @@
-#!/bin/sh
-[ -f $KERNEL_DIR/net/netfilter/xt_statistic.c -a -f $KERNEL_DIR/include/linux/netfilter/xt_statistic.h ] && echo statistic

Modified: trunk/iptables/extensions/Makefile
===================================================================
--- trunk/iptables/extensions/Makefile	2007-09-05 13:46:02 UTC (rev 7020)
+++ trunk/iptables/extensions/Makefile	2007-09-05 13:47:05 UTC (rev 7021)
@@ -7,7 +7,7 @@
 #
 PF_EXT_SLIB:=ah addrtype conntrack ecn icmp iprange owner policy realm tos ttl unclean DNAT ECN LOG MASQUERADE MIRROR NETMAP REDIRECT REJECT SAME SNAT TOS TTL ULOG
 PF6_EXT_SLIB:=eui64 hl icmp6 owner policy HL LOG
-PFX_EXT_SLIB:=connbytes connmark connlimit comment dscp esp hashlimit helper length limit mac mark multiport physdev pkttype quota sctp state standard tcp tcpmss udp CLASSIFY CONNMARK DSCP MARK NFLOG NFQUEUE NOTRACK TCPMSS TRACE
+PFX_EXT_SLIB:=connbytes connmark connlimit comment dscp esp hashlimit helper length limit mac mark multiport physdev pkttype quota sctp state statistic standard tcp tcpmss udp CLASSIFY CONNMARK DSCP MARK NFLOG NFQUEUE NOTRACK TCPMSS TRACE
 
 ifeq ($(DO_SELINUX), 1)
 PF_EXT_SE_SLIB:=

Added: trunk/iptables/include/linux/netfilter/xt_statistic.h
===================================================================
--- trunk/iptables/include/linux/netfilter/xt_statistic.h	                        (rev 0)
+++ trunk/iptables/include/linux/netfilter/xt_statistic.h	2007-09-05 13:47:05 UTC (rev 7021)
@@ -0,0 +1,32 @@
+#ifndef _XT_STATISTIC_H
+#define _XT_STATISTIC_H
+
+enum xt_statistic_mode {
+	XT_STATISTIC_MODE_RANDOM,
+	XT_STATISTIC_MODE_NTH,
+	__XT_STATISTIC_MODE_MAX
+};
+#define XT_STATISTIC_MODE_MAX (__XT_STATISTIC_MODE_MAX - 1)
+
+enum xt_statistic_flags {
+	XT_STATISTIC_INVERT		= 0x1,
+};
+#define XT_STATISTIC_MASK		0x1
+
+struct xt_statistic_info {
+	u_int16_t			mode;
+	u_int16_t			flags;
+	union {
+		struct {
+			u_int32_t	probability;
+		} random;
+		struct {
+			u_int32_t	every;
+			u_int32_t	packet;
+			u_int32_t	count;
+		} nth;
+	} u;
+	struct xt_statistic_info	*master __attribute__((aligned(8)));
+};
+
+#endif /* _XT_STATISTIC_H */




More information about the netfilter-cvslog mailing list