diff options
author | Darren Embry <dse@webonastick.com> | 2012-04-05 14:35:54 -0400 |
---|---|---|
committer | Darren Embry <dse@webonastick.com> | 2012-04-05 14:36:50 -0400 |
commit | 01ed452e3253f2883aed00b710d6c5e7c5420305 (patch) | |
tree | bd8f60638ea5ca4587d59787069c56eaed06ddd5 /usr | |
parent | 99f6b2a9a2e003304f5d197652ca0f1fe48de0f3 (diff) | |
download | pfsense-01ed452e3253f2883aed00b710d6c5e7c5420305.zip pfsense-01ed452e3253f2883aed00b710d6c5e7c5420305.tar.gz |
Load Balancer: allow port aliases in Pools and Virtual Servers. (PEV-394754)
Diffstat (limited to 'usr')
-rwxr-xr-x | usr/local/www/load_balancer_pool_edit.php | 9 | ||||
-rwxr-xr-x | usr/local/www/load_balancer_virtual_server_edit.php | 5 |
2 files changed, 9 insertions, 5 deletions
diff --git a/usr/local/www/load_balancer_pool_edit.php b/usr/local/www/load_balancer_pool_edit.php index 81a548c..078b61a 100755 --- a/usr/local/www/load_balancer_pool_edit.php +++ b/usr/local/www/load_balancer_pool_edit.php @@ -85,8 +85,8 @@ if ($_POST) { if (strpos($_POST['name'], " ") !== false) $input_errors[] = gettext("You cannot use spaces in the 'name' field."); - if (!is_port($_POST['port'])) - $input_errors[] = gettext("The port must be an integer between 1 and 65535."); + if (!is_portoralias($_POST['port'])) + $input_errors[] = gettext("The port must be an integer between 1 and 65535, or a port alias."); // May as well use is_port as we want a positive integer and such. if (!empty($_POST['retry']) && !is_port($_POST['retry'])) @@ -209,7 +209,10 @@ function clearcombo(){ <td width="22%" valign="top" id="monitorport_text" class="vncellreq"><?=gettext("Port"); ?></td> <td width="78%" class="vtable" colspan="2"> <input name="port" type="text" <?if(isset($pconfig['port'])) echo "value=\"{$pconfig['port']}\"";?> size="16" maxlength="16"><br> - <div id="monitorport_desc"><?=gettext("This is the port your servers are listening on."); ?></div> + <div id="monitorport_desc"> + <?=gettext("This is the port your servers are listening on."); ?><br /> + <?=gettext("You may also specify a port alias listed in Firewall -> Interfaces here."); ?> + </div> </td> </tr> <tr align="left"> diff --git a/usr/local/www/load_balancer_virtual_server_edit.php b/usr/local/www/load_balancer_virtual_server_edit.php index ff59fd9..046e18c 100755 --- a/usr/local/www/load_balancer_virtual_server_edit.php +++ b/usr/local/www/load_balancer_virtual_server_edit.php @@ -88,8 +88,8 @@ if ($_POST) { if (strpos($_POST['name'], " ") !== false) $input_errors[] = gettext("You cannot use spaces in the 'name' field."); - if (!is_port($_POST['port'])) - $input_errors[] = gettext("The port must be an integer between 1 and 65535."); + if (!is_portoralias($_POST['port'])) + $input_errors[] = gettext("The port must be an integer between 1 and 65535, or a port alias."); if (!is_ipaddr($_POST['ipaddr']) && !is_subnetv4($_POST['ipaddr'])) $input_errors[] = sprintf(gettext("%s is not a valid IP address or IPv4 subnet."), $_POST['ipaddr']); @@ -205,6 +205,7 @@ jQuery(document).ready( function() { <td width="78%" class="vtable" colspan="2"> <input name="port" type="text" <?if(isset($pconfig['port'])) echo "value=\"{$pconfig['port']}\"";?> size="16" maxlength="16"> <br><?=gettext("This is the port that the clients will connect to. All connections to this port will be forwarded to the pool cluster."); ?> + <br><?=gettext("You may also specify a port alias listed in Firewall -> Interfaces here."); ?> </td> </tr> <tr align="left"> |