-
Notifications
You must be signed in to change notification settings - Fork 710
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11427 from vojtapolasek/validate_levels_in_controls
Validate levels in controls
- Loading branch information
Showing
5 changed files
with
93 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
tests/unit/ssg-module/data/policy_with_different_than_implicit_default_level.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
policy: ABCD Benchmark for securing Linux systems | ||
title: ABCD Benchmark for securing Linux systems | ||
id: abcd | ||
version: 1.2.3 | ||
source: https://www.abcd.com/linux.pdf | ||
controls: | ||
- id: R1 | ||
title: User session timeout | ||
levels: | ||
- l1 | ||
description: >- | ||
Remote user sessions must be closed after a certain | ||
period of inactivity. | ||
automated: yes | ||
rules: | ||
- sshd_set_idle_timeout | ||
- accounts_tmout | ||
- var_accounts_tmout=10_min | ||
- configure_crypto_policy | ||
notes: >- | ||
Certain period of inactivity is vague. | ||
- id: R2 | ||
title: Minimization of configuration | ||
description: >- | ||
The features configured at the level of launched services | ||
should be limited to the strict minimum. | ||
rationale: >- | ||
Minimization of configuration helps to reduce attack surface. | ||
automated: no | ||
notes: >- | ||
This is individual depending on the system workload | ||
therefore needs to be audited manually. | ||
related_rules: | ||
- systemd_target_multi_user |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
policy: ABCD Benchmark for securing Linux systems with levels | ||
title: ABCD Benchmark for securing Linux systems with levels | ||
id: abcd-levels | ||
version: 1.2.3 | ||
source: https://www.abcd.com/linux.pdf | ||
levels: | ||
- id: low | ||
- id: medium | ||
inherits_from: | ||
- low | ||
- id: high | ||
inherits_from: | ||
- medium | ||
|
||
controls: | ||
- id: S1 | ||
title: User session timeout | ||
|
||
- id: S2 | ||
levels: | ||
- invalid | ||
rules: | ||
- var_password_pam_minlen=1 | ||
- var_some_variable=1 | ||
|
||
- id: S3 | ||
levels: | ||
- medium |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters