github.com/khulnasoft-lab/defsec@v1.0.5-0.20230827010352-5e9f46893d95/rules/cloud/policies/cloudstack/compute/no_sensitive_info.tf.go (about) 1 package compute 2 3 var terraformNoSensitiveInfoGoodExamples = []string{ 4 ` 5 resource "cloudstack_instance" "web" { 6 name = "server-1" 7 service_offering = "small" 8 network_id = "6eb22f91-7454-4107-89f4-36afcdf33021" 9 template = "CentOS 6.5" 10 zone = "zone-1" 11 user_data = <<EOF 12 export GREETING="Hello there" 13 EOF 14 } 15 `, ` 16 resource "cloudstack_instance" "web" { 17 name = "server-1" 18 service_offering = "small" 19 network_id = "6eb22f91-7454-4107-89f4-36afcdf33021" 20 template = "CentOS 6.5" 21 zone = "zone-1" 22 user_data = "ZXhwb3J0IEVESVRPUj12aW1hY3M=" 23 } 24 `, 25 } 26 27 var terraformNoSensitiveInfoBadExamples = []string{ 28 ` 29 resource "cloudstack_instance" "web" { 30 name = "server-1" 31 service_offering = "small" 32 network_id = "6eb22f91-7454-4107-89f4-36afcdf33021" 33 template = "CentOS 6.5" 34 zone = "zone-1" 35 user_data = <<EOF 36 export DATABASE_PASSWORD=\"SomeSortOfPassword\" 37 EOF 38 } 39 `, ` 40 resource "cloudstack_instance" "web" { 41 name = "server-1" 42 service_offering = "small" 43 network_id = "6eb22f91-7454-4107-89f4-36afcdf33021" 44 template = "CentOS 6.5" 45 zone = "zone-1" 46 user_data = "ZXhwb3J0IERBVEFCQVNFX1BBU1NXT1JEPSJTb21lU29ydE9mUGFzc3dvcmQi" 47 } 48 `, 49 } 50 51 var terraformNoSensitiveInfoLinks = []string{ 52 `https://registry.terraform.io/providers/hashicorp/cloudstack/latest/docs/resources/instance#`, 53 } 54 55 var terraformNoSensitiveInfoRemediationMarkdown = ``