Blame SOURCES/scap-security-guide-0.1.67-pwhistory_control-PR_10175.patch

e71555
From 13eda45e00e4a339227522c5954c1aec7f49f122 Mon Sep 17 00:00:00 2001
e71555
From: Watson Sato <wsato@redhat.com>
e71555
Date: Wed, 15 Feb 2023 16:25:47 +0100
e71555
Subject: [PATCH 5/6] Accept required and requisite control flag for
e71555
 pam_pwhistory
e71555
e71555
Patch-name: scap-security-guide-0.1.67-pwhistory_control-PR_10175.patch
e71555
Patch-status: Accept required and requisite control flag for pam_pwhistory
e71555
---
e71555
 controls/cis_rhel8.yml                                        | 2 +-
e71555
 controls/cis_rhel9.yml                                        | 2 +-
e71555
 controls/srg_gpos/SRG-OS-000077-GPOS-00045.yml                | 2 +-
e71555
 .../rule.yml                                                  | 4 ++++
e71555
 .../var_password_pam_remember_control_flag.var                | 1 +
e71555
 products/rhel8/profiles/stig.profile                          | 2 +-
e71555
 tests/data/profile_stability/rhel8/stig.profile               | 2 +-
e71555
 tests/data/profile_stability/rhel8/stig_gui.profile           | 2 +-
e71555
 8 files changed, 11 insertions(+), 6 deletions(-)
e71555
e71555
diff --git a/controls/cis_rhel8.yml b/controls/cis_rhel8.yml
e71555
index c0406f97b8..efc53d03fd 100644
e71555
--- a/controls/cis_rhel8.yml
e71555
+++ b/controls/cis_rhel8.yml
e71555
@@ -2267,7 +2267,7 @@ controls:
e71555
     rules:
e71555
       - accounts_password_pam_pwhistory_remember_password_auth
e71555
       - accounts_password_pam_pwhistory_remember_system_auth
e71555
-      - var_password_pam_remember_control_flag=requisite
e71555
+      - var_password_pam_remember_control_flag=requisite_or_required
e71555
       - var_password_pam_remember=5
e71555
 
e71555
   - id: 5.5.4
e71555
diff --git a/controls/cis_rhel9.yml b/controls/cis_rhel9.yml
e71555
index 7299a39528..30f7e8d182 100644
e71555
--- a/controls/cis_rhel9.yml
e71555
+++ b/controls/cis_rhel9.yml
e71555
@@ -2112,7 +2112,7 @@ controls:
e71555
     rules:
e71555
       - accounts_password_pam_pwhistory_remember_password_auth
e71555
       - accounts_password_pam_pwhistory_remember_system_auth
e71555
-      - var_password_pam_remember_control_flag=requisite
e71555
+      - var_password_pam_remember_control_flag=requisite_or_required
e71555
       - var_password_pam_remember=5
e71555
 
e71555
   - id: 5.5.4
e71555
diff --git a/controls/srg_gpos/SRG-OS-000077-GPOS-00045.yml b/controls/srg_gpos/SRG-OS-000077-GPOS-00045.yml
e71555
index 1e8286a4a4..b02b7da419 100644
e71555
--- a/controls/srg_gpos/SRG-OS-000077-GPOS-00045.yml
e71555
+++ b/controls/srg_gpos/SRG-OS-000077-GPOS-00045.yml
e71555
@@ -5,7 +5,7 @@ controls:
e71555
         title: {{{ full_name }}} must prohibit password reuse for a minimum of five generations.
e71555
         rules:
e71555
             - var_password_pam_remember=5
e71555
-            - var_password_pam_remember_control_flag=requisite
e71555
+            - var_password_pam_remember_control_flag=requisite_or_required
e71555
             - accounts_password_pam_pwhistory_remember_password_auth
e71555
             - accounts_password_pam_pwhistory_remember_system_auth
e71555
         status: automated
e71555
diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember_password_auth/rule.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember_password_auth/rule.yml
e71555
index c549de2e96..d2b220ef9f 100644
e71555
--- a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember_password_auth/rule.yml
e71555
+++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember_password_auth/rule.yml
e71555
@@ -129,3 +129,7 @@ warnings:
e71555
        Newer versions of <tt>authselect</tt> contain an authselect feature to easily and properly
e71555
        enable <tt>pam_pwhistory.so</tt> module. If this feature is not yet available in your
e71555
        system, an authselect custom profile must be used to avoid integrity issues in PAM files.
e71555
+       If a custom profile was created and used in the system before this authselect feature was
e71555
+       available, the new feature can't be used with this custom profile and the
e71555
+       remediation will fail. In this case, the custom profile should be recreated or manually
e71555
+       updated.
e71555
diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/var_password_pam_remember_control_flag.var b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/var_password_pam_remember_control_flag.var
e71555
index 8f01007550..1959936c04 100644
e71555
--- a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/var_password_pam_remember_control_flag.var
e71555
+++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/var_password_pam_remember_control_flag.var
e71555
@@ -20,4 +20,5 @@ options:
e71555
     "sufficient": "sufficient"
e71555
     "binding": "binding"
e71555
     "ol8": "required,requisite"
e71555
+    "requisite_or_required": "requisite,required"
e71555
     default: "requisite"
e71555
diff --git a/products/rhel8/profiles/stig.profile b/products/rhel8/profiles/stig.profile
e71555
index 8c64868619..a3f7dc9720 100644
e71555
--- a/products/rhel8/profiles/stig.profile
e71555
+++ b/products/rhel8/profiles/stig.profile
e71555
@@ -37,7 +37,7 @@ selections:
e71555
     - var_accounts_minimum_age_login_defs=1
e71555
     - var_accounts_max_concurrent_login_sessions=10
e71555
     - var_password_pam_remember=5
e71555
-    - var_password_pam_remember_control_flag=requisite
e71555
+    - var_password_pam_remember_control_flag=requisite_or_required
e71555
     - var_selinux_state=enforcing
e71555
     - var_selinux_policy_name=targeted
e71555
     - var_password_pam_unix_rounds=5000
e71555
diff --git a/tests/data/profile_stability/rhel8/stig.profile b/tests/data/profile_stability/rhel8/stig.profile
e71555
index 6970a32b4f..5d694c6ae1 100644
e71555
--- a/tests/data/profile_stability/rhel8/stig.profile
e71555
+++ b/tests/data/profile_stability/rhel8/stig.profile
e71555
@@ -433,7 +433,7 @@ selections:
e71555
 - var_accounts_minimum_age_login_defs=1
e71555
 - var_accounts_max_concurrent_login_sessions=10
e71555
 - var_password_pam_remember=5
e71555
-- var_password_pam_remember_control_flag=requisite
e71555
+- var_password_pam_remember_control_flag=requisite_or_required
e71555
 - var_selinux_state=enforcing
e71555
 - var_selinux_policy_name=targeted
e71555
 - var_password_pam_unix_rounds=5000
e71555
diff --git a/tests/data/profile_stability/rhel8/stig_gui.profile b/tests/data/profile_stability/rhel8/stig_gui.profile
e71555
index 314f14e4f6..e165525b90 100644
e71555
--- a/tests/data/profile_stability/rhel8/stig_gui.profile
e71555
+++ b/tests/data/profile_stability/rhel8/stig_gui.profile
e71555
@@ -441,7 +441,7 @@ selections:
e71555
 - var_accounts_minimum_age_login_defs=1
e71555
 - var_accounts_max_concurrent_login_sessions=10
e71555
 - var_password_pam_remember=5
e71555
-- var_password_pam_remember_control_flag=requisite
e71555
+- var_password_pam_remember_control_flag=requisite_or_required
e71555
 - var_selinux_state=enforcing
e71555
 - var_selinux_policy_name=targeted
e71555
 - var_password_pam_unix_rounds=5000
e71555
-- 
e71555
2.39.1
e71555