Skip to content

5.1.7 not working with AllowGroups #62

Open
@kodebach

Description

@kodebach

Describe the Issue
The check for 5.1.7 seems to broken when using AllowGroups. Possibly there is another reason, I don't quite understand how the check works.

Expected Behavior
After running https://github.com/ansible-lockdown/RHEL9-CIS with rhel9cis_sshd_allowgroups set, the check audit should succeed.

Actual Behavior
Running the lockdown playbook with

rhel9cis_sshd_allowusers: '' # disabled, using AllowGroups
rhel9cis_sshd_allowgroups: ssh-access

results in a failed audit.

Control(s) Affected
5.1.7 | Ensure SSH access is limited | config

Additional Notes

The output of this command

exec: grep -Ei "^(Allow|Deny)(Users|Groups)" /etc/ssh/sshd_config /etc/ssh/sshd_config.d/*.conf

is the following on our system

/etc/ssh/sshd_config:AllowGroups ssh-access
/etc/ssh/sshd_config:DenyUsers nobody

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions