generated from aws-ia/terraform-repo-template
-
Notifications
You must be signed in to change notification settings - Fork 8
/
variables.tf
161 lines (146 loc) · 6.39 KB
/
variables.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
variable "replica_region" {
description = "Region where S3 bucket data from Amazon GuardDuty will be replicated. Defaults to `null`."
type = string
default = null
}
##################################################
# GuardDuty Detector
##################################################
variable "enable_guardduty" {
description = "Enable monitoring and feedback reporting. Setting to false is equivalent to 'suspending' GuardDuty. Defaults to `true`."
type = bool
default = true
}
variable "enable_s3_protection" {
description = "Configure and enable S3 protection. Defaults to `true`."
type = bool
default = true
}
variable "enable_kubernetes_protection" {
description = "Configure and enable Kubernetes audit logs as a data source for Kubernetes protection. Defaults to `true`."
type = bool
default = true
}
variable "enable_malware_protection" {
description = "Configure and enable Malware Protection as data source for EC2 instances with findings for the detector. Defaults to `true`."
type = bool
default = true
}
variable "enable_snapshot_retention" {
description = "Enable EBS Snaptshot retention for 30 days, if any Findings exists. Defaults to `false`."
type = bool
default = false
}
variable "finding_publishing_frequency" {
description = "Specifies the frequency of notifications sent for subsequent finding occurrences. If the detector is a GuardDuty member account, the value is determined by the GuardDuty primary account and cannot be modified. For standalone and GuardDuty primary accounts, it must be configured in Terraform to enable drift detection. Valid values for standalone and primary accounts: `FIFTEEN_MINUTES`, `ONE_HOUR`, `SIX_HOURS`. Defaults to `SIX_HOURS`."
type = string
default = "FIFTEEN_MINUTES"
}
##################################################
# GuardDuty Filter
##################################################
variable "filter_config" {
description = <<EOF
Specifies AWS GuardDuty Filter configuration.
`name` - The name of the filter
`rank` - Specifies the position of the filter in the list of current filters. Also specifies the order in which this filter is applied to the findings.
`action` - Specifies the action that is to be applied to the findings that match the filter. Can be one of ARCHIVE or NOOP.
`criterion` - Configuration block for `finding_criteria`. Composed by `field` and one or more of the following operators: `equals` | `not_equals` | `greater_than` | `greater_than_or_equal` | `less_than` | `less_than_or_equal`.
EOF
type = list(object({
name = string
description = optional(string)
rank = number
action = string
criterion = list(object({
field = string
equals = optional(list(string))
not_equals = optional(list(string))
greater_than = optional(string)
greater_than_or_equal = optional(string)
less_than = optional(string)
less_than_or_equal = optional(string)
}))
}))
default = null
}
##################################################
# GuardDuty IPSet
##################################################
variable "ipset_config" {
description = <<EOF
Specifies AWS GuardDuty IPSet configuration.
`activate` - Specifies whether GuardDuty is to start using the uploaded IPSet.
`name` - The friendly name to identify the IPSet.
`format` - The format of the file that contains the IPSet. Valid values: `TXT` | `STIX` | `OTX_CSV` | `ALIEN_VAULT` | `PROOF_POINT` | `FIRE_EYE`.
`content`- Literal string value to use as the object content, which will be uploaded as UTF-8-encoded text. Example: `10.0.0.0/8\n`.
`key` - Name of the object once it is in the bucket.
EOF
type = list(object({
activate = bool
name = string
format = string
content = string
key = string
}))
default = null
}
##################################################
# GuardDuty ThreatIntelSet
##################################################
variable "threatintelset_config" {
description = <<EOF
Specifies AWS GuardDuty ThreatIntelSet configuration.
`activate` - Specifies whether GuardDuty is to start using the uploaded ThreatIntelSet.
`name` - The friendly name to identify the ThreatIntelSet.
`format` - The format of the file that contains the ThreatIntelSet. Valid values: `TXT` | `STIX` | `OTX_CSV` | `ALIEN_VAULT` | `PROOF_POINT` | `FIRE_EYE`.
`content`- Literal string value to use as the object content, which will be uploaded as UTF-8-encoded text. Example: `10.0.0.0/8\n`.
`key` - Name of the object once it is in the bucket.
`object_acl`- Canned ACL to apply to the object. Valid values are `private` | `public-read` | `public-read-write` | `aws-exec-read` | `authenticated-read` | `bucket-owner-read` | `bucket-owner-full-control`.
EOF
type = list(object({
activate = bool
name = string
format = string
content = string
key = string
object_acl = string
}))
default = null
}
##################################################
# GuardDuty Publishing
##################################################
variable "publish_to_s3" {
description = "Specifies if the Amazon GuardDuty findings should be exported to S3. Defaults to `false`."
type = bool
default = false
}
variable "publishing_config" {
description = "Defines the findings publishing configuration."
type = list(object({
destination_arn = string
kms_key_arn = string
destination_type = optional(string)
}))
default = [{
destination_arn = null
kms_key_arn = null
destination_type = "S3"
}]
}
variable "guardduty_s3_bucket" {
description = "Name of the S3 Bucket for GuardDuty. Defaults to `null`."
type = string
default = null
}
variable "guardduty_bucket_acl" {
description = "Canned ACL to apply to the bucket. Valid values are `private` | `public-read` | `public-read-write` | `aws-exec-read` | `authenticated-read` | `bucket-owner-read` | `bucket-owner-full-control`. Defaults to `null`."
type = string
default = null
}
variable "tags" {
description = "Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level. Defaults to `{}`."
type = map(any)
default = {}
}