Unbound: prevent wilcard domains for this machines primary domain (since you can't forward all and be responsible for a part). mentioned here https://github.com/opnsense/core/issues/4049

This commit is contained in:
Ad Schellevis 2020-04-23 08:28:08 +02:00
parent 600c794fcf
commit 74f235ac4a

View File

@ -83,6 +83,13 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
$input_errors[] = gettext("A valid domain must be specified.");
}
if (!empty($pconfig['domain']) && $pconfig['domain'] == $config['system']['domain'] && $pconfig['host'] == '*') {
$input_errors[] = sprintf(
gettext("A wildcard domain override is not supported for this machines domain '%s'."),
$config['system']['domain']
);
}
switch ($pconfig['rr']) {
case 'A': /* also: AAAA */
$reqdfields = explode(" ", "ip");