forked from extern/shorewall_code
Logically OR builtin definitions from the actions file if the builtin exists
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
f7bbac6ea8
commit
6c990a7253
@ -1789,16 +1789,22 @@ sub process_actions() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ( $builtin ) {
|
if ( $builtin ) {
|
||||||
my $actiontype = USERBUILTIN | OPTIONS;
|
my $actiontype = USERBUILTIN | OPTIONS;
|
||||||
$actiontype |= MANGLE_TABLE if $mangle;
|
$actiontype |= MANGLE_TABLE if $mangle;
|
||||||
$actiontype |= RAW_TABLE if $raw;
|
$actiontype |= RAW_TABLE if $raw;
|
||||||
$actiontype |= NAT_TABLE if $nat;
|
$actiontype |= NAT_TABLE if $nat;
|
||||||
#
|
#
|
||||||
# For backward compatibility, we assume that user-defined builtins are valid in the filter table
|
# For backward compatibility, we assume that user-defined builtins are valid in the filter table
|
||||||
#
|
#
|
||||||
$actiontype |= FILTER_TABLE if $filter || ! ($mangle || $raw || $nat);
|
$actiontype |= FILTER_TABLE if $filter || ! ($mangle || $raw || $nat);
|
||||||
$builtin_target{$action} = $actiontype;
|
|
||||||
$targets{$action} = $actiontype;
|
if ( $builtin_target{$action} ) {
|
||||||
|
$builtin_target{$action} |= $actiontype;
|
||||||
|
} else {
|
||||||
|
$builtin_target{$action} = $actiontype;
|
||||||
|
}
|
||||||
|
|
||||||
|
$targets{$action} = $actiontype;
|
||||||
} else {
|
} else {
|
||||||
fatal_error "Table names are only allowed for builtin actions" if $mangle || $raw || $nat || $filter;
|
fatal_error "Table names are only allowed for builtin actions" if $mangle || $raw || $nat || $filter;
|
||||||
new_action $action, $type, $noinline, $nolog;
|
new_action $action, $type, $noinline, $nolog;
|
||||||
|
Loading…
Reference in New Issue
Block a user