forked from trussworks/terraform-aws-config
-
Notifications
You must be signed in to change notification settings - Fork 0
/
variables.tf
550 lines (459 loc) · 14.7 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
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
variable "config_name" {
description = "The name of the AWS Config instance."
type = string
default = "aws-config"
}
variable "config_aggregator_name" {
description = "The name of the aggregator."
type = string
default = "organization"
}
variable "aggregate_organization" {
description = "Aggregate compliance data by organization"
type = bool
default = false
}
variable "config_logs_bucket" {
description = "The S3 bucket for AWS Config logs. If you have set enable_config_recorder to false then this can be an empty string."
type = string
}
variable "config_logs_prefix" {
description = "The S3 prefix for AWS Config logs."
type = string
default = "config"
}
variable "config_logs_bucket_kms_key_arn" {
description = "The ARN of the AWS KMS key used to encrypt objects delivered by AWS Config. Must belong to the same Region as the destination S3 bucket."
type = string
default = null
}
variable "config_max_execution_frequency" {
description = "The maximum frequency with which AWS Config runs evaluations for a rule."
type = string
default = "TwentyFour_Hours"
}
variable "config_delivery_frequency" {
description = "The frequency with which AWS Config delivers configuration snapshots."
default = "Six_Hours"
type = string
}
variable "acm_days_to_expiration" {
description = "Specify the number of days before the rule flags the ACM Certificate as noncompliant."
type = number
default = 14
}
variable "password_require_uppercase" {
description = "Require at least one uppercase character in password."
type = bool
default = true
}
variable "password_require_lowercase" {
description = "Require at least one lowercase character in password."
type = bool
default = true
}
variable "password_require_symbols" {
description = "Require at least one symbol in password."
type = bool
default = true
}
variable "password_require_numbers" {
description = "Require at least one number in password."
type = bool
default = true
}
variable "password_min_length" {
description = "Password minimum length."
type = number
default = 14
}
variable "password_reuse_prevention" {
description = "Number of passwords before allowing reuse."
type = number
default = 24
}
variable "password_max_age" {
description = "Number of days before password expiration."
type = number
default = 90
}
variable "check_root_account_mfa_enabled" {
description = "Enable root-account-mfa-enabled rule"
type = bool
default = false
}
variable "check_guard_duty" {
description = "Enable guardduty-enabled-centralized rule"
type = bool
default = false
}
variable "check_rds_public_access" {
description = "Enable rds-instance-public-access-check rule"
type = bool
default = false
}
variable "check_multi_region_cloud_trail" {
description = "Enable multi-region-cloud-trail-enabled rule"
type = bool
default = false
}
variable "check_cloudtrail_enabled" {
description = "Enable cloudtrail-enabled rule"
type = bool
default = true
}
variable "check_cloud_trail_encryption" {
description = "Enable cloud-trail-encryption-enabled rule"
type = bool
default = false
}
variable "check_cloud_trail_log_file_validation" {
description = "Enable cloud-trail-log-file-validation-enabled rule"
type = bool
default = false
}
variable "check_eip_attached" {
description = "Enable eip-attached rule"
type = bool
default = false
}
variable "check_required_tags" {
description = "Enable required-tags rule"
type = bool
default = false
}
variable "required_tags_resource_types" {
description = "Resource types to check for tags."
type = list(string)
default = []
}
variable "required_tags" {
description = "A map of required resource tags. Format is tagNKey, tagNValue, where N is int. Values are optional."
type = map(string)
default = {}
}
variable "check_instances_in_vpc" {
description = "Enable instances-in-vpc rule"
type = bool
default = true
}
variable "check_acm_certificate_expiration_check" {
description = "Enable acm-certificate-expiration-check rule"
type = bool
default = true
}
variable "check_iam_password_policy" {
description = "Enable iam-password-policy rule"
type = bool
default = true
}
variable "check_iam_group_has_users_check" {
description = "Enable iam-group-has-users-check rule"
type = bool
default = true
}
variable "check_iam_user_no_policies_check" {
description = "Enable iam-user-no-policies-check rule"
type = bool
default = true
}
variable "check_ec2_volume_inuse_check" {
description = "Enable ec2-volume-inuse-check rule"
type = bool
default = true
}
variable "check_approved_amis_by_tag" {
description = "Enable approved-amis-by-tag rule"
type = bool
default = false
}
variable "ami_required_tag_key_value" {
description = "Tag/s key and value which AMI has to have in order to be compliant: Example: key1:value1,key2:value2"
type = string
default = ""
}
variable "check_ec2_encrypted_volumes" {
description = "Enable ec2-encrypted-volumes rule"
type = bool
default = true
}
variable "check_rds_storage_encrypted" {
description = "Enable rds-storage-encrypted rule"
type = bool
default = true
}
variable "check_rds_snapshots_public_prohibited" {
description = "Enable rds-snapshots-public-prohibited rule"
type = bool
default = true
}
variable "check_s3_bucket_public_write_prohibited" {
description = "Enable s3-bucket-public-write-prohibited rule"
type = bool
default = true
}
variable "check_cloudwatch_log_group_encrypted" {
description = "Enable cloudwatch-log-group-encryption rule"
type = bool
default = true
}
variable "check_cw_loggroup_retention_period" {
description = "Enable cloudwatch-log-group-retention-period-check rule"
type = bool
default = false
}
variable "cw_loggroup_retention_period" {
description = "Retention period for cloudwatch logs in number of days"
type = number
default = 3653
}
variable "check_iam_root_access_key" {
description = "Enable iam-root-access-key rule"
type = bool
default = true
}
variable "check_ebs_snapshot_public_restorable" {
description = "Enable ebs-snapshot-public-restorable rule"
type = bool
default = true
}
variable "check_vpc_default_security_group_closed" {
description = "Enable vpc-default-security-group-closed rule"
type = bool
default = true
}
variable "check_s3_bucket_ssl_requests_only" {
description = "Enable s3-bucket-ssl-requests-only rule"
type = bool
default = true
}
variable "check_mfa_enabled_for_iam_console_access" {
description = "Enable mfa-enabled-for-iam-console-access rule"
type = bool
default = true
}
variable "check_restricted_ssh" {
description = "Enable restricted-ssh rule"
type = bool
default = true
}
variable "tags" {
description = "Tags to apply to AWS Config resources"
type = map(string)
default = {}
}
variable "include_global_resource_types" {
description = "Specifies whether AWS Config includes all supported types of global resources with the resources that it records."
type = bool
default = true
}
variable "config_sns_topic_arn" {
description = "An SNS topic to stream configuration changes and notifications to."
type = string
default = null
}
variable "enable_config_recorder" {
description = "Enables configuring the AWS Config recorder resources in this module."
type = bool
default = true
}
variable "check_ec2_imdsv2" {
description = "Enable IMDSv2 rule"
type = bool
default = false
}
variable "check_access_keys_rotated" {
description = "Enable access-keys-rotated rule"
type = bool
default = true
}
variable "access_key_max_age" {
description = "Maximum number of days without rotation."
type = number
default = 90
}
variable "check_cmk_backing_key_rotated" {
description = "Enable cmk_backing_key_rotation_enabled rule"
type = bool
default = true
}
variable "cloud_trail_cloud_watch_logs_enabled" {
description = "Enable cloud_trail_cloud_watch_logs_enabled rule"
type = bool
default = true
}
variable "expected_delivery_window_age" {
description = "Maximum age in hours of the most recent delivery to CloudWatch logs that satisfies compliance."
type = number
default = 12
}
variable "check_dynamodb_table_encryption_enabled" {
description = "Enable checkdynamodb-table-encryption-enabled rule"
type = bool
default = true
}
variable "check_dynamodb_table_encrypted_kms" {
description = "Enable dynamodb-table-encrypted-kms rule"
type = bool
default = false
}
variable "dynamodb_arn_encryption_list" {
description = "Comma separated list of AWS KMS key ARNs allowed for encrypting Amazon DynamoDB Tables."
type = string
default = "example,CSV"
}
variable "check_ecr_private_image_scanning_enabled" {
description = "Enable ecr-private-image-scanning-enabled rule"
type = bool
default = true
}
variable "check_ecr_private_lifecycle_policy_configured" {
description = "Enable ecr-private-lifecycle-policy-configured rule"
type = bool
default = true
}
variable "check_ecs_awsvpc_networking_enabled" {
description = "Enable ecs-awsvpc-networking-enabled rule"
type = bool
default = true
}
variable "check_ecs_containers_nonprivileged" {
description = "Enable ecs-containers-nonprivileged rule"
type = bool
default = true
}
variable "check_ecs_containers_readonly_access" {
description = "Enable ecs-containers-readonly-access rule"
type = bool
default = true
}
variable "check_ecs_no_environment_secrets" {
description = "Enable ecs-no-environment-secrets rule"
type = bool
default = false
}
variable "ecs_no_environment_secrets" {
description = "Comma-separated list of key names to search for in the environment variables of container definitions within Task Definitions. Extra spaces will be removed."
type = string
default = "example,CSV"
}
variable "enable_efs_encrypted_check" {
description = "Enable efs-encrypted-check rule"
type = bool
default = false
}
variable "kms_key_id" {
description = "Amazon Resource Name (ARN) of the KMS key that is used to encrypt the EFS file system."
type = string
default = "example,CSV"
}
variable "check_elb_deletion_protection_enabled" {
description = "Enable elb-deletion-protection-enabled rule"
type = bool
default = true
}
variable "check_elb_logging_enabled" {
description = "Enable elb-logging-enabled rule"
type = bool
default = false
}
variable "elb_logging_s3_buckets" {
description = "Comma-separated list of Amazon S3 bucket names for Amazon ELB to deliver the log files."
type = string
default = "example,CSV"
}
variable "check_iam_policy_no_statements_with_admin_access" {
description = "Enable iam-policy-no-statements-with-admin-access rule"
type = bool
default = true
}
variable "check_iam_policy_no_statements_with_full_access" {
description = "Enable iam-policy-no-statements-with-full-access rule"
type = bool
default = true
}
variable "exclude_permission_boundary" {
description = "Boolean to exclude the evaluation of IAM policies used as permissions boundaries. If set to 'true', the rule will not include permissions boundaries in the evaluation. Otherwise, all IAM policies in scope are evaluated when set to 'false.'"
type = bool
default = false
}
variable "check_nacl_no_unrestricted_ssh_rdp" {
description = "Enable nacl-no-unrestricted-ssh-rdp rule"
type = bool
default = true
}
variable "check_internet_gateway_authorized_vpc_only" {
description = "Enable internet-gateway-authorized-vpc-only rule"
type = bool
default = false
}
variable "authorized_vpc_ids" {
description = "Comma-separated list of the authorized VPC IDs with attached IGWs. If parameter is not provided all attached IGWs will be NON_COMPLIANT."
type = string
default = "example,CSV"
}
variable "check_rds_snapshot_encrypted" {
description = "Enable rds-snapshot-encrypted rule"
type = bool
default = true
}
variable "check_rds_cluster_deletion_protection_enabled" {
description = "Enable rds-cluster-deletion-protection-enabled rule"
type = bool
default = true
}
variable "check_db_instance_backup_enabled" {
description = "Enable db-instance-backup-enabled rule"
type = bool
default = false
}
variable "check_s3_bucket_level_public_access_prohibited" {
description = "Enable s3-bucket-level-public-access-prohibited rule"
type = bool
default = false
}
variable "s3_bucket_public_access_prohibited_exclusion" {
description = "Comma-separated list of known allowed public Amazon S3 bucket names."
type = string
default = "example,CSV"
}
variable "check_s3_bucket_acl_prohibited" {
description = "Enable s3-bucket-acl-prohibited rule"
type = bool
default = true
}
variable "check_s3_bucket_server_side_encryption_enabled" {
description = "Enable s3-bucket-server-side-encryption-enabled rule"
type = bool
default = true
}
variable "check_vpc_sg_open_only_to_authorized_ports" {
description = "Enable vpc-sg-open-only-to-authorized-ports rule"
type = bool
default = true
}
variable "resource_types" {
description = "A list that specifies the types of AWS resources for which AWS Config records configuration changes (for example, AWS::EC2::Instance or AWS::CloudTrail::Trail). See relevant part of AWS Docs for available types."
type = list(string)
default = []
}
variable "enable_multi_account_logs" {
description = "Enable sending of logs and snapshots from different Config accounts / regions into a single bucket"
type = bool
default = false
}
variable "check_restricted_common_ports" {
description = "Enable restricted-common-ports-check"
type = bool
default = false
}
variable "check_s3_bucket_public_read_prohibited" {
description = "Enable s3-bucket-public-read-prohibited rule"
type = bool
default = false
}
variable "check_ebs_optimized_instance" {
description = "Enable ebs-optimized-instance-check rule"
type = bool
default = false
}