mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2025-01-26 22:21:07 +02:00
[package] firewall: insert rules at the beginning of chains again while maintaining non reversed order, fixes wrong ordering introduced by r18015
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19946 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
d96f30084c
commit
fa8f585a08
@ -294,8 +294,11 @@ fw_rule() {
|
||||
[ -n "$src" -a -z "$dest" ] && ZONE=zone_$src
|
||||
[ -n "$src" -a -n "$dest" ] && ZONE=zone_${src}_forward
|
||||
[ -n "$dest" ] && TARGET=zone_${dest}_$target
|
||||
|
||||
eval 'RULE_COUNT=$((++RULE_COUNT_'$ZONE'))'
|
||||
|
||||
add_rule() {
|
||||
$IPTABLES -A $ZONE \
|
||||
$IPTABLES -I $ZONE $RULE_COUNT \
|
||||
${proto:+-p $proto} \
|
||||
${icmp_type:+--icmp-type $icmp_type} \
|
||||
${src_ip:+-s $src_ip} \
|
||||
|
Loading…
x
Reference in New Issue
Block a user