diff options
author | sullrich <sullrich@pfsense.org> | 2009-11-28 18:38:01 -0500 |
---|---|---|
committer | sullrich <sullrich@pfsense.org> | 2009-11-28 18:38:01 -0500 |
commit | 03fdfdd652b86da67eb44235f67a75e90fc9dfea (patch) | |
tree | 0dc0554a26e72450825663325887f50dfc7edf02 /usr/local/www | |
parent | 07a3b40b0bf931542fd53a48c692594a346b7577 (diff) | |
download | pfsense-03fdfdd652b86da67eb44235f67a75e90fc9dfea.zip pfsense-03fdfdd652b86da67eb44235f67a75e90fc9dfea.tar.gz |
Verify carp VHIDS no matter what and compare to current id if needed Resolves #189
Diffstat (limited to 'usr/local/www')
-rwxr-xr-x | usr/local/www/firewall_virtual_ip_edit.php | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/usr/local/www/firewall_virtual_ip_edit.php b/usr/local/www/firewall_virtual_ip_edit.php index 851c92b..c388842 100755 --- a/usr/local/www/firewall_virtual_ip_edit.php +++ b/usr/local/www/firewall_virtual_ip_edit.php @@ -127,14 +127,12 @@ if ($_POST) { * on one of our interfaces (wan, lan optX) */ if ($_POST['mode'] == "carp" or $_POST['mode'] == "carpdev-dhcp") { - if(!$id) { - /* verify against reusage of vhids */ - $idtracker=0; - foreach($config['virtualip']['vip'] as $vip) { - if($vip['vhid'] == $_POST['vhid'] and $idtracker <> $id) - $input_errors[] = "VHID {$_POST['vhid']} is already in use. Pick a unique number."; - $idtracker++; - } + /* verify against reusage of vhids */ + $idtracker = 0; + foreach($config['virtualip']['vip'] as $vip) { + if($vip['vhid'] == $_POST['vhid'] and $idtracker <> $id) + $input_errors[] = "VHID {$_POST['vhid']} is already in use. Pick a unique number."; + $idtracker++; } if($_POST['password'] == "") $input_errors[] = "You must specify a CARP password that is shared between the two VHID members."; |