After upgrading IPFire to the latest Core Update, the WIO addon version 1.3.2-19 is no longer working correctly. Before the update, WIO was working without issues. The problem appears when configuring WIO with an IP address that is not assigned to any local IPFire interface (for example an external public IP address). When the CGI page reaches that entry, the page stops loading and is displayed incomplete. Local IP addresses are handled correctly. The Apache error log shows: ``` Undefined subroutine &General::GetDyndnsRedIP called at /srv/web/ipfire/cgi-bin/wio.cgi line 1166 ``` After investigating, I found that the function exists in: ``` /var/ipfire/http-client-functions.pl ``` as: ``` sub GetDyndnsRedIP ``` but WIO tries to call it from the old `General` namespace. After fixing this part locally, another error appears: ``` Undefined subroutine &General::ipcidr2msk called at /srv/web/ipfire/cgi-bin/wio.cgi line 1586 ``` The issue seems to be caused by incompatibilities between WIO 1.3.2-19 and the current IPFire Perl functions. I can provide the original `wio.cgi` file and screenshots of the broken page if needed. System information: * IPFire Core Update: [IPFire 2.29 - Core-Update 203] * Architecture: [x86_64/aarch64] * WIO version: 1.3.2-19 https://community.ipfire.org/t/wio-1-3-2-19-not-compatible-with-latest-ipfire-versions-cgi-errors-with-public-ip-addresses/16050 Thank you.
The Apache error log shows: ``` Undefined subroutine &General::GetDyndnsRedIP called at /srv/web/ipfire/cgi-bin/wio.cgi line 1166 ``` After investigating, I found that the function exists in: ``` /var/ipfire/http-client-functions.pl ``` as: ``` sub GetDyndnsRedIP ``` GetDyndnsRedIP has always been in http-client-functions.pl The line in your wio.cgi must have been edited accidentally with a typo. Line 1167 should read $bgcolor = ( &General::DyndnsServiceSync (&HTTPClient::GetDyndnsRedIP,$temp[1],$temp[2]) ? "$Header::colourgreen" : "$Header::colourred" );
ipcidr2msk was removed from general-functions.pl I am trying to duplicate this effect myself but haven't been abler to do it yet. You mentioned that you got the error when you tried to add a client with a public IP. I just tried that and the screen was displayed with no ptoblem. Can you provide a screenshot of the add client entry you make so I can try and duplicate it?
Created attachment 1741 [details] Screenshot windows I entered that IP address, which isn't listed in the ipfire interfaces. As you can see, the page is cut off right after that.
I reinstalled the add-ons after first clearing the cache: /opt/pakfire/db/meta /var/cache/pakfire Nothing happened.
Created attachment 1742 [details] Ip Random
Created attachment 1743 [details] Ip Range Interface
With the following changes to the CGI, everything is OK. if ( $temp[7] eq "on" ) { $bgcolor = "$Header::colourgreen"; } else { $bgcolor = "blue"; } my ($cidrip, $cidrmask) = split(/\//, $ovpnccdconfhash{$key}[1]); my $mask = pack("N", (0xffffffff << (32-$cidrmask)) & 0xffffffff); my $netmask = join(".", unpack("C4", $mask)); my $convertip = "$cidrip/$netmask";
Created attachment 1744 [details] CGI Modific