Skip to content

Commit

Permalink
Merge branch 'master' into dependabot/go_modules/github.com/cloudflar…
Browse files Browse the repository at this point in the history
…e/cloudflare-go-0.70.0
  • Loading branch information
jacobbednarz authored Jun 22, 2023
2 parents db52f79 + 8a766c8 commit a28924d
Show file tree
Hide file tree
Showing 14 changed files with 72 additions and 119 deletions.
1 change: 1 addition & 0 deletions testdata/terraform/cloudflare_custom_hostname/test.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ resource "cloudflare_custom_hostname" "terraform_managed_resource" {
hostname = "app.example.com"
zone_id = "0da42c8d2132a9ddaf714f9e7c920711"
ssl {
bundle_method = "ubiquitous"
certificate_authority = "digicert"
custom_certificate = "-----BEGIN CERTIFICATE-----\\nMIIFJDCCBAygAwIBAgIQD0ifmj/Yi5NP/2gdUySbfzANBgkqhkiG9w0BAQsFADBN\\nMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMScwJQYDVQQDEx5E...SzSHfXp5lnu/3V08I72q1QNzOCgY1XeL4GKVcj4or6cT6tX6oJH7ePPmfrBfqI/O\\nOeH8gMJ+FuwtXYEPa4hBf38M5eU5xWG7\\n-----END CERTIFICATE-----\\n"
custom_key = "-----BEGIN RSA PRIVATE KEY-----\nMIIEowIBAAKCAQEAwQHoetcl9+5ikGzV6cMzWtWPJHqXT3wpbEkRU9Yz7lgvddmG\ndtcGbg/1CGZu0jJGkMoppoUo4c3dts3iwqRYmBikUP77wwY2QGmDZw2FvkJCJlKn\nabIRuGvBKwzESIXgKk2016aTP6/dAjEHyo6SeoK8lkIySUvK0fyOVlsiEsCmOpid\ntnKX/a+50GjB79CJH4ER2lLVZnhePFR/zUOyPxZQQ4naHf7yu/b5jhO0f8fwt+py\nFxIXjbEIdZliWRkRMtzrHOJIhrmJ2A1J7iOrirbbwillwjjNVUWPf3IJ3M12S9pE\newooaeO2izNTERcG9HzAacbVRn2Y2SWIyT/18QIDAQABAoIBACbhTYXBZYKmYPCb\nHBR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gAcWPokmJ7EbYQGeMbS7HC8eWO/RyamlnSffdCdSc7ue3zdVJxpAkQ8W\nqu80pEIF6raIQfAf8MXiiZ7auFOSnHQTXUbhCpvDLKi0Mwq3G8Pl07l+2s6dQG6T\nlv6XTQaMyf6n1yjzL+fzDrH3qXMxHMO/b13EePXpDMpY7HQpoLDi\n-----END RSA PRIVATE KEY-----\n"
Expand Down
2 changes: 1 addition & 1 deletion testdata/terraform/cloudflare_page_rule/test.tf
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ resource "cloudflare_page_rule" "terraform_managed_resource" {
resolved = true
}
query_string {
exclude = ["*"]
ignore = true
}
user {
device_type = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,10 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
disable_stale_while_updating = true
}
}
description = "test cache rule"
enabled = false
expression = "(http.host eq \"example.com\")"
id = "0f24aab3002347a9a4ac01520e6893d0"
last_updated = "2022-09-28T17:21:21.510301Z"
ref = "0f24aab3002347a9a4ac01520e6893d0"
version = "3"
description = "test cache rule"
enabled = false
expression = "(http.host eq \"example.com\")"
ref = "0f24aab3002347a9a4ac01520e6893d0"
}
rules {
action = "set_cache_settings"
Expand All @@ -68,12 +65,9 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
mode = "override_origin"
}
}
description = "/status/202"
enabled = true
expression = "(http.host eq \"example.com\")"
id = "e5f1bd1386b4464aa8d726ba1e0d51ad"
last_updated = "2022-09-21T16:36:00.999083Z"
ref = "e5f1bd1386b4464aa8d726ba1e0d51ad"
version = "2"
description = "/status/202"
enabled = true
expression = "(http.host eq \"example.com\")"
ref = "e5f1bd1386b4464aa8d726ba1e0d51ad"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,8 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
version = "latest"
}
description = "zone"
enabled = false
expression = "(http.cookie eq \"jb_testing=true\")"
last_updated = "2021-09-03T06:42:41.341405Z"
description = "zone"
enabled = false
expression = "(http.cookie eq \"jb_testing=true\")"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,8 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
version = "latest"
}
description = "zone"
enabled = false
expression = "(http.cookie eq \"jb_testing=true\")"
last_updated = "2021-09-03T06:42:41.341405Z"
description = "zone"
enabled = false
expression = "(http.cookie eq \"jb_testing=true\")"
}
}
9 changes: 3 additions & 6 deletions testdata/terraform/cloudflare_ruleset_zone/test.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,8 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
version = "latest"
}
enabled = true
expression = "true"
id = "0789dc4343054d1e981f8c44bedc6fbd"
last_updated = "2021-08-19T23:41:34.985519Z"
ref = "0789dc4343054d1e981f8c44bedc6fbd"
version = "1"
enabled = true
expression = "true"
ref = "0789dc4343054d1e981f8c44bedc6fbd"
}
}
11 changes: 4 additions & 7 deletions testdata/terraform/cloudflare_ruleset_zone_ddos_l7/test.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,9 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
version = "latest"
}
description = "zone"
enabled = true
expression = "true"
id = "c6893ad10fb344e9b8be3c0c3575adc9"
last_updated = "2021-08-30T02:38:50.39057Z"
ref = "c6893ad10fb344e9b8be3c0c3575adc9"
version = "1"
description = "zone"
enabled = true
expression = "true"
ref = "c6893ad10fb344e9b8be3c0c3575adc9"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,9 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
request_fields = ["request", "fields"]
response_fields = ["response", "fields"]
}
description = "zone"
enabled = true
expression = "true"
id = "17a0d1e23a3444ccbd5e58fc7793649a"
last_updated = "2022-07-22T12:34:45.479429Z"
ref = "17a0d1e23a3444ccbd5e58fc7793649a"
version = "1"
description = "zone"
enabled = true
expression = "true"
ref = "17a0d1e23a3444ccbd5e58fc7793649a"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,16 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
phase = "http_ratelimit"
zone_id = "0da42c8d2132a9ddaf714f9e7c920711"
rules {
action = "block"
description = "fwewe"
enabled = false
expression = "(http.cookie eq \"namwe=value\")"
id = "549e64153ff14d2cb5a5ef88c1f5bdbc"
last_updated = "2021-08-29T21:59:21.447624Z"
action = "block"
description = "fwewe"
enabled = false
expression = "(http.cookie eq \"namwe=value\")"
ratelimit {
characteristics = ["ip.src", "cf.colo.id"]
mitigation_timeout = 30
period = 60
requests_per_period = 100
}
ref = "549e64153ff14d2cb5a5ef88c1f5bdbc"
version = "1"
ref = "549e64153ff14d2cb5a5ef88c1f5bdbc"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,35 +10,26 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
products = ["zoneLockdown", "uaBlock", "bic", "hot", "securityLevel", "rateLimit", "waf"]
ruleset = "current"
}
description = "test.example.com"
enabled = true
expression = "(http.host eq \"test.example.com\")"
id = "88dcb30401e348ba9e1352c2598f2a4c"
last_updated = "2022-11-24T14:24:14.756247Z"
description = "test.example.com"
enabled = true
expression = "(http.host eq \"test.example.com\")"
logging {
enabled = true
}
ref = "88dcb30401e348ba9e1352c2598f2a4c"
version = "2"
ref = "88dcb30401e348ba9e1352c2598f2a4c"
}
rules {
action = "challenge"
description = "customRule-test"
enabled = true
expression = "(cf.bot_management.score eq 50 and cf.bot_management.static_resource)"
id = "b3cc5e4cc6604f9d90a6a106df867760"
last_updated = "2022-11-07T19:03:05.198191Z"
ref = "b3cc5e4cc6604f9d90a6a106df867760"
version = "29"
action = "challenge"
description = "customRule-test"
enabled = true
expression = "(cf.bot_management.score eq 50 and cf.bot_management.static_resource)"
ref = "b3cc5e4cc6604f9d90a6a106df867760"
}
rules {
action = "log"
description = "AWAF ML"
enabled = false
expression = "(cf.waf.score le 20)"
id = "1ecf73bdf7bd4227969a734412b13ad1"
last_updated = "2022-12-09T16:53:19.003821Z"
ref = "1ecf73bdf7bd4227969a734412b13ad1"
version = "7"
action = "log"
description = "AWAF ML"
enabled = false
expression = "(cf.waf.score le 20)"
ref = "1ecf73bdf7bd4227969a734412b13ad1"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,9 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
version = "latest"
}
description = "zone"
enabled = false
expression = "(http.cookie eq \"jb_testing=true\")"
last_updated = "2021-09-03T06:42:41.341405Z"
description = "zone"
enabled = false
expression = "(http.cookie eq \"jb_testing=true\")"
}
rules {
action = "skip"
Expand All @@ -83,15 +82,12 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
"4814384a9e5d4991b9815dcfc25d2f1f" = "37da7855d2f94f69865365d894a556a4,6afe6795ee6a48d6a1dfe59255395a78,5a6f5a57cde8428ab0668ce17cdec0c8,5e4903d6afa841c9b88b96203297003f,2380cd409b604c2a9273042f3eb29c4e,f5aebedc99a14c8d9e8cfa2ce5f94216,edf8c37cc81747d382690b3c77e82ce4,1129dfb383bb42e48466488cf3b37cb1"
}
}
description = "Bypass managed OWSAP SQL Injection rules for /api/v1/identity"
enabled = true
expression = "(http.request.method eq \"POST\" and http.request.uri.path eq \"/api/v1/identity\")"
id = "d189267a8dc943769d0000c3dcb400eb"
last_updated = "2023-05-12T08:23:03.177093Z"
description = "Bypass managed OWSAP SQL Injection rules for /api/v1/identity"
enabled = true
expression = "(http.request.method eq \"POST\" and http.request.uri.path eq \"/api/v1/identity\")"
logging {
enabled = true
}
ref = "d189267a8dc943769d0000c3dcb400eb"
version = "1"
ref = "d189267a8dc943769d0000c3dcb400eb"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,10 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
}
}
description = "test transform"
enabled = true
expression = "(http.request.uri.path eq \"example.com\")"
id = "e5b61605d6cf4ce08f729c17d42d76ef"
last_updated = "2022-02-07T16:58:54.317608Z"
ref = "e5b61605d6cf4ce08f729c17d42d76ef"
version = "1"
description = "test transform"
enabled = true
expression = "(http.request.uri.path eq \"example.com\")"
ref = "e5b61605d6cf4ce08f729c17d42d76ef"
}
rules {
action = "rewrite"
Expand All @@ -42,13 +39,10 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
value = "my-http-header-1"
}
}
description = "test transform set"
enabled = true
expression = "(http.request.uri.path eq \"example.com\")"
id = "8ec764cf386940c89dd83dbab7bb4c16"
last_updated = "2022-02-07T16:58:54.317608Z"
ref = "8ec764cf386940c89dd83dbab7bb4c16"
version = "1"
description = "test transform set"
enabled = true
expression = "(http.request.uri.path eq \"example.com\")"
ref = "8ec764cf386940c89dd83dbab7bb4c16"
}
rules {
action = "rewrite"
Expand All @@ -59,12 +53,9 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
}
}
description = "test uri rewrite set"
enabled = false
expression = "(http.request.uri.path eq \"pumpkin.com\")"
id = "d0f1b4fdb4234adf9c6de9b614424836"
last_updated = "2022-05-07T16:58:54.317608Z"
ref = "d0f1b4fdb4234adf9c6de9b614424836"
version = "1"
description = "test uri rewrite set"
enabled = false
expression = "(http.request.uri.path eq \"pumpkin.com\")"
ref = "d0f1b4fdb4234adf9c6de9b614424836"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,8 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
version = "latest"
}
enabled = true
expression = "true"
id = "0789dc4343054d1e981f8c44bedc6fbd"
last_updated = "2021-08-19T23:41:34.985519Z"
ref = "0789dc4343054d1e981f8c44bedc6fbd"
version = "1"
enabled = true
expression = "true"
ref = "0789dc4343054d1e981f8c44bedc6fbd"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,9 @@ resource "cloudflare_ruleset" "terraform_managed_resource" {
}
}
}
description = "rewrite with no query string"
enabled = true
expression = "true"
id = "1fb6a3117e864d46bcda192d14a1e1dc"
last_updated = "2023-02-16T00:26:08.978517Z"
ref = "1fb6a3117e864d46bcda192d14a1e1dc"
version = "5"
description = "rewrite with no query string"
enabled = true
expression = "true"
ref = "1fb6a3117e864d46bcda192d14a1e1dc"
}
}

0 comments on commit a28924d

Please sign in to comment.