Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cis_1.8.2 failed. Modifications needed to align with RHEL9-CIS role #38

Open
levaillx opened this issue Oct 29, 2024 · 1 comment
Open
Assignees
Labels
bug Something isn't working

Comments

@levaillx
Copy link

levaillx commented Oct 29, 2024

Describe the Issue
Commands gdm_profile_banner and gdm_banner_msg are not aligned with the modifications applied by RHEL9-CIS (1.3.2).
Commands fail even if the configuration is correctly set.

Expected Behavior
Count: 4, Failed: 0, Skipped: 0

Actual Behavior
Count: 4, Failed: 2, Skipped: 0

Control(s) Affected
cis 1.8.2

Environment:

  • branch being used: benchmark_v1.0.0
  • Ansible Version: 2.16.11
  • Host Python Version: 3.9.18
  • Ansible Server Python Version: 3.9.18
  • Additional Details:

Additional Notes

Possible Solution
Minor modifications:

@@ -7,9 +7,8 @@
     exit-status: 0
     stdout:
     - '/^user-db:user/'
-    - '/^system-db:user/'
+    - '/^system-db:gdm/'
     - '/^file-db:\/usr\/share\/gdm\/greeter-dconf-defaults/'
-    - "/^banner-message-text=\'{{ .Vars.rhel9cis_warning_banner }}\'/"
     meta:
       server: 1
       workstation: 1
@@ -22,7 +21,7 @@
       CISv8_IG3: true
   gdm_banner_msg:
     title: 1.8.2 | Ensure GDM login banner is configured
-    exec: grep "[org/gnome/login-screen]" /etc/dconf/db/gdm.d/* | grep banner-message
+    exec: grep "[org/gnome/login-screen]" /etc/dconf/db/gdm.d/01-banner-message | grep banner-message
     exit-status:
       or:
       - 0
@@ -30,7 +29,7 @@
     stdout:
     - '/^banner-message-enable=true/'
     - '!/^banner-message-enable=false/'
-    - "/^banner-message-text=\'{{ .Vars.rhel9cis_warning_banner }}\'/"
+    - "/^banner-message-text=\"{{ .Vars.rhel9cis_warning_banner }}\"/"
     meta:
       server: 1
       workstation: 1
@levaillx levaillx added the bug Something isn't working label Oct 29, 2024
uk-bolly added a commit that referenced this issue Oct 30, 2024
Signed-off-by: Mark Bolwell <[email protected]>
@uk-bolly uk-bolly self-assigned this Oct 30, 2024
@uk-bolly
Copy link
Member

hi @levaillx

Thank you for your time and feedback. There is a new branch created to address the issues you have raised which i hope to get merged later today.

Many thanks

uk-bolly

This was referenced Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants