WillyXJ / facileManager

A modular suite of web apps built with the sysadmin in mind.
www.facilemanager.com
GNU General Public License v2.0
84 stars 37 forks source link

[BUG] [] operator not supported for strings[] in Edit Zone #622

Closed imyller closed 2 months ago

imyller commented 3 months ago

fM Version : 4.6.1 fmDNS Version : 6.0.4

Debian 12 (Bookworm) PHP 8.2.7 Apache 2.4.57

In raising this issue, I confirm the following (please check boxes, eg [X]):


(BUG | ISSUE) Expected Behavior:

When editing zone configuration the edits are saved.

(BUG | ISSUE) Actual Behavior:

Fatal error: Uncaught Error: [] operator not supported for strings in /opt/facileManager/server/fm-modules/fmDNS/functions.php:694 Stack trace: #0 /opt/facileManager/server/fm-modules/fmDNS/classes/class_zones.php(461): getZoneServers() #1 /opt/facileManager/server/fm-modules/fmDNS/pages/zones.php(61): fm_dns_zones->update() #2 /opt/facileManager/server/fm-modules/fmDNS/pages/zones-forward.php(27): include('...') #3 /opt/facileManager/server/index.php(57): include('...') #4 {main} thrown in /opt/facileManager/server/fm-modules/fmDNS/functions.php on line 694

Click Save:

editzonerr

Results in:

editzoneerr2

(BUG | ISSUE) Steps to reproduce:

NOTE: I am not sure if the server group assignment is required to trigger this bug, but I was able to get the issue to appear after Save in Edit Zone worked first when changing zone's DNS server assignment from All servers to a newly created server group and then failed for subsequent edits.

internethering commented 3 months ago

workaround: change fm-modules/fmDNS/functions.php line 677: $serial_no = array();

WillyXJ commented 2 months ago

This is now fixed in fmDNS 6.0.5 and later.