[packages] nodogsplash: fix use of deprecated iptables syntax
authorjow <jow@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sun, 1 Jul 2012 11:44:23 +0000 (11:44 +0000)
committerjow <jow@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sun, 1 Jul 2012 11:44:23 +0000 (11:44 +0000)
Based on http://patchwork.openwrt.org/patch/2256/ by Moritz Warning <moritzwarning@web.de>

git-svn-id: svn://svn.openwrt.org/openwrt/packages/net/nodogsplash@32571 3c298f89-4303-0410-b956-a3cf2f4a3e73

Makefile
patches/002-deprecated_iptables_syntax.patch [new file with mode: 0644]

index 1e2b514..69ac310 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2007-2011 OpenWrt.org
+# Copyright (C) 2007-2012 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=nodogsplash
 PKG_VERSION:=0.9_beta9.9.6
-PKG_RELEASE:=2
+PKG_RELEASE:=3
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=http://kokoro.ucsd.edu/nodogsplash/ \
diff --git a/patches/002-deprecated_iptables_syntax.patch b/patches/002-deprecated_iptables_syntax.patch
new file mode 100644 (file)
index 0000000..26a22af
--- /dev/null
@@ -0,0 +1,11 @@
+--- a/src/fw_iptables.c
++++ b/src/fw_iptables.c
+@@ -449,7 +449,7 @@ iptables_fw_init(void) {
+   /* CHAIN_TO_ROUTER, related and established packets  ACCEPT */
+   rc |= iptables_do_command("-t filter -A " CHAIN_TO_ROUTER " -m state --state RELATED,ESTABLISHED -j ACCEPT");
+   /* CHAIN_TO_ROUTER, bogus SYN packets  DROP */
+-  rc |= iptables_do_command("-t filter -A " CHAIN_TO_ROUTER " -p tcp --tcp-flags SYN SYN --tcp-option \\! 2 -j  DROP");
++  rc |= iptables_do_command("-t filter -A " CHAIN_TO_ROUTER " -p tcp --tcp-flags SYN SYN \\! --tcp-option 2 -j  DROP");
+   /* CHAIN_TO_ROUTER, packets to HTTP listening on gw_port on router ACCEPT */
+   rc |= iptables_do_command("-t filter -A " CHAIN_TO_ROUTER " -p tcp --dport %d -j ACCEPT", gw_port);