patch-2.3.99-pre2 linux/include/linux/netfilter_ipv4/ip_nat_helper.h

Next file: linux/include/linux/netfilter_ipv4/ip_nat_protocol.h
Previous file: linux/include/linux/netfilter_ipv4/ip_nat_ftp.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.99-pre1/linux/include/linux/netfilter_ipv4/ip_nat_helper.h linux/include/linux/netfilter_ipv4/ip_nat_helper.h
@@ -0,0 +1,30 @@
+#ifndef _IP_NAT_HELPER_H
+#define _IP_NAT_HELPER_H
+/* NAT protocol helper routines. */
+
+#include <linux/netfilter_ipv4/ip_conntrack.h>
+
+struct sk_buff;
+
+struct ip_nat_helper
+{
+	/* Internal use */
+	struct list_head list;
+
+	/* Here's the protocol and dst we care about. */
+	u_int16_t protocol;
+	u_int16_t protocol_dst;
+
+	/* Helper function: returns verdict */
+	unsigned int (*help)(struct ip_conntrack *ct,
+			     struct ip_nat_info *info,
+			     enum ip_conntrack_info ctinfo,
+			     unsigned int hooknum,
+			     struct sk_buff **pskb);
+
+	const char *name;
+};
+
+extern int ip_nat_helper_register(struct ip_nat_helper *me);
+extern void ip_nat_helper_unregister(struct ip_nat_helper *me);
+#endif

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)