You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The code to address V-230274, "RHEL 8 must implement certificate status checking for multifactor authentication." is placed in the incorrect section of the sssd.conf file in some situations.
This section of the fix-cat2.yml attempts to enforce the STIG V-230274 finding using the ansible.builtin.lineinfile: module:
If the certificate_verification line is missing from the [sssd] section, or is missing "ocsp_dgst=sha1", ask the administrator to indicate what type of multifactor authentication is being utilized and how the system implements certificate status checking. If there is no evidence of certificate status checking being used, this is a finding.
(Emphasis mine.)
The lineinfile: module will only ensure the line is in the file, but it does not account for which section of this INI formatted file it must reside. This has bit me on a few occasions when the sections of the sssd.conf file are rearranged.
If we can use the community.general.ini_file: module, this section can be rewritten to address this issue:
Since the state: present entries only need the section, the ini_file: parameter for section: is omitted if the with_items: don't have a section (and conveniently those are only state: absent so should still work regardless of the section the value appears.
(I apologize if there are errors in the code, or corner cases it doesn't address - I'm not able to execute this on a test system, but this has bit us in some of our test configurations and I wanted to log this issue for visibility.)
The text was updated successfully, but these errors were encountered:
Brilliant thank you for this issue. You have summarised the issue and provided a great solution. Really appreciated. Hope t o get this out in the next couple of days in a v1r14 release.
The code to address V-230274, "RHEL 8 must implement certificate status checking for multifactor authentication." is placed in the incorrect section of the
sssd.conf
file in some situations.This section of the
fix-cat2.yml
attempts to enforce the STIG V-230274 finding using theansible.builtin.lineinfile:
module:RHEL8-STIG/tasks/fix-cat2.yml
Lines 1392 to 1403 in 461d572
This is addressing this STIG finding:
(Emphasis mine.)
The
lineinfile:
module will only ensure the line is in the file, but it does not account for which section of this INI formatted file it must reside. This has bit me on a few occasions when the sections of thesssd.conf
file are rearranged.If we can use the
community.general.ini_file:
module, this section can be rewritten to address this issue:Since the
state: present
entries only need the section, theini_file:
parameter forsection:
is omitted if thewith_items:
don't have a section (and conveniently those are onlystate: absent
so should still work regardless of the section thevalue
appears.(I apologize if there are errors in the code, or corner cases it doesn't address - I'm not able to execute this on a test system, but this has bit us in some of our test configurations and I wanted to log this issue for visibility.)
The text was updated successfully, but these errors were encountered: