From 5e4c035bfa43c426d939b149780d9863f08cf156 Mon Sep 17 00:00:00 2001 From: Jacob Bednarz Date: Thu, 5 Dec 2024 11:32:22 +1100 Subject: [PATCH] `make docs` --- .../resources/leaked_credential_check_rule.md | 47 +++++++++++++ .../leaked_credential_check_rules.md | 68 ------------------- docs/resources/notification_policy.md | 2 +- .../resource.tf | 2 +- 4 files changed, 49 insertions(+), 70 deletions(-) create mode 100644 docs/resources/leaked_credential_check_rule.md delete mode 100644 docs/resources/leaked_credential_check_rules.md diff --git a/docs/resources/leaked_credential_check_rule.md b/docs/resources/leaked_credential_check_rule.md new file mode 100644 index 0000000000..5700a484bd --- /dev/null +++ b/docs/resources/leaked_credential_check_rule.md @@ -0,0 +1,47 @@ +--- +page_title: "cloudflare_leaked_credential_check_rule Resource - Cloudflare" +subcategory: "" +description: |- + Provides a Cloudflare Leaked Credential Check Rules resource for managing user-defined Leaked Credential detection patterns within a specific zone. +--- + +# cloudflare_leaked_credential_check_rule (Resource) + +Provides a Cloudflare Leaked Credential Check Rules resource for managing user-defined Leaked Credential detection patterns within a specific zone. + +## Example Usage + +```terraform +# Enable the Leaked Credentials Check detection before trying +# to add detections. +resource "cloudflare_leaked_credential_check" "example" { + zone_id = "399c6f4950c01a5a141b99ff7fbcbd8b" + enabled = true +} + +resource "cloudflare_leaked_credential_check_rules" "example" { + zone_id = cloudflare_leaked_credential_check.example.zone_id + username = "lookup_json_string(http.request.body.raw, \"user\")" + password = "lookup_json_string(http.request.body.raw, \"pass\")" +} +``` + +## Schema + +### Required + +- `password` (String) The ruleset expression to use in matching the password in a request +- `username` (String) The ruleset expression to use in matching the username in a request. +- `zone_id` (String) The zone identifier to target for the resource. + +### Read-Only + +- `id` (String) The identifier of this resource. + +## Import + +Import is supported using the following syntax: + +```shell +terraform import cloudflare_leaked_credential_check_rule.example / +``` diff --git a/docs/resources/leaked_credential_check_rules.md b/docs/resources/leaked_credential_check_rules.md deleted file mode 100644 index eae1dc3adb..0000000000 --- a/docs/resources/leaked_credential_check_rules.md +++ /dev/null @@ -1,68 +0,0 @@ ---- -page_title: "cloudflare_leaked_credential_check_rules Resource - Cloudflare" -subcategory: "" -description: |- - Provides a Cloudflare Leaked Credential Check Rules resource for managing user-defined Leaked Credential detection patterns within a specific zone. ---- - -# cloudflare_leaked_credential_check_rules (Resource) - -Provides a Cloudflare Leaked Credential Check Rules resource for managing user-defined Leaked Credential detection patterns within a specific zone. - -## Example Usage - -```terraform -# Enable the Leaked Credentials Check detection -resource "cloudflare_leaked_credential_check" "example" { - zone_id = "399c6f4950c01a5a141b99ff7fbcbd8b" - enabled = true -} - -# Create user-defined detection patterns for Leaked Credentials Check -resource "cloudflare_leaked_credential_check_rules" "example" { - # The following line ensures that rules are created only for a zone - # where the Leaked Credentials Check module is enabled, and that the - # module is activated before user-defined detection patterns are created. - zone_id = cloudflare_leaked_credential_check.example.zone_id - - rule { - username = "lookup_json_string(http.request.body.raw, \"user\")" - password = "lookup_json_string(http.request.body.raw, \"pass\")" - } - - rule { - username = "lookup_json_string(http.request.body.raw, \"id\")" - password = "lookup_json_string(http.request.body.raw, \"secret\")" - } -} -``` - -## Schema - -### Required - -- `zone_id` (String) The zone identifier to target for the resource. - -### Optional - -- `rule` (Block Set) List of user-defined patterns for Leaked Credential Check (see [below for nested schema](#nestedblock--rule)) - - -### Nested Schema for `rule` - -Required: - -- `password` (String) The ruleset expression to use in matching the password in a request -- `username` (String) The ruleset expression to use in matching the username in a request. - -Read-Only: - -- `id` (String) The identifier of this resource. - -## Import - -Import is supported using the following syntax: - -```shell -terraform import cloudflare_leaked_credential_check_rules.example -``` diff --git a/docs/resources/notification_policy.md b/docs/resources/notification_policy.md index 77fda4f5c3..d44ab56cec 100644 --- a/docs/resources/notification_policy.md +++ b/docs/resources/notification_policy.md @@ -104,7 +104,7 @@ Read-Only: Optional: - `actions` (Set of String) Targeted actions for alert. -- `affected_components` (Set of String) Affected components for alert. Available values: `API`, `API Shield`, `Access`, `Always Online`, `Analytics`, `Apps Marketplace`, `Argo Smart Routing`, `Audit Logs`, `Authoritative DNS`, `Billing`, `Bot Management`, `Bring Your Own IP (BYOIP)`, `Browser Isolation`, `CDN Cache Purge`, `CDN/Cache`, `Cache Reserve`, `Challenge Platform`, `Cloud Access Security Broker (CASB)`, `Community Site`, `DNS Root Servers`, `DNS Updates`, `Dashboard`, `Data Loss Prevention (DLP)`, `Developer's Site`, `Digital Experience Monitoring (DEX)`, `Distributed Web Gateway`, `Durable Objects`, `Email Routing`, `Ethereum Gateway`, `Firewall`, `Gateway`, `Geo-Key Manager`, `Image Resizing`, `Images`, `Infrastructure`, `Lists`, `Load Balancing and Monitoring`, `Logs`, `Magic Firewall`, `Magic Transit`, `Magic WAN`, `Magic WAN Connector`, `Marketing Site`, `Mirage`, `Network`, `Notifications`, `Observatory`, `Page Shield`, `Pages`, `R2`, `Radar`, `Randomness Beacon`, `Recursive DNS`, `Registrar`, `Registration Data Access Protocol (RDAP)`, `SSL Certificate Provisioning`, `SSL for SaaS Provisioning`, `Security Center`, `Snippets`, `Spectrum`, `Speed Optimizations`, `Stream`, `Support Site`, `Time Services`, `Trace`, `Tunnel`, `Turnstile`, `WARP`, `Waiting Room`, `Web Analytics`, `Workers`, `Workers KV`, `Workers Preview`, `Zaraz`, `Zero Trust`, `Zero Trust Dashboard`, `Zone Versioning`. +- `affected_components` (Set of String) Affected components for alert. Available values: `API`, `API Shield`, `Access`, `Always Online`, `Analytics`, `Apps Marketplace`, `Argo Smart Routing`, `Audit Logs`, `Authoritative DNS`, `Billing`, `Bot Management`, `Bring Your Own IP (BYOIP)`, `Browser Isolation`, `CDN Cache Purge`, `CDN/Cache`, `Cache Reserve`, `Challenge Platform`, `Cloud Access Security Broker (CASB)`, `Community Site`, `D1`, `DNS Root Servers`, `DNS Updates`, `Dashboard`, `Data Loss Prevention (DLP)`, `Developer's Site`, `Digital Experience Monitoring (DEX)`, `Distributed Web Gateway`, `Durable Objects`, `Email Routing`, `Ethereum Gateway`, `Firewall`, `Gateway`, `Geo-Key Manager`, `Image Resizing`, `Images`, `Infrastructure`, `Lists`, `Load Balancing and Monitoring`, `Logs`, `Magic Firewall`, `Magic Transit`, `Magic WAN`, `Magic WAN Connector`, `Marketing Site`, `Mirage`, `Network`, `Notifications`, `Observatory`, `Page Shield`, `Pages`, `R2`, `Radar`, `Randomness Beacon`, `Recursive DNS`, `Registrar`, `Registration Data Access Protocol (RDAP)`, `SSL Certificate Provisioning`, `SSL for SaaS Provisioning`, `Security Center`, `Snippets`, `Spectrum`, `Speed Optimizations`, `Stream`, `Support Site`, `Time Services`, `Trace`, `Tunnel`, `Turnstile`, `WARP`, `Waiting Room`, `Web Analytics`, `Workers`, `Workers KV`, `Workers Preview`, `Zaraz`, `Zero Trust`, `Zero Trust Dashboard`, `Zone Versioning`. - `airport_code` (Set of String) Filter on Points of Presence. - `alert_trigger_preferences` (Set of String) Alert trigger preferences. Example: `slo`. - `enabled` (Set of String) State of the pool to alert on. diff --git a/examples/resources/cloudflare_leaked_credential_check_rule/resource.tf b/examples/resources/cloudflare_leaked_credential_check_rule/resource.tf index b18147d1a8..879fce32e6 100644 --- a/examples/resources/cloudflare_leaked_credential_check_rule/resource.tf +++ b/examples/resources/cloudflare_leaked_credential_check_rule/resource.tf @@ -5,7 +5,7 @@ resource "cloudflare_leaked_credential_check" "example" { enabled = true } -resource "cloudflare_leaked_credential_check_rules" "example" { +resource "cloudflare_leaked_credential_check_rule" "example" { zone_id = cloudflare_leaked_credential_check.example.zone_id username = "lookup_json_string(http.request.body.raw, \"user\")" password = "lookup_json_string(http.request.body.raw, \"pass\")"