-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathmain.tf
68 lines (52 loc) · 1.29 KB
/
main.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
resource "aws_security_group_rule" "my-rule" {
type = "ingress"
cidr_blocks = ["0.0.0.0/0"]
}
resource "aws_alb_listener" "my-alb-listener" {
port = "80"
protocol = "HTTP"
}
resource "aws_db_security_group" "my-group" {
}
resource "aws_instance" "bad_user_data" {
user_data = <<EOF
DB_PASSWORD = "Some passwprkd"
EOF
}
variable "enableEncryption" {
default = false
}
#tfsec:ignore:azure-compute-enable-disk-encryption
resource "azurerm_managed_disk" "source" {
encryption_settings {
enabled = var.enableEncryption
}
}
resource "aws_api_gateway_domain_name" "missing_security_policy" {
}
resource "aws_api_gateway_domain_name" "empty_security_policy" {
security_policy = ""
}
resource "aws_api_gateway_domain_name" "outdated_security_policy" {
security_policy = "TLS_1_0"
}
resource "aws_api_gateway_domain_name" "valid_security_policy" {
security_policy = "TLS_1_2"
}
#tfsec:ignore:AWS092
resource "aws_dynamodb_table" "bad_example" {
name = "example"
hash_key = "TestTableHashKey"
billing_mode = "PAY_PER_REQUEST"
stream_enabled = true
stream_view_type = "NEW_AND_OLD_IMAGES"
attribute {
name = "TestTableHashKey"
type = "S"
}
point_in_time_recovery {
enabled = true
}
}
resource "aws_instance" "my_project" {
}