-
Notifications
You must be signed in to change notification settings - Fork 6
/
scan_sudoers.yml
64 lines (53 loc) · 1.42 KB
/
scan_sudoers.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
---
- name: "Test scan_sudoers - Python 2.7"
hosts: "localhost"
gather_facts: False
vars:
ansible_python_interpreter: "/usr/bin/python2.7"
tasks:
- name: "Scan Sudoers"
scan_sudoers:
become: True
- name: "Display all sudoers data"
debug:
var: "sudoers"
- name: "Scan Sudoers - no parsed data"
scan_sudoers:
output_parsed_configs: False
become: True
- name: "Display only sudoers raw configs"
debug:
var: "sudoers"
- name: "Scan Sudoers - no raw configuration data"
scan_sudoers:
output_raw_configs: False
become: True
- name: "Display only sudoers parsed configs"
debug:
var: "sudoers"
- name: "Test scan_sudoers - Python 3.7"
hosts: "localhost"
gather_facts: False
vars:
ansible_python_interpreter: "/usr/bin/python3.7"
tasks:
- name: "Scan Sudoers - all data"
scan_sudoers:
become: True
- name: "Display all sudoers data"
debug:
var: "sudoers"
- name: "Scan Sudoers - no parsed data"
scan_sudoers:
output_parsed_configs: False
become: True
- name: "Display only sudoers raw configs"
debug:
var: "sudoers"
- name: "Scan Sudoers - no raw configuration data"
scan_sudoers:
output_raw_configs: False
become: True
- name: "Display only sudoers parsed configs"
debug:
var: "sudoers"