mirror of
https://gitlab.com/shorewall/code.git
synced 2025-01-18 03:29:12 +01:00
Disallow DEFAULTS in the rules file
This commit is contained in:
parent
d51ca478bd
commit
ece598288f
@ -2373,11 +2373,20 @@ sub process_rule ( ) {
|
||||
#
|
||||
process_section( 'NEW' ) unless $section;
|
||||
|
||||
if ( $target eq 'DEFAULTS' ) {
|
||||
if ( @actionstack ) {
|
||||
default_action_params( split_list $source, 'defaults' );
|
||||
next;
|
||||
}
|
||||
|
||||
fatal_error "DEFAULTS is only allowed in an ACTION file";
|
||||
}
|
||||
|
||||
if ( $source =~ /^none(:.*)?$/i || $dest =~ /^none(:.*)?$/i ) {
|
||||
progress_message "Rule \"$currentline\" ignored.";
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
my $intrazone = 0;
|
||||
my $wild = 0;
|
||||
my $thisline = $currentline; #We must save $currentline because it is overwritten by macro expansion
|
||||
|
Loading…
Reference in New Issue
Block a user