github.com/khulnasoft-lab/defsec@v1.0.5-0.20230827010352-5e9f46893d95/pkg/terraform/schema.go (about) 1 package terraform 2 3 import "github.com/hashicorp/hcl/v2" 4 5 // Schema is regularly lifted from terraform source to ensure compatibility 6 var Schema = &hcl.BodySchema{ 7 Blocks: []hcl.BlockHeaderSchema{ 8 { 9 Type: "terraform", 10 }, 11 { 12 Type: "required_providers", 13 }, 14 { 15 Type: "provider", 16 LabelNames: []string{"name"}, 17 }, 18 { 19 Type: "variable", 20 LabelNames: []string{"name"}, 21 }, 22 { 23 Type: "locals", 24 }, 25 { 26 Type: "output", 27 LabelNames: []string{"name"}, 28 }, 29 { 30 Type: "module", 31 LabelNames: []string{"name"}, 32 }, 33 { 34 Type: "check", 35 LabelNames: []string{"name"}, 36 }, 37 { 38 Type: "resource", 39 LabelNames: []string{"type", "name"}, 40 }, 41 { 42 Type: "data", 43 LabelNames: []string{"type", "name"}, 44 }, 45 { 46 Type: "moved", 47 }, 48 { 49 Type: "import", 50 }, 51 }, 52 }