Project

General

Profile

Actions

Bug #11969

closed

PHP error if no DHCPv6 Relay interfaces are selected

Added by Viktor Gurov 6 months ago. Updated about 1 month ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
DHCP Relay
Target version:
Start date:
05/27/2021
Due date:
% Done:

0%

Estimated time:
Plus Target Version:
22.01
Release Notes:
Default
Affected Version:
2.6.0
Affected Architecture:

Description

How to reproduce:
Unselect all interfaces on the services_dhcpv6_relay.php and uncheck "Enable"
Result:

Crash report details:

PHP Errors:
[27-May-2021 18:11:36 Europe/Moscow] PHP Warning:  implode(): 
Invalid arguments passed in /usr/local/www/services_dhcpv6_relay.php on line 130

It should check `interface` array, see https://github.com/pfsense/pfsense/blob/cf8a0761c5c2ae80b62743d6d476e0fae6f2495e/src/usr/local/www/services_dhcp_relay.php#L115:

        if (isset($_POST['interface']) &&
            is_array($_POST['interface'])) {
            $config['dhcrelay']['interface'] = implode(",",
                $_POST['interface']);
        }


Related issues

Has duplicate Bug #12014: Invalid arguments passed in services_dhcpv6_relay.php on line 116Duplicate06/08/2021

Actions
Actions

Also available in: Atom PDF