Firewall/Rules - support tos/dscp matching. validation issue in a002251146 for https://github.com/opnsense/core/issues/6045

This commit is contained in:
Ad Schellevis 2022-09-22 17:12:54 +02:00
parent a002251146
commit 7c0db67577

View File

@ -452,7 +452,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
$input_errors[] = gettext('Priority match must be an integer between 0 and 7.');
}
if (!empty($pconfig['tos']) && !in_array($pconfig['tos'], get_tos_values())) {
if (!empty($pconfig['tos']) && !isset(get_tos_values()[$pconfig['tos']])) {
$input_errors[] = gettext('Match TOS/DSCP value invalid.');
}