summaryrefslogtreecommitdiff
path: root/include/uapi/linux/netfilter/xt_ipcomp.h
diff options
context:
space:
mode:
authorfan.du <fan.du@windriver.com>2013-12-18 11:27:02 +0800
committerPablo Neira Ayuso <pablo@netfilter.org>2013-12-24 12:37:58 +0100
commit6a649f339802f104549e1fb211e381036661e244 (patch)
tree673fd543f147e890e2cd34deceaa70606ff83054 /include/uapi/linux/netfilter/xt_ipcomp.h
parent08c0cad69f32ad1e881fa3fb7f5e0a25db5b07ce (diff)
netfilter: add IPv4/6 IPComp extension match support
With this plugin, user could specify IPComp tagged with certain CPI that host not interested will be DROPped or any other action. For example: iptables -A INPUT -p 108 -m ipcomp --ipcompspi 0x87 -j DROP ip6tables -A INPUT -p 108 -m ipcomp --ipcompspi 0x87 -j DROP Then input IPComp packet with CPI equates 0x87 will not reach upper layer anymore. Signed-off-by: Fan Du <fan.du@windriver.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include/uapi/linux/netfilter/xt_ipcomp.h')
-rw-r--r--include/uapi/linux/netfilter/xt_ipcomp.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/include/uapi/linux/netfilter/xt_ipcomp.h b/include/uapi/linux/netfilter/xt_ipcomp.h
new file mode 100644
index 000000000000..45c7e40eb8e1
--- /dev/null
+++ b/include/uapi/linux/netfilter/xt_ipcomp.h
@@ -0,0 +1,16 @@
+#ifndef _XT_IPCOMP_H
+#define _XT_IPCOMP_H
+
+#include <linux/types.h>
+
+struct xt_ipcomp {
+ __u32 spis[2]; /* Security Parameter Index */
+ __u8 invflags; /* Inverse flags */
+ __u8 hdrres; /* Test of the Reserved Filed */
+};
+
+/* Values for "invflags" field in struct xt_ipcomp. */
+#define XT_IPCOMP_INV_SPI 0x01 /* Invert the sense of spi. */
+#define XT_IPCOMP_INV_MASK 0x01 /* All possible flags. */
+
+#endif /*_XT_IPCOMP_H*/