summaryrefslogtreecommitdiffstats
path: root/usr/local/www/firewall_virtual_ip_edit.php
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2010-08-26 16:37:38 +0000
committerErmal <eri@pfsense.org>2010-08-26 16:38:12 +0000
commite19b7d1ea849f40f1de194cadeefb3c289812442 (patch)
tree3cca6a4f1865575e039bb63c63a1084c8ff6486a /usr/local/www/firewall_virtual_ip_edit.php
parent1bd4b4dcd97c2c77aa8900e3113d5050d44af469 (diff)
downloadpfsense-e19b7d1ea849f40f1de194cadeefb3c289812442.zip
pfsense-e19b7d1ea849f40f1de194cadeefb3c289812442.tar.gz
Allow carp interfaces to sit on top of aliases. Also add safety belts to ipalias deletion for this to avoid breakage. Trigered-by: http://forum.pfsense.org/index.php/topic,27834.0.html
Diffstat (limited to 'usr/local/www/firewall_virtual_ip_edit.php')
-rwxr-xr-xusr/local/www/firewall_virtual_ip_edit.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr/local/www/firewall_virtual_ip_edit.php b/usr/local/www/firewall_virtual_ip_edit.php
index ffddef7..bdad11a 100755
--- a/usr/local/www/firewall_virtual_ip_edit.php
+++ b/usr/local/www/firewall_virtual_ip_edit.php
@@ -143,7 +143,7 @@ if ($_POST) {
$parent_ip = get_interface_ip($_POST['interface']);
$parent_sn = get_interface_subnet($_POST['interface']);
- if (!ip_in_subnet($_POST['subnet'], gen_subnet($parent_ip, $parent_sn) . "/" . $parent_sn)) {
+ if (!ip_in_subnet($_POST['subnet'], gen_subnet($parent_ip, $parent_sn) . "/" . $parent_sn) && !ip_in_interface_alias_subnet($_POST['interface'], $_POST['subnet'])) {
$cannot_find = $_POST['subnet'] . "/" . $_POST['subnet_bits'] ;
$input_errors[] = sprintf(gettext("Sorry, we could not locate an interface with a matching subnet for %s. Please add an IP alias in this subnet on this interface."),$cannot_find);
} else if ($parent_sn != $_POST['subnet_bits'])
OpenPOWER on IntegriCloud