interfaces: nothing requires all vips to be regenerated #5540

The side effect from this may be that VIPs disappear from disabled
interfaces which is how it should have been.

Furthermore, remove the configuration of vips from rc.newwanip which
was added for unknown reasons in pfSense a long time ago and got also
copied to rc.newwanipv6 for us during cleanups but never in pfSense.
Especially since we removed find_interface_*() function family we never
risk reading an alias as a primary address and for all intents and
purposes an alias should never appear from an interface except it was
stripped in error by faulty code.  Win-win really.  ;)
This commit is contained in:
Franco Fichtner 2022-02-13 10:50:05 +01:00
parent f2507208fe
commit 24f100366f
3 changed files with 2 additions and 6 deletions

View File

@ -1388,7 +1388,7 @@ function interface_proxyarp_configure($interface = '')
}
}
function interfaces_vips_configure($verbose = false, $interface = '')
function interfaces_vips_configure($verbose = false, $interface = 'wan')
{
global $config;
@ -1400,7 +1400,7 @@ function interfaces_vips_configure($verbose = false, $interface = '')
$anyproxyarp = false;
foreach ($config['virtualip']['vip'] as $vip) {
if (empty($interface) || $vip['interface'] == $interface) {
if ($vip['interface'] == $interface) {
switch ($vip['mode']) {
case 'proxyarp':
$anyproxyarp = true;

View File

@ -75,8 +75,6 @@ if (!is_ipaddr($ip) && substr($interface_real, 0, 4) != 'ovpn') {
return;
}
interfaces_vips_configure(false, $interface);
$gres = link_interface_to_gre($interface);
foreach ($gres as $gre) {
_interfaces_gre_configure($gre);

View File

@ -75,8 +75,6 @@ if (!is_ipaddr($ip) && substr($interface_real, 0, 4) != 'ovpn') {
return;
}
interfaces_vips_configure(false, $interface);
if (count(link_interface_to_track6($interface, true))) {
plugins_configure('dhcp', false, array('inet6'));
}