Skip to content

Commit

Permalink
r/aws_wafv2: Add missing values to text_transformation argument (#2…
Browse files Browse the repository at this point in the history
…0564)

* Add all possible text transformation values

* Add changelog

* Remove trailing space

* review fixes

Co-authored-by: Jack Batzner <[email protected]>
  • Loading branch information
jackbatzner and Brunhil authored Aug 19, 2021
1 parent 74b5e12 commit 018f423
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 12 deletions.
3 changes: 3 additions & 0 deletions .changelog/20564.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
resource/aws_wafv2: Add missing values to `text_transformation` argument for `aws_wafv2_web_acl` and `aws_wafv2_rule_group` resources
```
13 changes: 3 additions & 10 deletions aws/wafv2_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -373,16 +373,9 @@ func wafv2TextTransformationSchema() *schema.Schema {
Required: true,
},
"type": {
Type: schema.TypeString,
Required: true,
ValidateFunc: validation.StringInSlice([]string{
wafv2.TextTransformationTypeCmdLine,
wafv2.TextTransformationTypeCompressWhiteSpace,
wafv2.TextTransformationTypeHtmlEntityDecode,
wafv2.TextTransformationTypeLowercase,
wafv2.TextTransformationTypeNone,
wafv2.TextTransformationTypeUrlDecode,
}, false),
Type: schema.TypeString,
Required: true,
ValidateFunc: validation.StringInSlice(wafv2.TextTransformationType_Values(), false),
},
},
},
Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/wafv2_rule_group.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -520,7 +520,7 @@ The `single_query_argument` block supports the following arguments:
The `text_transformation` block supports the following arguments:

* `priority` - (Required) The relative processing order for multiple transformations that are defined for a rule statement. AWS WAF processes all transformations, from lowest priority to highest, before inspecting the transformed content.
* `type` - (Required) The transformation to apply, you can specify the following types: `NONE`, `COMPRESS_WHITE_SPACE`, `HTML_ENTITY_DECODE`, `LOWERCASE`, `CMD_LINE`, `URL_DECODE`. See the [documentation](https://docs.aws.amazon.com/waf/latest/APIReference/API_TextTransformation.html) for more details.
* `type` - (Required) The transformation to apply, please refer to the Text Transformation [documentation](https://docs.aws.amazon.com/waf/latest/APIReference/API_TextTransformation.html) for more details.

### Visibility Configuration

Expand Down
3 changes: 2 additions & 1 deletion website/docs/r/wafv2_web_acl.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,8 @@ The `single_query_argument` block supports the following arguments:
The `text_transformation` block supports the following arguments:

* `priority` - (Required) The relative processing order for multiple transformations that are defined for a rule statement. AWS WAF processes all transformations, from lowest priority to highest, before inspecting the transformed content.
* `type` - (Required) The transformation to apply, you can specify the following types: `NONE`, `COMPRESS_WHITE_SPACE`, `HTML_ENTITY_DECODE`, `LOWERCASE`, `CMD_LINE`, `URL_DECODE`. See the [documentation](https://docs.aws.amazon.com/waf/latest/APIReference/API_TextTransformation.html) for more details.
* `type` - (Required) The transformation to apply, please refer to the Text Transformation [documentation](https://docs.aws.amazon.com/waf/latest/APIReference/API_TextTransformation.html) for more details.


### Visibility Configuration

Expand Down

0 comments on commit 018f423

Please sign in to comment.