}
}
+# Checks for a valid country code
+sub validcc($) {
+ my $cc = shift;
+
+ # Must contain of exactly two uppercase characters, or must be A1, A2, or A3
+ return ($cc =~ m/^([A-Z]{2}|A[123])$/);
+}
+
sub IpInSubnet {
my $addr = shift;
my $network = shift;
WARNING: untranslated string: fwhost err sub32 = Please add a network, not a single host
WARNING: untranslated string: fwhost hint = Note
WARNING: untranslated string: fwhost icmptype = ICMP type:
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: fwhost ip_mac = IP/MAC address
WARNING: untranslated string: fwhost ipsec net = IPsec networks:
WARNING: untranslated string: fwhost menu = Firewall Groups
WARNING: untranslated string: extrahd because it is outside the allowed mount path = unknown string
WARNING: untranslated string: fwhost cust locationgrp = unknown string
WARNING: untranslated string: fwhost err hostip = unknown string
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: guardian block a host = unknown string
WARNING: untranslated string: guardian block httpd brute-force = unknown string
WARNING: untranslated string: guardian block ssh brute-force = unknown string
WARNING: untranslated string: fwdfw syn flood protection = Enable SYN Flood Protection (TCP only)
WARNING: untranslated string: fwhost cust locationgrp = unknown string
WARNING: untranslated string: fwhost err hostip = unknown string
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: fwhost wg peers = WireGuard Peers
WARNING: untranslated string: guardian block a host = unknown string
WARNING: untranslated string: guardian block httpd brute-force = unknown string
WARNING: untranslated string: fwhost cust locationgroup = Location Groups
WARNING: untranslated string: fwhost cust locationgrp = unknown string
WARNING: untranslated string: fwhost err hostip = unknown string
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: fwhost newlocationgrp = Location Groups
WARNING: untranslated string: fwhost wg peers = WireGuard Peers
WARNING: untranslated string: generate ptr = Generate PTR
WARNING: untranslated string: fwhost cust locationgroup = Location Groups
WARNING: untranslated string: fwhost cust locationgrp = unknown string
WARNING: untranslated string: fwhost err hostip = unknown string
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: fwhost newlocationgrp = Location Groups
WARNING: untranslated string: fwhost wg peers = WireGuard Peers
WARNING: untranslated string: generate ptr = Generate PTR
WARNING: untranslated string: fwhost err sub32 = Please add a network, not a single host
WARNING: untranslated string: fwhost hint = Note
WARNING: untranslated string: fwhost icmptype = ICMP type:
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: fwhost ip_mac = IP/MAC address
WARNING: untranslated string: fwhost ipsec net = IPsec networks:
WARNING: untranslated string: fwhost menu = Firewall Groups
WARNING: untranslated string: fwhost err sub32 = Please add a network, not a single host
WARNING: untranslated string: fwhost hint = Note
WARNING: untranslated string: fwhost icmptype = ICMP type:
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: fwhost ip_mac = IP/MAC address
WARNING: untranslated string: fwhost ipsec net = IPsec networks:
WARNING: untranslated string: fwhost menu = Firewall Groups
WARNING: untranslated string: fwdfw syn flood protection = Enable SYN Flood Protection (TCP only)
WARNING: untranslated string: fwhost cust locationgrp = unknown string
WARNING: untranslated string: fwhost err hostip = unknown string
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: fwhost wg peers = WireGuard Peers
WARNING: untranslated string: generate ptr = Generate PTR
WARNING: untranslated string: guardian block a host = unknown string
WARNING: untranslated string: extrahd because it is outside the allowed mount path = unknown string
WARNING: untranslated string: fwhost cust locationgrp = unknown string
WARNING: untranslated string: fwhost err hostip = unknown string
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: guaranteed bandwidth = Guaranteed bandwidth
WARNING: untranslated string: guardian block a host = unknown string
WARNING: untranslated string: guardian block httpd brute-force = unknown string
WARNING: untranslated string: extrahd because it is outside the allowed mount path = unknown string
WARNING: untranslated string: fwhost cust locationgrp = unknown string
WARNING: untranslated string: fwhost err hostip = unknown string
+WARNING: untranslated string: fwhost invalid country code = Invalid Country Code
WARNING: untranslated string: guaranteed bandwidth = Guaranteed bandwidth
WARNING: untranslated string: guardian block a host = unknown string
WARNING: untranslated string: guardian block httpd brute-force = unknown string
< AES-256-GCM
< CHACHA20-POLY1305
< dns servers
+< fwhost invalid country code
< ids all including informational
< ids email alerts
< ids email alert severity
< endpoint port
< extrahd because it it outside the allowed mount path
< fwdfw syn flood protection
+< fwhost invalid country code
< fwhost wg peers
< g.dtm
< g.lite
< fwhost cust location
< fwhost cust locationgroup
< fwhost cust locationlocation
+< fwhost invalid country code
< fwhost newlocationgrp
< fwhost wg peers
< fw red
< fwhost cust location
< fwhost cust locationgroup
< fwhost cust locationlocation
+< fwhost invalid country code
< fwhost newlocationgrp
< fwhost wg peers
< fw red
< fwhost hint
< fwhost hosts
< fwhost icmptype
+< fwhost invalid country code
< fwhost ipadr
< fwhost ip_mac
< fwhost ipsec host
< fwhost hint
< fwhost hosts
< fwhost icmptype
+< fwhost invalid country code
< fwhost ipadr
< fwhost ip_mac
< fwhost ipsec host
< foreshadow
< fwdfw all subnets
< fwdfw syn flood protection
+< fwhost invalid country code
< fwhost wg peers
< fw red
< generate ptr
< Captive wrong type
< CHACHA20-POLY1305
< dns servers
+< fwhost invalid country code
< guaranteed bandwidth
< ids all including informational
< ids email alerts
< Captive wrong type
< CHACHA20-POLY1305
< dns servers
+< fwhost invalid country code
< guaranteed bandwidth
< ids all including informational
< ids email alerts
# Check name
if (!&validhostname($grp)){$errormessage.=$Lang::tr{'fwhost err name'};}
+ unless (&General::validcc($fwhostsettings{'COUNTRY_CODE'})) {
+ $errormessage = $Lang::tr{'fwhost invalid country code'};
+ }
+
# Check for existing group name.
if (!&checkgroup($grp) && $fwhostsettings{'update'} ne 'on'){
$errormessage = $Lang::tr{'fwhost err grpexist'};
}
if ($fwhostsettings{'update'} eq 'on'){
- @target=&Header::escape($fwhostsettings{'COUNTRY_CODE'});
+ @target = $fwhostsettings{'COUNTRY_CODE'};
$type='Location Group';
#check if host/net exists in grp
'fwhost hint' => 'Hinweis',
'fwhost hosts' => 'Firewall-Hosts',
'fwhost icmptype' => 'ICMP-Typ:',
+'fwhost invalid country code' => 'Ungültiger Ländercode',
'fwhost ip_mac' => 'IP/MAC-Adresse',
'fwhost ipadr' => 'IP-Adresse:',
'fwhost ipsec host' => 'IPsec-Clients:',
'fwhost hint' => 'Note',
'fwhost hosts' => 'Firewall Hosts',
'fwhost icmptype' => 'ICMP type:',
+'fwhost invalid country code' => 'Invalid Country Code',
'fwhost ip_mac' => 'IP/MAC address',
'fwhost ipadr' => 'IP address:',
'fwhost ipsec host' => 'IPsec clients:',