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

Groups the Defaults together #131

Merged
merged 1 commit into from
Jan 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions tasks/section_4/cis_4.3.x.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
path: /etc/sudoers
regexp: '^\s*Defaults\s+use_pty\s*$'
line: 'Defaults use_pty'
insertafter: 'EOF'
insertafter: '^\s*Defaults'
when:
- ubtu20cis_rule_4_3_2
tags:
Expand All @@ -35,7 +35,7 @@
path: /etc/sudoers
regexp: '^\s*Defaults\s+logfile\s*='
line: 'Defaults logfile="{{ ubtu20cis_sudo_logfile }}"'
insertafter: 'EOF'
insertafter: '^\s*Defaults'
when:
- ubtu20cis_rule_4_3_3
tags:
Expand Down Expand Up @@ -92,6 +92,7 @@
regexp: '^\s*Defaults\s+timestamp_timeout\s*='
line: "Defaults timestamp_timeout={{ ubtu20cis_sudo_timestamp_timeout }}"
validate: '/usr/sbin/visudo -cf %s'
insertafter: '^\s*Defaults'
when: ubtu20cis_4_3_6_timeout_files.stdout | length == 0

- name: "4.3.6 | PATCH | Ensure sudo authentication timeout is configured correctly | Set value if has results"
Expand Down