diff --git a/Shorewall-perl/Shorewall/Chains.pm b/Shorewall-perl/Shorewall/Chains.pm index 6cd7fe3d3..ce01d232f 100644 --- a/Shorewall-perl/Shorewall/Chains.pm +++ b/Shorewall-perl/Shorewall/Chains.pm @@ -1426,7 +1426,7 @@ sub match_source_net( $;$ ) { $net =~ s/!// if my $invert = $1 ? '! ' : ''; validate_range $addr1, $addr2; iprange_match . "${invert}--src-range $net "; - } elsif ( $net =~ /^!?~.*$/ ) { + } elsif ( $net =~ /^!?~/ ) { fatal_error "MAC address cannot be used in this context" if $restriction >= OUTPUT_RESTRICT; mac_match $net; } elsif ( $net =~ /^(!?)\+/ ) {