Project

General

Profile

Bug #152

Deleting a VIP leaves <vip/> in config.xml

Added by Chris Buechler almost 10 years ago. Updated over 9 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
11/15/2009
Due date:
% Done:

0%

Estimated time:
Affected Version:
Affected Architecture:

Description

Each deleted VIP leaves <vip/> in config.xml. For example after deleting 3 VIPs:

&lt;virtualip&gt;
&lt;vip/&gt;
&lt;vip/&gt;
&lt;vip/&gt;
nat_interface.jpg (29.2 KB) nat_interface.jpg IP list with empty vip elements in config.xml Pierre POMES, 11/30/2009 10:42 PM

Associated revisions

Revision ed65eb04 (diff)
Added by Ermal Luçi over 9 years ago

Ticket #152. Hoepfully fix creation of empty vip entries in the config when deleting them. Probably more checks need to be done by consumers.

History

#1 Updated by Scott Ullrich almost 10 years ago

  • Target version changed from 2.0 to 3

#2 Updated by Pierre POMES almost 10 years ago

Target has been changed to 3.0, however, on the NAT screen, the list of available addresses contains empty elements (see screenshot)

So maybe a new ticket could be created to fix code in /etc/inc/util.inc in the function used to build the addresses list ?

#3 Updated by Chris Buechler almost 10 years ago

The target was changed because this was caused by the new XML parser code that's been reverted, so this is no longer an issue. ("Affected version" isn't accurate in this case, maybe we need a "none" for unusual cases like this)

Pierre - I suspect you're seeing something different there, at least when I tested this after the XML parser was reverted, it no longer did this.

#4 Updated by Pierre POMES almost 10 years ago

Hum, I tried a 2009/12/01 snapshot (pfSense-Full-Update-2.0-ALPHA-ALPHA-20091201-1245.tgz), here are my results:
- I cleaned up all my <vip/> entries in config.xml, the "External address" field in NAT (port forward) is ok
- I defined a carp interface, and I deleted it. My config.xml does contain an empty "<vip/>"
- The "External address" field in NAT (port forward) shows an empty address "()" in the list.

I had a quick look in the code, a loop on $config['virtualip']['vip'] is done to fill up "option" HTML tags, and use $config['virtualip']['vip']['subnet'] without no check: so if config.xml contains an empty <vip/>, an empty "option" html tag will be generated.

(/usr/local/www/firewall_nat_edit.php, line 322)

Pierre

#5 Updated by Ermal Luçi over 9 years ago

  • Status changed from New to Feedback

#6 Updated by Chris Buechler over 9 years ago

  • Status changed from Feedback to Closed
  • Target version deleted (3)
  • Affected Version deleted (2.0)

Also available in: Atom PDF