mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Prevent a Fall Back Pool from being selected when the DNS protocol is in use. If one is present in the config, ignore it. Fixes #3300
This commit is contained in:
parent
add913b143
commit
c5d4d97bab
@ -337,7 +337,7 @@ function relayd_configure($kill_first=false) {
|
||||
|
||||
$conf .= " forward to <{$vs_a[$i]['poolname']}> port {$dest_port} {$lbmode} {$check_a[$pools[$vs_a[$i]['poolname']]['monitor']]} \n";
|
||||
|
||||
if (isset($vs_a[$i]['sitedown']) && strlen($vs_a[$i]['sitedown']) > 0)
|
||||
if (isset($vs_a[$i]['sitedown']) && strlen($vs_a[$i]['sitedown']) > 0 && ($vs_a[$i]['relay_protocol'] != 'dns'))
|
||||
$conf .= " forward to <{$vs_a[$i]['sitedown']}> port {$dest_port} {$lbmode} {$check_a[$pools[$vs_a[$i]['poolname']]['monitor']]} \n";
|
||||
$conf .= "}\n";
|
||||
} else {
|
||||
@ -349,7 +349,7 @@ function relayd_configure($kill_first=false) {
|
||||
$conf .= " sticky-address\n";
|
||||
|
||||
/* sitedown MUST use the same port as the primary pool - sucks, but it's a relayd thing */
|
||||
if (isset($vs_a[$i]['sitedown']) && strlen($vs_a[$i]['sitedown']) > 0)
|
||||
if (isset($vs_a[$i]['sitedown']) && strlen($vs_a[$i]['sitedown']) > 0 && ($vs_a[$i]['relay_protocol'] != 'dns'))
|
||||
$conf .= " forward to <{$vs_a[$i]['sitedown']}> port {$dest_port} {$check_a[$pools[$vs_a[$i]['sitedown']]['monitor']]} \n";
|
||||
|
||||
$conf .= "}\n";
|
||||
|
||||
@ -96,6 +96,9 @@ if ($_POST) {
|
||||
else if (is_subnetv4($_POST['ipaddr']) && subnet_size($_POST['ipaddr']) > 64)
|
||||
$input_errors[] = sprintf(gettext("%s is a subnet containing more than 64 IP addresses."), $_POST['ipaddr']);
|
||||
|
||||
if ((strtolower($_POST['relay_protocol']) == "dns") && !empty($_POST['sitedown']))
|
||||
$input_errors[] = gettext("You cannot select a Fall Back Pool when using the DNS relay protocol.");
|
||||
|
||||
if (!$input_errors) {
|
||||
$vsent = array();
|
||||
if(isset($id) && $a_vs[$id])
|
||||
@ -232,7 +235,8 @@ include("head.inc");
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
<br><b><?=gettext("NOTE:"); ?></b> <?=gettext("This is the server that clients will be redirected to if *ALL* servers in the pool are offline."); ?>
|
||||
<br><?=gettext("The server pool to which clients will be redirected if *ALL* servers in the Virtual Server Pool are offline."); ?>
|
||||
<br><?=gettext("This option is NOT compatible with the DNS relay protocol."); ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user