forked from extern/shorewall_code
Implement '+' to specify inline matches as "early"
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
c36cee28fb
commit
90ace544eb
@ -2487,6 +2487,7 @@ sub process_rule ( $$$$$$$$$$$$$$$$$$$$ ) {
|
||||
my $raw_matches = '';
|
||||
my $exceptionrule = '';
|
||||
my $usergenerated;
|
||||
my $prerule = '';
|
||||
|
||||
if ( $inchain = defined $chainref ) {
|
||||
( $inaction, undef, undef, undef ) = split /:/, $normalized_action = $chainref->{action}, 4 if $chainref->{action};
|
||||
@ -2500,6 +2501,13 @@ sub process_rule ( $$$$$$$$$$$$$$$$$$$$ ) {
|
||||
$raw_matches = get_inline_matches(0);
|
||||
}
|
||||
#
|
||||
# Handle early matches
|
||||
#
|
||||
if ( $raw_matches =~ s/s*\+// ) {
|
||||
$prerule = $raw_matches;
|
||||
$raw_matches = '';
|
||||
}
|
||||
#
|
||||
# Determine the validity of the action
|
||||
#
|
||||
$actiontype = ( $targets{$basictarget} || find_macro ( $basictarget ) );
|
||||
@ -3142,7 +3150,7 @@ sub process_rule ( $$$$$$$$$$$$$$$$$$$$ ) {
|
||||
|
||||
expand_rule( $chainref ,
|
||||
$restriction ,
|
||||
'' ,
|
||||
$prerule ,
|
||||
$rule ,
|
||||
$source ,
|
||||
$dest ,
|
||||
|
Loading…
Reference in New Issue
Block a user