From a8cea205d5f9f975ca03ef39e79d18698236cfe2 Mon Sep 17 00:00:00 2001 From: Watson Sato Date: Mon, 13 Feb 2023 17:49:14 +0100 Subject: [PATCH 3/5] Change custom zones check in firewalld_sshd_port_enabled Patch-name: scap-security-guide-0.1.67-firewalld_sshd_port_enabled_tests-PR_10162.patch Patch-status: Change custom zones check in firewalld_sshd_port_enabled --- .../oval/shared.xml | 68 +++++++++++++++---- 1 file changed, 54 insertions(+), 14 deletions(-) diff --git a/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/oval/shared.xml index 4adef2e53f..d7c96665b4 100644 --- a/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/oval/shared.xml @@ -133,9 +133,10 @@ OVAL resources in order to detect and assess only active zone, which are zones with at least one NIC assigned to it. Since it was possible to easily have the list of active zones, it was cumbersome to use that list in other OVAL objects without introduce a high - level of complexity to make sure environments with multiple NICs and multiple zones are - in use. So, in favor of simplicity and readbility it was decided to work with a static - list. It means that, in the future, it is possible this list needs to be updated. --> + level of complexity to ensure proper assessment in environments where multiple NICs and + multiple zones are in use. So, in favor of simplicity and readbility it was decided to + work with a static list. It means that, in the future, it is possible this list needs to + be updated. --> @@ -145,23 +146,62 @@ - + - - - + + + + + + var_firewalld_sshd_port_enabled_custom_zone_files_with_ssh_count + + + + + + + - /etc/firewalld/zones - ^.*\.xml$ - /zone/service[@name='ssh'] + /etc/firewalld/zones + ^.*\.xml$ + /zone/service[@name='ssh'] - - /zone/service[@name='ssh'] - + + + + + + + + + + + + + /etc/firewalld/zones + ^.*\.xml$ +