mirror of
https://gitlab.com/shorewall/code.git
synced 2025-06-20 17:58:07 +02:00
Fix minor maclist bug
git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@6126 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
parent
b95db312b5
commit
76506f7c1f
@ -732,7 +732,7 @@ log_rule_limit() # $1 = log level, $2 = chain, $3 = display Chain $4 = dispositi
|
|||||||
|
|
||||||
shift 7
|
shift 7
|
||||||
|
|
||||||
save_command "do_log_rule_limit \"$level\" \"$chain\" \"$displayChain\" \"$disposition\" \"$limit\" \"$tag\" \"$command\" $@"
|
save_command "do_log_rule_limit \"$level\" \"$chain\" \"$displayChain\" \"$disposition\" \"$limit\" \"$tag\" \"$command\" $(fix_bang $@)"
|
||||||
}
|
}
|
||||||
|
|
||||||
log_rule() # $1 = log level, $2 = chain, $3 = disposition , $... = predicates for the rule
|
log_rule() # $1 = log level, $2 = chain, $3 = disposition , $... = predicates for the rule
|
||||||
|
@ -192,7 +192,7 @@ setup_mac_lists() # $1 = Phase Number
|
|||||||
if [ -z "$addresses" ]; then
|
if [ -z "$addresses" ]; then
|
||||||
[ -n "$level" ] && \
|
[ -n "$level" ] && \
|
||||||
log_rule_limit $level $chain $(mac_chain $interface) $disposition "$LOGLIMIT" "" -A -t $MACLIST_TABLE $macpart $physdev_part
|
log_rule_limit $level $chain $(mac_chain $interface) $disposition "$LOGLIMIT" "" -A -t $MACLIST_TABLE $macpart $physdev_part
|
||||||
run_iptables -A $chain -t $MACLIST_TABLE $macpart $physdev_part -j $target
|
run_iptables2 -A $chain -t $MACLIST_TABLE $macpart $physdev_part -j $target
|
||||||
else
|
else
|
||||||
for address in $(separate_list $addresses) ; do
|
for address in $(separate_list $addresses) ; do
|
||||||
[ -n "$level" ] && \
|
[ -n "$level" ] && \
|
||||||
@ -213,12 +213,12 @@ setup_mac_lists() # $1 = Phase Number
|
|||||||
case $MACLIST_TABLE in
|
case $MACLIST_TABLE in
|
||||||
filter)
|
filter)
|
||||||
for chain in $(first_chains $interface) ; do
|
for chain in $(first_chains $interface) ; do
|
||||||
run_iptables -A $chain $(match_source_hosts $hosts) -m state --state NEW \
|
run_iptables2 -A $chain $(match_source_hosts $hosts) -m state --state NEW \
|
||||||
$policy -j $(mac_chain $interface)
|
$policy -j $(mac_chain $interface)
|
||||||
done
|
done
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
run_iptables -t mangle -A PREROUTING -i $interface $(match_source_hosts $hosts) -m state --state NEW \
|
run_iptables2 -t mangle -A PREROUTING -i $interface $(match_source_hosts $hosts) -m state --state NEW \
|
||||||
$policy -j $(mac_chain $interface)
|
$policy -j $(mac_chain $interface)
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
Loading…
x
Reference in New Issue
Block a user