-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* introduce user constraints * introduce help props * adjust help uri coverage * Update src/validations/constraints/fedramp-external-constraints.xml Co-authored-by: A.J. Stein <[email protected]> * Update src/validations/constraints/fedramp-external-constraints.xml Co-authored-by: A.J. Stein <[email protected]> * Update src/validations/constraints/fedramp-external-constraints.xml Co-authored-by: A.J. Stein <[email protected]> * Update src/validations/constraints/fedramp-external-constraints.xml Co-authored-by: A.J. Stein <[email protected]> * Update src/validations/constraints/fedramp-external-constraints.xml Co-authored-by: A.J. Stein <[email protected]> * see GSA/automate.fedramp.gov#98 * merge same invalid samples * Update user-type-FAIL.yaml * Update user-type-FAIL.yaml * update tests * Update src/validations/constraints/fedramp-external-allowed-values.xml Co-authored-by: A.J. Stein <[email protected]> * Update src/validations/constraints/content/ssp-all-VALID.xml Co-authored-by: A.J. Stein <[email protected]> * update tests --------- Co-authored-by: A.J. Stein <[email protected]>
- Loading branch information
1 parent
04d3591
commit 5cb7351
Showing
22 changed files
with
210 additions
and
5 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<system-security-plan xmlns="http://csrc.nist.gov/ns/oscal/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" uuid="12345678-1234-4321-8765-123456789012"> | ||
<system-implementation> | ||
<user uuid="44444444-0000-4000-9000-000000000004"> | ||
</user> | ||
</system-implementation> | ||
</system-security-plan> |
8 changes: 8 additions & 0 deletions
8
src/validations/constraints/content/ssp-user-privilege-level-INVALID.xml
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,8 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<system-security-plan xmlns="http://csrc.nist.gov/ns/oscal/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" uuid="12345678-1234-4321-8765-123456789012"> | ||
<system-implementation> | ||
<user uuid="44444444-0000-4000-9000-000000000004"> | ||
<prop ns="https://fedramp.gov/ns/oscal" name="privilege-level" value="invalid"/> | ||
</user> | ||
</system-implementation> | ||
</system-security-plan> |
8 changes: 8 additions & 0 deletions
8
src/validations/constraints/content/ssp-user-sensitivity-level-INVALID.xml
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,8 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<system-security-plan xmlns="http://csrc.nist.gov/ns/oscal/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" uuid="12345678-1234-4321-8765-123456789012"> | ||
<system-implementation> | ||
<user uuid="44444444-0000-4000-9000-000000000004"> | ||
<prop ns='https://fedramp.gov/ns/oscal' name="sensitivity" value="infinite-risk"/> | ||
</user> | ||
</system-implementation> | ||
</system-security-plan> |
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
9 changes: 9 additions & 0 deletions
9
src/validations/constraints/unit-tests/user-has-authorized-privilege-FAIL.yaml
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,9 @@ | ||
test-case: | ||
name: Negative Test for user-has-authorized-privilege | ||
description: >- | ||
This test case validates the behavior of constraint | ||
user-has-authorized-privilege | ||
content: ../content/ssp-user-INVALID.xml | ||
expectations: | ||
- constraint-id: user-has-authorized-privilege | ||
result: fail |
9 changes: 9 additions & 0 deletions
9
src/validations/constraints/unit-tests/user-has-authorized-privilege-PASS.yaml
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,9 @@ | ||
test-case: | ||
name: Positive Test for user-has-authorized-privilege | ||
description: >- | ||
This test case validates the behavior of constraint | ||
user-has-authorized-privilege | ||
content: ../content/ssp-all-VALID.xml | ||
expectations: | ||
- constraint-id: user-has-authorized-privilege | ||
result: pass |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-has-privilege-level-FAIL.yaml
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,7 @@ | ||
test-case: | ||
name: Negative Test for user-has-privilege-level | ||
description: This test case validates the behavior of constraint user-has-privilege-level | ||
content: ../content/ssp-user-INVALID.xml | ||
expectations: | ||
- constraint-id: user-has-privilege-level | ||
result: fail |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-has-privilege-level-PASS.yaml
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,7 @@ | ||
test-case: | ||
name: Positive Test for user-has-privilege-level | ||
description: This test case validates the behavior of constraint user-has-privilege-level | ||
content: ../content/ssp-all-VALID.xml | ||
expectations: | ||
- constraint-id: user-has-privilege-level | ||
result: pass |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-has-role-id-FAIL.yaml
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,7 @@ | ||
test-case: | ||
name: Negative Test for user-has-role-id | ||
description: This test case validates the behavior of constraint user-has-role-id | ||
content: ../content/ssp-user-INVALID.xml | ||
expectations: | ||
- constraint-id: user-has-role-id | ||
result: fail |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-has-role-id-PASS.yaml
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,7 @@ | ||
test-case: | ||
name: Positive Test for user-has-role-id | ||
description: This test case validates the behavior of constraint user-has-role-id | ||
content: ../content/ssp-all-VALID.xml | ||
expectations: | ||
- constraint-id: user-has-role-id | ||
result: pass |
9 changes: 9 additions & 0 deletions
9
src/validations/constraints/unit-tests/user-has-sensitivity-level-FAIL.yaml
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,9 @@ | ||
test-case: | ||
name: Negative Test for user-has-sensitivity-level | ||
description: >- | ||
This test case validates the behavior of constraint | ||
user-has-sensitivity-level | ||
content: ../content/ssp-user-INVALID.xml | ||
expectations: | ||
- constraint-id: user-has-sensitivity-level | ||
result: fail |
9 changes: 9 additions & 0 deletions
9
src/validations/constraints/unit-tests/user-has-sensitivity-level-PASS.yaml
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,9 @@ | ||
test-case: | ||
name: Positive Test for user-has-sensitivity-level | ||
description: >- | ||
This test case validates the behavior of constraint | ||
user-has-sensitivity-level | ||
content: ../content/ssp-all-VALID.xml | ||
expectations: | ||
- constraint-id: user-has-sensitivity-level | ||
result: pass |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-has-user-type-FAIL.yaml
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,7 @@ | ||
test-case: | ||
name: Negative Test for user-has-user-type | ||
description: This test case validates the behavior of constraint user-has-user-type | ||
content: ../content/ssp-user-INVALID.xml | ||
expectations: | ||
- constraint-id: user-has-user-type | ||
result: fail |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-has-user-type-PASS.yaml
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,7 @@ | ||
test-case: | ||
name: Positive Test for user-has-user-type | ||
description: This test case validates the behavior of constraint user-has-user-type | ||
content: ../content/ssp-all-VALID.xml | ||
expectations: | ||
- constraint-id: user-has-user-type | ||
result: pass |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-privilege-level-FAIL.yaml
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,7 @@ | ||
test-case: | ||
name: Negative Test for user-privilege-level | ||
description: This test case validates the behavior of constraint user-privilege-level | ||
content: ../content/ssp-user-privilege-level-INVALID.xml | ||
expectations: | ||
- constraint-id: user-privilege-level | ||
result: fail |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-privilege-level-PASS.yaml
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,7 @@ | ||
test-case: | ||
name: Positive Test for user-privilege-level | ||
description: This test case validates the behavior of constraint user-privilege-level | ||
content: ../content/ssp-all-VALID.xml | ||
expectations: | ||
- constraint-id: user-privilege-level | ||
result: pass |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-sensitivity-level-FAIL.yaml
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,7 @@ | ||
test-case: | ||
name: Negative Test for user-sensitivity-level | ||
description: This test case validates the behavior of constraint user-sensitivity-level | ||
content: ../content/ssp-user-sensitivity-level-INVALID.xml | ||
expectations: | ||
- constraint-id: user-sensitivity-level | ||
result: fail |
7 changes: 7 additions & 0 deletions
7
src/validations/constraints/unit-tests/user-sensitivity-level-PASS.yaml
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,7 @@ | ||
test-case: | ||
name: Positive Test for user-sensitivity-level | ||
description: This test case validates the behavior of constraint user-sensitivity-level | ||
content: ../content/ssp-all-VALID.xml | ||
expectations: | ||
- constraint-id: user-sensitivity-level | ||
result: pass |