diff options
author | Ermal <eri@pfsense.org> | 2014-11-10 15:00:30 +0100 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2014-11-10 15:00:30 +0100 |
commit | 5063f1df931b2887e2da2560c73fef954656e4e8 (patch) | |
tree | 6dc55e05e7936c41238a135461fdeb4dd53bc410 /usr/local | |
parent | 9c97df267fd4f3c6c638466a54482e3d2c1b2986 (diff) | |
download | pfsense-5063f1df931b2887e2da2560c73fef954656e4e8.zip pfsense-5063f1df931b2887e2da2560c73fef954656e4e8.tar.gz |
Ticket #3967. Allow to have carp as parent of ipaliases - continued
Diffstat (limited to 'usr/local')
-rw-r--r-- | usr/local/www/carp_status.php | 4 | ||||
-rw-r--r-- | usr/local/www/firewall_virtual_ip.php | 6 |
2 files changed, 10 insertions, 0 deletions
diff --git a/usr/local/www/carp_status.php b/usr/local/www/carp_status.php index 869cc1b..5701ad7 100644 --- a/usr/local/www/carp_status.php +++ b/usr/local/www/carp_status.php @@ -81,6 +81,10 @@ if($_POST['disablecarp'] <> "") { sleep(1); break; } + case 'ipalias': + if (strpos($vip['interface'], '_vip')) + interface_ipalias_configure($vip); + break; } } interfaces_sync_setup(); 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) { |