summaryrefslogtreecommitdiffstats
path: root/usr/local/www/firewall_virtual_ip.php
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2014-11-10 15:00:30 +0100
committerErmal <eri@pfsense.org>2014-11-10 15:00:30 +0100
commit5063f1df931b2887e2da2560c73fef954656e4e8 (patch)
tree6dc55e05e7936c41238a135461fdeb4dd53bc410 /usr/local/www/firewall_virtual_ip.php
parent9c97df267fd4f3c6c638466a54482e3d2c1b2986 (diff)
downloadpfsense-5063f1df931b2887e2da2560c73fef954656e4e8.zip
pfsense-5063f1df931b2887e2da2560c73fef954656e4e8.tar.gz
Ticket #3967. Allow to have carp as parent of ipaliases - continued
Diffstat (limited to 'usr/local/www/firewall_virtual_ip.php')
-rw-r--r--usr/local/www/firewall_virtual_ip.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/usr/local/www/firewall_virtual_ip.php b/usr/local/www/firewall_virtual_ip.php
index f4aa0d3..f3703f9 100644
--- a/usr/local/www/firewall_virtual_ip.php
+++ b/usr/local/www/firewall_virtual_ip.php
@@ -162,6 +162,12 @@ if ($_GET['act'] == "del") {
if ($found_carp === true && $found_other_alias === false && $found_if === false)
$input_errors[] = gettext("This entry cannot be deleted because it is still referenced by a CARP IP with the description") . " {$vip['descr']}.";
+ } else if ($a_vip[$_GET['id']]['mode'] == "carp") {
+ $vipiface = "{$a_vip[$_GET['id']]['interface']}_vip{$a_vip[$_GET['id']]['vhid']}";
+ foreach ($a_vip as $vip) {
+ if ($vipiface == $vip['interface'] && $vip['mode'] == "ipalias")
+ $input_errors[] = gettext("This entry cannot be deleted because it is still referenced by an IP alias entry with the description") . " {$vip['descr']}.";
+ }
}
if (!$input_errors) {
OpenPOWER on IntegriCloud