diff --git a/Shorewall-perl/Shorewall/Tunnels.pm b/Shorewall-perl/Shorewall/Tunnels.pm index bc91b5000..0e26a25a3 100644 --- a/Shorewall-perl/Shorewall/Tunnels.pm +++ b/Shorewall-perl/Shorewall/Tunnels.pm @@ -71,6 +71,7 @@ sub setup_tunnels() { unless ( $gatewayzones eq '-' ) { for my $zone ( split /,/, $gatewayzones ) { + fatal_error "Unknown zone ($zone)" unless $zones{zone}; fatal_error "Invalid zone ($zone)" unless $zones{$zone}{type} eq 'ipv4'; $inchainref = ensure_filter_chain "${zone}2${firewall_zone}", 1; $outchainref = ensure_filter_chain "${firewall_zone}2${zone}", 1; @@ -209,6 +210,8 @@ sub setup_tunnels() { sub setup_one_tunnel($$$$) { my ( $kind , $zone, $gateway, $gatewayzones ) = @_; + fatal_error "Unknown zone ($zone)" unless $zones{zone}; + fatal_error "Invalid zone ($zone)" unless $zones{$zone}{type} eq 'ipv4'; my $inchainref = ensure_filter_chain "${zone}2${firewall_zone}", 1;