webguiport is managed in system_advanced_admin.php these days, not here in system.php. This validation is never executed, so might a well clean up old unused code.
What a pain this was. The user can blank out a DNS server from a position in the middle of the list. e.g. they had all 4 entries previously filled, and then they blank out DNS server #3. The way the DNS servers are stored in the config, they are just the defined ones in an "un-indexed" array. So actually entries 1, 2 and 4 on the screen become 1st, 2nd and 3rd in the config. The selected gateways for 1, 2 and 4 then have to end up in positions 1, 2 and 3 to match the stored DNS servers.
This fixes all that up, as well as allowing the user to leave a gateway selected against a blanked-out DNS server entry - in that case the whole entry is "removed/ignored".
The "local" search domain signifies to local hosts that are running
mDNS (bonjour or avahi) that mDNS is to be used to look up local hosts
instead of doing a normal DNS query to the server listed in
/etc/resolv.conf on the local host.
Also, hosts running bonjour or avahi can not ping or reach *any* other
host by name if it is not running some mDNS implementation.
Essentially, if DHCP tells the local host that it's search domain is
"local" then hosts running mDNS will not query the pfsense DNS server
for any local lan DNS lookups.
See here on apple's website:
http://support.apple.com/kb/TA20999?viewlocale=en_US
Quote from above link:
"To indicate that the name should be looked up using local multicast
instead of a standard DNS query, all Bonjour host names end with the
extension ".local."
This function can sleep till the resource is free and can help find not well behaving code.
* Remove most of the config_lock/config_unlock logics on the whole scripts/pages it is an abuse of this.
If any sybsytem wants to lock can do so with its own lock.
* Lock the config when doing a filter reload to avoid parallell recursion on this function, since it is not reentrant.
This compenstates for the removal of lock aquiring from the scripts/pages.
* config_lock/config_unlock are now compate shims that do nothing. They are preserved since packages 'abuse' them too.