mirror of
https://gitlab.com/shorewall/code.git
synced 2024-12-22 22:30:58 +01:00
Add new zone-list function to return all but firewall zone.
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
c8274f0538
commit
21ce6f9b84
@ -1589,7 +1589,7 @@ sub process_rule ( ) {
|
||||
if ( $anydest ) {
|
||||
@dest = ( all_parent_zones );
|
||||
} else {
|
||||
@dest = ( non_firewall_zones, vserver_zones )
|
||||
@dest = ( non_firewall_zones )
|
||||
}
|
||||
|
||||
unshift @dest, firewall_zone if $includedstfw;
|
||||
@ -1841,7 +1841,7 @@ sub generate_matrix() {
|
||||
my $preroutingref = ensure_chain 'nat', 'dnat';
|
||||
my $fw = firewall_zone;
|
||||
my $notrackref = $raw_table->{notrack_chain $fw};
|
||||
my @zones = non_firewall_zones;
|
||||
my @zones = off_firewall_zones;
|
||||
my @vservers = vserver_zones;
|
||||
my $interface_jumps_added = 0;
|
||||
our %input_jump_added = ();
|
||||
|
@ -54,6 +54,7 @@ our @EXPORT = qw( NOTHING
|
||||
all_parent_zones
|
||||
complex_zones
|
||||
vserver_zones
|
||||
off_firewall_zones
|
||||
non_firewall_zones
|
||||
single_interface
|
||||
chain_base
|
||||
@ -730,10 +731,14 @@ sub all_zones() {
|
||||
@zones;
|
||||
}
|
||||
|
||||
sub non_firewall_zones() {
|
||||
sub off_firewall_zones() {
|
||||
grep ( ! ( $zones{$_}{type} == FIREWALL || $zones{$_}{type} == VSERVER ) , @zones );
|
||||
}
|
||||
|
||||
sub non_firewall_zones() {
|
||||
grep ( $zones{$_}{type} != FIREWALL , @zones );
|
||||
}
|
||||
|
||||
sub all_parent_zones() {
|
||||
grep ( ! @{$zones{$_}{parents}} , @zones );
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user