Skip to content

Commit

Permalink
Services: Unbound DNS - validate service is offering a properly typed…
Browse files Browse the repository at this point in the history
… "dns_ports" list. closes #6690
  • Loading branch information
AdSchellevis committed Jul 31, 2023
1 parent 40d1569 commit c61ef7a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/opnsense/mvc/app/models/OPNsense/Unbound/Unbound.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function performValidation($validateFullModel = false)
!empty((string)$this->general->enabled)
) {
foreach (json_decode((new Backend())->configdpRun('service list'), true) as $service) {
if (empty($service['dns_ports'])) {
if (empty($service['dns_ports']) || !is_array($service['dns_ports'])) {
continue;
}
if ($service['name'] != 'unbound' && in_array((string)$this->general->port, $service['dns_ports'])) {

This comment has been minimized.

Copy link
@fichtner

fichtner Jul 31, 2023

Member

ironic part: we "verify" all services before we make sure it's not unbound? oO

This comment has been minimized.

Copy link
@fichtner

fichtner Jul 31, 2023

Member

discard, we need to scan all of course

Expand Down

0 comments on commit c61ef7a

Please sign in to comment.