Commit fb555fa
committed
Fix no_empty_passwords remediation for RHCOS 9
On RHCOS 9, /usr/bin/authselect exists but PAM files are not managed
by authselect. Using authselect rewrites the PAM stack with RHEL 8
era templates (including pam_fprintd.so and a 2018 authselect header)
that don't match the actual RHCOS 9 PAM configuration.
After applying the authselect-based remediation, the compliance scan
still reports FAIL because the OVAL check doesn't recognize the
RHEL 8 PAM template as a valid remediated state.
Fix: Add an rhcos-specific branch that uses direct sed (via
bash_remove_pam_module_option) to surgically remove nullok from the
existing PAM files, preserving the RHCOS 9 PAM stack.
Verified on OCP 4.22 (RHCOS 9.8): no_empty_passwords flips from
FAIL to PASS with the direct sed approach.1 parent 181f937 commit fb555fa
1 file changed
Lines changed: 12 additions & 1 deletion
File tree
- linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/bash
Lines changed: 12 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
41 | 52 | | |
42 | 53 | | |
43 | 54 | | |
| |||
0 commit comments