Browse Source

mwan3: Update to version 1.5-2

Fix issue icmp unreachables go out wrong interface
Remove unnecessary line

Signed-off-by: Jeroen Louwes <jeroen.louwes@gmail.com>
Adze1502 10 years ago
parent
commit
35d05cfebe
3 changed files with 12 additions and 13 deletions
  1. 4
    4
      net/mwan3/Makefile
  2. 7
    8
      net/mwan3/files/etc/hotplug.d/iface/15-mwan3
  3. 1
    1
      net/mwan3/files/usr/sbin/mwan3

+ 4
- 4
net/mwan3/Makefile View File

@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
9 9
 
10 10
 PKG_NAME:=mwan3
11 11
 PKG_VERSION:=1.5
12
-PKG_RELEASE:=1
12
+PKG_RELEASE:=2
13 13
 PKG_MAINTAINER:=Jeroen Louwes <jeroen.louwes@gmail.com>
14 14
 PKG_LICENSE:=GPLv2
15 15
 
@@ -26,9 +26,9 @@ define Package/mwan3
26 26
 endef
27 27
 
28 28
 define Package/mwan3/description
29
-	Hotplug script which makes configuration of multiple WAN interfaces simple
30
-	and manageable. With loadbalancing/failover support for up to 250 wan
31
-	interfaces, connection tracking and an easy to manage traffic ruleset.
29
+Hotplug script which makes configuration of multiple WAN interfaces simple
30
+and manageable. With loadbalancing/failover support for up to 250 wan
31
+interfaces, connection tracking and an easy to manage traffic ruleset.
32 32
 endef
33 33
 
34 34
 define Package/mwan3/conffiles

+ 7
- 8
net/mwan3/files/etc/hotplug.d/iface/15-mwan3 View File

@@ -29,8 +29,9 @@ mwan3_set_general_iptables()
29 29
 		$IPT -A mwan3_hook -j CONNMARK --save-mark --nfmask 0xff00 --ctmask 0xff00
30 30
 	fi
31 31
 
32
-	if ! $IPT -S mwan3_track_hook &> /dev/null; then
33
-		$IPT -N mwan3_track_hook
32
+	if ! $IPT -S mwan3_output_hook &> /dev/null; then
33
+		$IPT -N mwan3_output_hook
34
+		$IPT -A mwan3_output_hook -p icmp -m icmp --icmp-type 3 -j MARK --set-xmark 0xff00/0xff00
34 35
 	fi
35 36
 
36 37
 	if ! $IPT -S PREROUTING | grep mwan3_hook &> /dev/null; then
@@ -41,8 +42,8 @@ mwan3_set_general_iptables()
41 42
 		$IPT -A OUTPUT -j mwan3_hook
42 43
 	fi
43 44
 
44
-	if ! $IPT -S OUTPUT | grep mwan3_track_hook &> /dev/null; then
45
-		$IPT -A OUTPUT -j mwan3_track_hook
45
+	if ! $IPT -S OUTPUT | grep mwan3_output_hook &> /dev/null; then
46
+		$IPT -A OUTPUT -j mwan3_output_hook
46 47
 	fi
47 48
 
48 49
 	$IPT -F mwan3_rules
@@ -140,7 +141,7 @@ mwan3_track()
140 141
 
141 142
 		if ! $IPT -S mwan3_track_$INTERFACE &> /dev/null; then
142 143
 			$IPT -N mwan3_track_$INTERFACE
143
-			$IPT -A mwan3_track_hook -p icmp -m icmp --icmp-type 8 -m length --length 32 -j mwan3_track_$INTERFACE
144
+			$IPT -A mwan3_output_hook -p icmp -m icmp --icmp-type 8 -m length --length 32 -j mwan3_track_$INTERFACE
144 145
 		fi
145 146
 
146 147
 		$IPT -F mwan3_track_$INTERFACE
@@ -151,7 +152,7 @@ mwan3_track()
151 152
 
152 153
 		[ -x /usr/sbin/mwan3track ] && /usr/sbin/mwan3track $INTERFACE $DEVICE $reliability $count $timeout $interval $down $up $track_ips &
153 154
 	else
154
-		$IPT -D mwan3_track_hook -p icmp -m icmp --icmp-type 8 -m length --length 32 -j mwan3_track_$INTERFACE &> /dev/null
155
+		$IPT -D mwan3_output_hook -p icmp -m icmp --icmp-type 8 -m length --length 32 -j mwan3_track_$INTERFACE &> /dev/null
155 156
 		$IPT -F mwan3_track_$INTERFACE &> /dev/null
156 157
 		$IPT -X mwan3_track_$INTERFACE &> /dev/null
157 158
 	fi
@@ -223,8 +224,6 @@ mwan3_set_policies_iptables()
223 224
 	total_weight=0
224 225
 
225 226
 	config_list_foreach $policy use_member mwan3_set_policy
226
-
227
-	$IPT -X $policy &> /dev/null
228 227
 }
229 228
 
230 229
 mwan3_set_user_rules_iptables()

+ 1
- 1
net/mwan3/files/usr/sbin/mwan3 View File

@@ -190,7 +190,7 @@ stop()
190 190
 
191 191
 	$IPT -D PREROUTING -j mwan3_hook &> /dev/null
192 192
 	$IPT -D OUTPUT -j mwan3_hook &> /dev/null
193
-	$IPT -D OUTPUT -j mwan3_track_hook &> /dev/null
193
+	$IPT -D OUTPUT -j mwan3_output_hook &> /dev/null
194 194
 
195 195
 	for table in $($IPT -S | awk '{print $2}' | grep mwan3 | sort -u); do
196 196
 		$IPT -F $table &> /dev/null