-
Notifications
You must be signed in to change notification settings - Fork 509
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 #270 from accurics/bugfix/policy-exporter-update-r…
…ule-json added line number and file name output support
- Loading branch information
Showing
48 changed files
with
262 additions
and
368 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
7 changes: 3 additions & 4 deletions
7
.../aws/aws_cloudfront_distribution/AWS.CloudFront.EncryptionandKeyManagement.High.0407.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "cloudfrontNoHTTPSTraffic", | ||
"name": "cloudfrontNoHTTPSTraffic", | ||
"file": "cloudfrontNoHTTPSTraffic.rego", | ||
"ruleTemplate": "cloudfrontNoHTTPSTraffic", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "HIGH", | ||
"description": "Use encrypted connection between CloudFront and origin server", | ||
"ruleReferenceId": "AWS.CloudFront.EncryptionandKeyManagement.High.0407", | ||
"referenceId": "AWS.CloudFront.EncryptionandKeyManagement.High.0407", | ||
"category": "Encryption and Key Management", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
.../aws/aws_cloudfront_distribution/AWS.CloudFront.EncryptionandKeyManagement.High.0408.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "cloudfrontNoSecureCiphers", | ||
"name": "cloudfrontNoSecureCiphers", | ||
"file": "cloudfrontNoSecureCiphers.rego", | ||
"ruleTemplate": "cloudfrontNoSecureCiphers", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "HIGH", | ||
"description": "Secure ciphers are not used in CloudFront distribution", | ||
"ruleReferenceId": "AWS.CloudFront.EncryptionandKeyManagement.High.0408", | ||
"referenceId": "AWS.CloudFront.EncryptionandKeyManagement.High.0408", | ||
"category": "Encryption and Key Management", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
...policies/opa/rego/aws/aws_cloudfront_distribution/AWS.CloudFront.Logging.Medium.0567.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "cloudfrontNoLogging", | ||
"name": "cloudfrontNoLogging", | ||
"file": "cloudfrontNoLogging.rego", | ||
"ruleTemplate": "cloudfrontNoLogging", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Ensure that your AWS Cloudfront distributions have the Logging feature enabled in order to track all viewer requests for the content delivered through the Content Delivery Network (CDN).", | ||
"ruleReferenceId": "AWS.CloudFront.Logging.Medium.0567", | ||
"referenceId": "AWS.CloudFront.Logging.Medium.0567", | ||
"category": "Logging", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_cloudtrail/AWS.CloudTrail.Logging.High.0399.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "cloudTrailLogNotEncrypted", | ||
"name": "cloudTrailLogNotEncrypted", | ||
"file": "cloudTrailLogNotEncrypted.rego", | ||
"ruleTemplate": "cloudTrailLogNotEncrypted", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "HIGH", | ||
"description": "Cloud Trail Log Not Enabled", | ||
"ruleReferenceId": "AWS.CloudTrail.Logging.High.0399", | ||
"referenceId": "AWS.CloudTrail.Logging.High.0399", | ||
"category": "Logging", | ||
"version": 2 | ||
} |
9 changes: 4 additions & 5 deletions
9
pkg/policies/opa/rego/aws/aws_cloudtrail/AWS.CloudTrail.Logging.Low.0559.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "reme_enableSNSTopic", | ||
"name": "reme_enableSNSTopic", | ||
"file": "enableSNSTopic.rego", | ||
"ruleTemplate": "enableSNSTopic", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "reme_" | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Ensure appropriate subscribers to each SNS topic", | ||
"ruleReferenceId": "AWS.CloudTrail.Logging.Low.0559", | ||
"referenceId": "AWS.CloudTrail.Logging.Low.0559", | ||
"category": "Logging", | ||
"version": 0 | ||
"version": 1 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_cloudtrail/AWS.CloudTrail.Logging.Medium.0460.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "cloudTrailMultiRegionNotCreated", | ||
"name": "cloudTrailMultiRegionNotCreated", | ||
"file": "cloudTrailMultiRegionNotCreated.rego", | ||
"ruleTemplate": "cloudTrailMultiRegionNotCreated", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Cloud Trail Multi Region not enabled", | ||
"ruleReferenceId": "AWS.CloudTrail.Logging.Medium.0460", | ||
"referenceId": "AWS.CloudTrail.Logging.Medium.0460", | ||
"category": "Logging", | ||
"version": 2 | ||
} |
This file was deleted.
Oops, something went wrong.
9 changes: 0 additions & 9 deletions
9
pkg/policies/opa/rego/aws/aws_db_instance/rdsPubliclyAccessible.rego
This file was deleted.
Oops, something went wrong.
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_access_key/AWS.IamUser.IAM.High.0390.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "noAccessKeyForRootAccount", | ||
"name": "noAccessKeyForRootAccount", | ||
"file": "noAccessKeyForRootAccount.rego", | ||
"ruleTemplate": "noAccessKeyForRootAccount", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "HIGH", | ||
"description": "The root account is the most privileged user in an AWS account. AWS Access Keys provide programmatic access to a given AWS account. It is recommended that all access keys associated with the root account be removed. Removing access keys associated with the root account limits vectors by which the account can be compromised. Additionally, removing the root access keys encourages the creation and use of role based accounts that are least privileged.", | ||
"ruleReferenceId": "AWS.IamUser.IAM.High.0390", | ||
"referenceId": "AWS.IamUser.IAM.High.0390", | ||
"category": "Identity and Access Management", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_account_password_policy/AWS.Iam.IAM.Low.0540.json
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 |
---|---|---|
@@ -1,14 +1,13 @@ | ||
{ | ||
"ruleName": "passwordRotateEvery90Days", | ||
"name": "passwordRotateEvery90Days", | ||
"file": "passwordRotateEvery90Days.rego", | ||
"ruleTemplate": "passwordRotateEvery90Days", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"name": "passwordRotateEvery90Days", | ||
"prefix": "" | ||
}, | ||
"severity": "LOW", | ||
"description": "Reducing the password lifetime increases account resiliency against brute force login attempts", | ||
"ruleReferenceId": "AWS.Iam.IAM.Low.0540", | ||
"referenceId": "AWS.Iam.IAM.Low.0540", | ||
"category": "IAM", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_account_password_policy/AWS.Iam.IAM.Medium.0454.json
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 |
---|---|---|
@@ -1,15 +1,14 @@ | ||
{ | ||
"ruleName": "passwordRequireLowerCase", | ||
"name": "passwordRequireLowerCase", | ||
"file": "passwordPolicyRequirement.rego", | ||
"ruleTemplate": "passwordRequireLowerCase", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"name": "passwordRequireLowerCase", | ||
"prefix": "", | ||
"required_parameter": "require_lowercase_characters" | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Lower case alphabet not present in the Password, Password Complexity is not high. Increased Password complexity increases resiliency against brute force attack", | ||
"ruleReferenceId": "AWS.Iam.IAM.Medium.0454", | ||
"referenceId": "AWS.Iam.IAM.Medium.0454", | ||
"category": "IAM", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_account_password_policy/AWS.Iam.IAM.Medium.0455.json
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 |
---|---|---|
@@ -1,15 +1,14 @@ | ||
{ | ||
"ruleName": "passwordRequireNumber", | ||
"name": "passwordRequireNumber", | ||
"file": "passwordPolicyRequirement.rego", | ||
"ruleTemplate": "passwordRequireNumber", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"name": "passwordRequireNumber", | ||
"prefix": "", | ||
"required_parameter": "require_numbers" | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Number not present in the Password, Password Complexity is not high. Increased Password complexity increases resiliency against brute force attack", | ||
"ruleReferenceId": "AWS.Iam.IAM.Medium.0455", | ||
"referenceId": "AWS.Iam.IAM.Medium.0455", | ||
"category": "IAM", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_account_password_policy/AWS.Iam.IAM.Medium.0456.json
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 |
---|---|---|
@@ -1,15 +1,14 @@ | ||
{ | ||
"ruleName": "passwordRequireSymbol", | ||
"name": "passwordRequireSymbol", | ||
"file": "passwordPolicyRequirement.rego", | ||
"ruleTemplate": "passwordRequireSymbol", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"name": "passwordRequireSymbol", | ||
"prefix": "", | ||
"required_parameter": "require_symbols" | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Special symbols not present in the Password, Password Complexity is not high. Increased Password complexity increases resiliency against brute force attack", | ||
"ruleReferenceId": "AWS.Iam.IAM.Medium.0456", | ||
"referenceId": "AWS.Iam.IAM.Medium.0456", | ||
"category": "IAM", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_account_password_policy/AWS.Iam.IAM.Medium.0457.json
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 |
---|---|---|
@@ -1,15 +1,14 @@ | ||
{ | ||
"ruleName": "passwordRequireUpperCase", | ||
"name": "passwordRequireUpperCase", | ||
"file": "passwordPolicyRequirement.rego", | ||
"ruleTemplate": "passwordRequireUpperCase", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"name": "passwordRequireUpperCase", | ||
"prefix": "", | ||
"required_parameter": "require_uppercase_characters" | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Upper case alphabet not present in the Password, Password Complexity is not high. Increased Password complexity increases resiliency against brute force attack", | ||
"ruleReferenceId": "AWS.Iam.IAM.Medium.0457", | ||
"referenceId": "AWS.Iam.IAM.Medium.0457", | ||
"category": "IAM", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_account_password_policy/AWS.Iam.IAM.Medium.0458.json
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 |
---|---|---|
@@ -1,16 +1,15 @@ | ||
{ | ||
"ruleName": "passwordRequireMinLength14", | ||
"name": "passwordRequireMinLength14", | ||
"file": "passwordMinLength.rego", | ||
"ruleTemplate": "passwordRequireMinLength14", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"name": "passwordRequireMinLength14", | ||
"parameter": "minimum_password_length", | ||
"prefix": "", | ||
"value": 14 | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Setting a lengthy password increases account resiliency against brute force login attempts", | ||
"ruleReferenceId": "AWS.Iam.IAM.Medium.0458", | ||
"referenceId": "AWS.Iam.IAM.Medium.0458", | ||
"category": "IAM", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_account_password_policy/AWS.Iam.IAM.Medium.0495.json
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 |
---|---|---|
@@ -1,16 +1,15 @@ | ||
{ | ||
"ruleName": "passwordRequireMinLength", | ||
"name": "passwordRequireMinLength", | ||
"file": "passwordMinLength.rego", | ||
"ruleTemplate": "passwordRequireMinLength", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"name": "passwordRequireMinLength", | ||
"parameter": "minimum_password_length", | ||
"prefix": "", | ||
"value": 7 | ||
}, | ||
"severity": "MEDIUM", | ||
"description": "Setting a lengthy password increases account resiliency against brute force login attempts", | ||
"ruleReferenceId": "AWS.Iam.IAM.Medium.0495", | ||
"referenceId": "AWS.Iam.IAM.Medium.0495", | ||
"category": "IAM", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_group_policy/AWS.IamPolicy.IAM.High.0392.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "iamGrpPolicyWithFullAdminCntrl", | ||
"name": "iamGrpPolicyWithFullAdminCntrl", | ||
"file": "iamGrpPolicyWithFullAdminCntrl.rego", | ||
"ruleTemplate": "iamGrpPolicyWithFullAdminCntrl", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "HIGH", | ||
"description": "It is recommended and considered a standard security advice to grant least privileges that is, granting only the permissions required to perform a task. IAM policies are the means by which privileges are granted to users, groups, or roles. Determine what users need to do and then craft policies for them that let the users perform only those tasks, instead of granting full administrative privileges.", | ||
"ruleReferenceId": "AWS.IamPolicy.IAM.High.0392", | ||
"referenceId": "AWS.IamPolicy.IAM.High.0392", | ||
"category": "Identity and Access Management", | ||
"version": 2 | ||
} |
7 changes: 3 additions & 4 deletions
7
pkg/policies/opa/rego/aws/aws_iam_policy/AWS.IamPolicy.IAM.High.0392.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "reme_iamPolicyWithFullAdminControl", | ||
"name": "reme_iamPolicyWithFullAdminControl", | ||
"file": "iamPolicyWithFullAdminControl.rego", | ||
"ruleTemplate": "iamPolicyWithFullAdminControl", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "reme_" | ||
}, | ||
"severity": "HIGH", | ||
"description": "It is recommended and considered a standard security advice to grant least privileges that is, granting only the permissions required to perform a task. IAM policies are the means by which privileges are granted to users, groups, or roles. Determine what users need to do and then craft policies for them that let the users perform only those tasks, instead of granting full administrative privileges.", | ||
"ruleReferenceId": "AWS.IamPolicy.IAM.High.0392", | ||
"referenceId": "AWS.IamPolicy.IAM.High.0392", | ||
"category": "Identity and Access Management", | ||
"version": 2 | ||
} |
9 changes: 4 additions & 5 deletions
9
pkg/policies/opa/rego/aws/aws_iam_user_policy/AWS.IamUser.IAM.High.0387.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "rootUserNotContainMfaTypeHardware", | ||
"name": "rootUserNotContainMfaTypeHardware", | ||
"file": "rootUserNotContainMfaTypeHardware.rego", | ||
"ruleTemplate": "rootUserNotContainMfaTypeHardware", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "HIGH", | ||
"description": "Ensure Hardware MFA device is enabled for the \"root\" account", | ||
"ruleReferenceId": "AWS.IamUser.IAM.High.0387", | ||
"referenceId": "AWS.IamUser.IAM.High.0387", | ||
"category": "Identity and Access Management", | ||
"version": 0 | ||
"version": 1 | ||
} |
9 changes: 4 additions & 5 deletions
9
pkg/policies/opa/rego/aws/aws_iam_user_policy/AWS.IamUser.IAM.High.0388.json
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 |
---|---|---|
@@ -1,13 +1,12 @@ | ||
{ | ||
"ruleName": "rootUserNotContainMfaTypeVirtual", | ||
"name": "rootUserNotContainMfaTypeVirtual", | ||
"file": "rootUserNotContainMfaTypeVirtual.rego", | ||
"ruleTemplate": "rootUserNotContainMfaTypeVirtual", | ||
"ruleTemplateArgs": { | ||
"templateArgs": { | ||
"prefix": "" | ||
}, | ||
"severity": "HIGH", | ||
"description": "Ensure Virtual MFA device is enabled for the \"root\" account", | ||
"ruleReferenceId": "AWS.IamUser.IAM.High.0388", | ||
"referenceId": "AWS.IamUser.IAM.High.0388", | ||
"category": "Identity and Access Management", | ||
"version": 0 | ||
"version": 1 | ||
} |
Oops, something went wrong.