diff --git a/New/Shorewall/Common.pm b/New/Shorewall/Common.pm index 5dabe909b..29fcb5b67 100644 --- a/New/Shorewall/Common.pm +++ b/New/Shorewall/Common.pm @@ -106,7 +106,7 @@ sub emit ( $ ) { # # 'compile' as opposed to 'check' # - my $line = $_[0]; # This copy is necessary :-(. We modify the value below and we can't modify subroutine arguments. + my $line = $_[0]; # This copy is necessary because the actual arguments are almost always read-only. unless ( $line =~ /^\s*$/ ) { $line =~ s/^\n// if $lastlineblank; diff --git a/New/Shorewall/Rules.pm b/New/Shorewall/Rules.pm index 600c59f05..9aac1666b 100644 --- a/New/Shorewall/Rules.pm +++ b/New/Shorewall/Rules.pm @@ -491,6 +491,8 @@ sub add_common_rules() { if ( $capabilities{ADDRTYPE} ) { $chainref = new_standard_chain 'smurfs'; + add_rule $chainref , '-s 0.0.0.0 -j RETURN'; + add_rule_pair $chainref, '-m addrtype --src-type BROADCAST ', 'DROP', $config{SMURF_LOG_LEVEL} ; add_rule_pair $chainref, '-m addrtype --src-type MULTICAST ', 'DROP', $config{SMURF_LOG_LEVEL} ;