diff --git a/etc/inc/services.inc b/etc/inc/services.inc index 33e21683d8..8c69cb04b3 100644 --- a/etc/inc/services.inc +++ b/etc/inc/services.inc @@ -1559,7 +1559,9 @@ function services_dnsmasq_configure() { /* Setup forwarded domains */ if (isset($config['dnsmasq']['domainoverrides']) && is_array($config['dnsmasq']['domainoverrides'])) { foreach($config['dnsmasq']['domainoverrides'] as $override) { - $args .= ' --server=/' . $override['domain'] . '/' . $override['ip']; + if ($override['ip'] == "!") + $override[ip] = ""; + $args .= ' --server=/' . $override['domain'] . '/' . $override['ip']; } } diff --git a/usr/local/www/services_dnsmasq_domainoverride_edit.php b/usr/local/www/services_dnsmasq_domainoverride_edit.php index 74869b4de1..52714c996d 100755 --- a/usr/local/www/services_dnsmasq_domainoverride_edit.php +++ b/usr/local/www/services_dnsmasq_domainoverride_edit.php @@ -86,8 +86,8 @@ if ($_POST) { elseif ($_POST['domain'] && !is_domain($_POST['domain'])) { $input_errors[] = gettext("A valid domain must be specified."); } - if ($_POST['ip'] && !is_ipaddr($_POST['ip']) && ($_POST['ip'] != '#')) { - $input_errors[] = gettext("A valid IP address must be specified, or # for an exclusion."); + if ($_POST['ip'] && !is_ipaddr($_POST['ip']) && ($_POST['ip'] != '#') && ($_POST['ip'] != '!')) { + $input_errors[] = gettext("A valid IP address must be specified, or # for an exclusion or ! to not forward at all."); } if ($_POST['dnssrcip'] && !in_array($_POST['dnssrcip'], get_configured_ip_addresses())) { $input_errors[] = gettext("An interface IP address must be specified for the DNS query source."); @@ -131,14 +131,14 @@ include("head.inc");

-
+ mycompany.localdomain 1.168.192.in-addr.arpa

- 192.168.100.100
+ 192.168.100.100