mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-28 11:43:25 +02:00
firewall: Fix creation of automatic rules for the firewall.
If the firewall is part of a local network (e.g. GREEN), we automatically add rules that grant/forbid access for the firewall, too. This has been broken for various default policies other than ALLOWED.
This commit is contained in:
@@ -520,6 +520,9 @@ sub get_internal_firewall_ip_address
|
||||
return 0;
|
||||
}
|
||||
|
||||
# Convert net mask into correct format for &General::IpInSubnet().
|
||||
$net_mask = &General::iporsubtodec($net_mask);
|
||||
|
||||
my @addresses = &get_internal_firewall_ip_addresses($use_orange);
|
||||
foreach my $zone_address (@addresses) {
|
||||
if (&General::IpInSubnet($zone_address, $net_address, $net_mask)) {
|
||||
|
||||
Reference in New Issue
Block a user