diff options
author | Renato Botelho <garga@FreeBSD.org> | 2014-02-17 12:19:41 -0300 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2014-02-17 12:20:34 -0300 |
commit | 838e1f6342b42c52e21d11942e35561c25194c1d (patch) | |
tree | 0e364c9ef1fa8f1d4f4057ecfd82c85691c4eea3 /usr/local | |
parent | b67ec10c72c5f24639e72c9168e0f7e238f57b06 (diff) | |
download | pfsense-838e1f6342b42c52e21d11942e35561c25194c1d.zip pfsense-838e1f6342b42c52e21d11942e35561c25194c1d.tar.gz |
Use correct parameter (bootfile-url) to configure netboot on DHCPdv6, it fixes #3421
Diffstat (limited to 'usr/local')
-rw-r--r-- | usr/local/www/services_dhcpv6.php | 27 |
1 files changed, 7 insertions, 20 deletions
diff --git a/usr/local/www/services_dhcpv6.php b/usr/local/www/services_dhcpv6.php index 45f99ee..d1918e8 100644 --- a/usr/local/www/services_dhcpv6.php +++ b/usr/local/www/services_dhcpv6.php @@ -114,9 +114,7 @@ if (is_array($config['dhcpdv6'][$if])){ $pconfig['tftp'] = $config['dhcpdv6'][$if]['tftp']; $pconfig['ldap'] = $config['dhcpdv6'][$if]['ldap']; $pconfig['netboot'] = isset($config['dhcpdv6'][$if]['netboot']); - $pconfig['nextserver'] = $config['dhcpdv6'][$if]['nextserver']; - $pconfig['filename'] = $config['dhcpdv6'][$if]['filename']; - $pconfig['rootpath'] = $config['dhcpdv6'][$if]['rootpath']; + $pconfig['bootfile_url'] = $config['dhcpdv6'][$if]['bootfile_url']; $pconfig['netmask'] = $config['dhcpdv6'][$if]['netmask']; $pconfig['numberoptions'] = $config['dhcpdv6'][$if]['numberoptions']; $pconfig['dhcpv6leaseinlocaltime'] = $config['dhcpdv6'][$if]['dhcpv6leaseinlocaltime']; @@ -208,8 +206,8 @@ if ($_POST) { $input_errors[] = gettext("A valid domain name must be specified for the DNS domain."); if ($_POST['tftp'] && !is_ipaddr($_POST['tftp']) && !is_domain($_POST['tftp']) && !is_URL($_POST['tftp'])) $input_errors[] = gettext("A valid IPv6 address or hostname must be specified for the TFTP server."); - if (($_POST['nextserver'] && !is_ipaddrv6($_POST['nextserver']))) - $input_errors[] = gettext("A valid IPv6 address must be specified for the network boot server."); + if (($_POST['bootfile_url'] && !is_URL($_POST['bootfile_url']))) + $input_errors[] = gettext("A valid URL must be specified for the network bootfile."); // Disallow a range that includes the virtualip if (is_array($config['virtualip']['vip'])) { @@ -305,9 +303,7 @@ if ($_POST) { $config['dhcpdv6'][$if]['tftp'] = $_POST['tftp']; $config['dhcpdv6'][$if]['ldap'] = $_POST['ldap']; $config['dhcpdv6'][$if]['netboot'] = ($_POST['netboot']) ? true : false; - $config['dhcpdv6'][$if]['nextserver'] = $_POST['nextserver']; - $config['dhcpdv6'][$if]['filename'] = $_POST['filename']; - $config['dhcpdv6'][$if]['rootpath'] = $_POST['rootpath']; + $config['dhcpdv6'][$if]['bootfile_url'] = $_POST['bootfile_url']; $config['dhcpdv6'][$if]['dhcpv6leaseinlocaltime'] = $_POST['dhcpv6leaseinlocaltime']; // Handle the custom options rowhelper @@ -402,9 +398,7 @@ include("head.inc"); //document.iform.tftp.disabled = endis; document.iform.ldap.disabled = endis; document.iform.netboot.disabled = endis; - document.iform.nextserver.disabled = endis; - document.iform.filename.disabled = endis; - document.iform.rootpath.disabled = endis; + document.iform.bootfile_url.disabled = endis; } function show_shownumbervalue() { @@ -733,15 +727,8 @@ display_top_tabs($tab_array); <input valign="middle" type="checkbox" value="yes" name="netboot" id="netboot" <?php if($pconfig['netboot']) echo " checked"; ?>> <b><?=gettext("Enables network booting.");?></b> <p> - <?=gettext("Enter the IP of the"); ?> <b><?=gettext("next-server"); ?></b> - <input name="nextserver" type="text" class="formfld unknown" id="nextserver" size="28" value="<?=htmlspecialchars($pconfig['nextserver']);?>"> - <?=gettext("and the filename");?> - <input name="filename" type="text" class="formfld unknown" id="filename" size="28" value="<?=htmlspecialchars($pconfig['filename']);?>"><br> - <?=gettext("Note: You need both a filename and a boot server configured for this to work!");?> - <p> - <?=gettext("Enter the"); ?> <b><?=gettext("root-path"); ?></b>-<?=gettext("string");?> - <input name="rootpath" type="text" class="formfld unknown" id="rootpath" size="90" value="<?=htmlspecialchars($pconfig['rootpath']);?>"><br> - <?=gettext("Note: string-format: iscsi:(servername):(protocol):(port):(LUN):targetname");?> + <?=gettext("Enter the Bootfile URL");?> + <input name="bootfile_url" type="text" class="formfld unknown" id="bootfile_url" size="28" value="<?=htmlspecialchars($pconfig['bootfile_url']);?>"> </div> </td> </tr> |