Legend or not ;-)

Hi there

Might be a bug or even my stupid thinking about things. But I recognized something strange behavior at my firewalls. There is showing a legend as soon I acivate DNS from provider. If I untick this, there is no legend.

Both firewalls react the same.

with tick

without tick

thx for watching

1 Like

I can confirm this behaviour for the version:

Core-Update 199 Development Build: master/75ecc483

1 Like

Nice find. That is case for bugzilla.

2 Likes

wow. I found a bug. And it’s not even easter :wink:

3 Likes

Thanks for reporting this.

It’s been logged as Bug 13917

Cheers,
A G

2 Likes

The effect was created back in CU140 around 6 years ago.

You only see the legend if the isp dns server(s) are enabled and the number of dns servers listed ( including isp ones) is > 2.

3 Likes

That is right.
The relevant condition should read ( in pseudocode )

if servercount > (use_isp_dns_servers)?2:0 
  print legend
1 Like

No idea what pseudocode is but the simplest thing i would think is to change the ‘on’ to ‘off’ as you can’t edit the isp dns servers as they define them so i suspect there was an error when the code was changed in CU140.

The only problem would be with the dns sources > 2 if you have an isp that has only one dns server. That is the case for my vm ipfire behind my production ipfire as that provides only one dns server.

Okay.
The solution is just to change line 714, file /srv/web/cgi-bin/dns.cgi
from
if (($settings{'USE_ISP_NAMESERVERS'} eq "on") && ($server_amount > 2)) {
to
if ($server_amount > ($settings{'USE_ISP_NAMESERVERS'} eq "on")?2:0) {

This shows the legend with DNS servers defined only.

1 Like

That’s excellent work. Thanks for picking this up. :+1: