We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1407f6a commit 9399370Copy full SHA for 9399370
etc/inc/services.inc
@@ -851,6 +851,15 @@ EOD;
851
continue;
852
$primary = $zone['dns-servers'][0];
853
$secondary = empty($zone['dns-servers'][1]) ? "" : $zone['dns-servers'][1];
854
+ // Make sure we aren't using any invalid or IPv6 DNS servers.
855
+ if (!is_ipaddrv4($primary)) {
856
+ if (is_ipaddrv4($secondary)) {
857
+ $primary = $secondary;
858
+ $secondary = "";
859
+ } else {
860
+ continue;
861
+ }
862
863
// We don't need to add zones multiple times.
864
if (!in_array($zone['domain-name'], $added_zones)) {
865
$dhcpdconf .= "zone {$zone['domain-name']} {\n";
0 commit comments