Skip to content

Commit

Permalink
Groups the Defaults together
Browse files Browse the repository at this point in the history
Signed-off-by: Dan D <[email protected]>
  • Loading branch information
dderemiah committed Jan 5, 2024
1 parent c10bca7 commit aab873f
Showing 1 changed file with 3 additions and 2 deletions.
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

0 comments on commit aab873f

Please sign in to comment.