Don't apply rate limiting twice in ACCEPT+ rules

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2010-02-19 13:57:45 -08:00
parent 5b77f378e5
commit 8eb3de7db2

View File

@ -1182,9 +1182,9 @@ sub process_rule1 ( $$$$$$$$$$$$$ ) {
#
# Generate Fixed part of the rule
#
if ( ( $actiontype & ( NATRULE | NATONLY ) ) == NATRULE ) {
if ( $actiontype & ( NATRULE | NONAT ) && ! ( $actiontype & NATONLY ) ) {
#
# Don't apply rate limiting twice
# Either a DNAT, REDIRECT or ACCEPT+ rule; don't apply rate limiting twice
#
$rule = join( '',
do_proto($proto, $ports, $sports),