Skip to content

Commit

Permalink
Merge pull request #6559 from Checkmarx/kics-782-alicloud-terraform
Browse files Browse the repository at this point in the history
fix(query): alicloud rds instance address publicly accessible terraform query refactor
  • Loading branch information
asofsilva authored Aug 11, 2023
2 parents 9107466 + 91cb4ed commit b8f4ff1
Show file tree
Hide file tree
Showing 8 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"id": "faaefc15-51a5-419e-bb5e-51a4b5ab3485",
"queryName": "DB Instance Publicly Accessible",
"queryName": "RDS DB Instance Publicly Accessible",
"severity": "HIGH",
"category": "Insecure Configurations",
"descriptionText": "The field 'address' should not be set to '0.0.0.0/0'",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[
{
"queryName": "DB Instance Publicly Accessible",
"queryName": "RDS DB Instance Publicly Accessible",
"severity": "HIGH",
"line": 10,
"fileName": "positive1.tf"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ CxPolicy[result] {
"documentId": input.document[i].id,
"resourceType": "alicloud_db_instance",
"resourceName": tf_lib.get_resource_name(resource, name),
"searchKey": sprintf("alicloud_db_instance[%s].security_ips.%s", [name,x]),
"searchKey": sprintf("alicloud_db_instance[%s].security_ips[%v]", [name,x]),
"issueType": "IncorrectValue",
"keyExpectedValue": sprintf("'%s' should not be in 'security_ips' list", [sec_ip]),
"keyActualValue": sprintf("'%s' is in 'security_ips' list", [sec_ip]),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ CxPolicy[result] {
"documentId": input.document[i].id,
"resourceType": "alicloud_db_instance",
"resourceName": tf_lib.get_resource_name(resource, name),
"searchKey": sprintf("alicloud_db_instance[%s]]", [name]),
"searchKey": sprintf("alicloud_db_instance[%s]", [name]),
"issueType": "MissingAttribute",
"keyExpectedValue": "'ssl_action' value should be 'Open'",
"keyActualValue": "'ssl_action' is not defined",
Expand Down

0 comments on commit b8f4ff1

Please sign in to comment.