mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Allow URLs for TFTP Server (Bug #6634)
is_URL() from util.inc is way too limited for this purpose.
(cherry picked from commit 4838163139)
This commit is contained in:
parent
2d8770b2ce
commit
2e5a481c91
@ -362,8 +362,8 @@ if (isset($_POST['save'])) {
|
||||
if (($_POST['domain'] && !is_domain($_POST['domain']))) {
|
||||
$input_errors[] = gettext("A valid domain name must be specified for the DNS domain.");
|
||||
}
|
||||
if ($_POST['tftp'] && !is_ipaddrv4($_POST['tftp']) && !is_domain($_POST['tftp']) && !is_URL($_POST['tftp'])) {
|
||||
$input_errors[] = gettext("A valid IP address or hostname must be specified for the TFTP server.");
|
||||
f ($_POST['tftp'] && !is_ipaddrv4($_POST['tftp']) && !is_domain($_POST['tftp']) && !filter_var($_POST['tftp'], FILTER_VALIDATE_URL)) {
|
||||
$input_errors[] = gettext("A valid IP address, hostname or URL must be specified for the TFTP server.");
|
||||
}
|
||||
if (($_POST['nextserver'] && !is_ipaddrv4($_POST['nextserver']))) {
|
||||
$input_errors[] = gettext("A valid IP address must be specified for the network boot server.");
|
||||
|
||||
Loading…
Reference in New Issue
Block a user