forked from extern/shorewall_code
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 ) {
|
if ( $anydest ) {
|
||||||
@dest = ( all_parent_zones );
|
@dest = ( all_parent_zones );
|
||||||
} else {
|
} else {
|
||||||
@dest = ( non_firewall_zones, vserver_zones )
|
@dest = ( non_firewall_zones )
|
||||||
}
|
}
|
||||||
|
|
||||||
unshift @dest, firewall_zone if $includedstfw;
|
unshift @dest, firewall_zone if $includedstfw;
|
||||||
@ -1841,7 +1841,7 @@ sub generate_matrix() {
|
|||||||
my $preroutingref = ensure_chain 'nat', 'dnat';
|
my $preroutingref = ensure_chain 'nat', 'dnat';
|
||||||
my $fw = firewall_zone;
|
my $fw = firewall_zone;
|
||||||
my $notrackref = $raw_table->{notrack_chain $fw};
|
my $notrackref = $raw_table->{notrack_chain $fw};
|
||||||
my @zones = non_firewall_zones;
|
my @zones = off_firewall_zones;
|
||||||
my @vservers = vserver_zones;
|
my @vservers = vserver_zones;
|
||||||
my $interface_jumps_added = 0;
|
my $interface_jumps_added = 0;
|
||||||
our %input_jump_added = ();
|
our %input_jump_added = ();
|
||||||
|
@ -54,6 +54,7 @@ our @EXPORT = qw( NOTHING
|
|||||||
all_parent_zones
|
all_parent_zones
|
||||||
complex_zones
|
complex_zones
|
||||||
vserver_zones
|
vserver_zones
|
||||||
|
off_firewall_zones
|
||||||
non_firewall_zones
|
non_firewall_zones
|
||||||
single_interface
|
single_interface
|
||||||
chain_base
|
chain_base
|
||||||
@ -730,10 +731,14 @@ sub all_zones() {
|
|||||||
@zones;
|
@zones;
|
||||||
}
|
}
|
||||||
|
|
||||||
sub non_firewall_zones() {
|
sub off_firewall_zones() {
|
||||||
grep ( ! ( $zones{$_}{type} == FIREWALL || $zones{$_}{type} == VSERVER ) , @zones );
|
grep ( ! ( $zones{$_}{type} == FIREWALL || $zones{$_}{type} == VSERVER ) , @zones );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub non_firewall_zones() {
|
||||||
|
grep ( $zones{$_}{type} != FIREWALL , @zones );
|
||||||
|
}
|
||||||
|
|
||||||
sub all_parent_zones() {
|
sub all_parent_zones() {
|
||||||
grep ( ! @{$zones{$_}{parents}} , @zones );
|
grep ( ! @{$zones{$_}{parents}} , @zones );
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user