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

Inconsistent conditionals when masking services #135

Open
ipruteanu-sie opened this issue Dec 7, 2023 · 0 comments
Open

Inconsistent conditionals when masking services #135

ipruteanu-sie opened this issue Dec 7, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@ipruteanu-sie
Copy link
Contributor

Describe the Issue
The way I understood rules 2.2.16, 2.2.17 and 2.2.18 is this one:

Server Service Result
false false Remove 'package'
false true Needing 'service' without needing 'server' makes no sense
true false Mask 'service'
true true SKIP RULE, BOTH 'service' and 'server' are required

Expected Behavior (similar with 2.2.17 or 2.2.18)

      - name: "2.2.16 | PATCH | Ensure nfs-utils is not installed or the nfs-server service is masked | mask service"
        ansible.builtin.systemd:
            name: nfs-server
            masked: true
            state: stopped
        when:
            - rhel9cis_use_nfs_server
            - not rhel9cis_use_nfs_service

Actual Behavior

      - name: "2.2.16 | PATCH | Ensure nfs-utils is not installed or the nfs-server service is masked | mask service"
        ansible.builtin.systemd:
            name: nfs-server
            masked: true
            state: stopped
        when:
            - not rhel9cis_use_nfs_server
            - rhel9cis_use_nfs_service

Control(s) Affected
2.2.16

Environment (please complete the following information):

  • branch being used: [e.g. devel]

Possible Solution
PR afterwards.

@ipruteanu-sie ipruteanu-sie added the bug Something isn't working label Dec 7, 2023
@uk-bolly uk-bolly self-assigned this Dec 13, 2023
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