mirror of
https://gitlab.com/shorewall/code.git
synced 2024-11-22 15:43:30 +01:00
Add hack to distinguish between the BLACKLIST macro and action
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
33b4ee4d31
commit
2bbb5c8c1e
@ -2,6 +2,8 @@
|
||||
# Shorewall -- /usr/share/shorewall/macro.blacklist
|
||||
#
|
||||
# This macro handles blacklisting using BLACKLIST_DISPOSITION and BLACKLIST_LOGLEVEL.
|
||||
# It is usable only in the blrules file; in the rules file the action by the
|
||||
# same name is invoked.
|
||||
#
|
||||
###############################################################################
|
||||
#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST RATE USER
|
||||
|
@ -2736,7 +2736,13 @@ sub process_rule ( $$$$$$$$$$$$$$$$$$$$ ) {
|
||||
#
|
||||
# Determine the validity of the action
|
||||
#
|
||||
$actiontype = ( $targets{$basictarget} || find_macro ( $basictarget ) );
|
||||
if ( $actiontype = $targets{$basictarget} ) {
|
||||
if ( $section == BLACKLIST_SECTION && $basictarget eq 'BLACKLIST' ) {
|
||||
assert( $actiontype = find_macro( 'BLACKLIST' ) );
|
||||
}
|
||||
} else {
|
||||
$actiontype = find_macro ( $basictarget );
|
||||
}
|
||||
|
||||
if ( $config{ MAPOLDACTIONS } ) {
|
||||
( $basictarget, $actiontype , $param ) = map_old_actions( $basictarget ) unless $actiontype || supplied $param;
|
||||
|
Loading…
Reference in New Issue
Block a user