awswafv2: SingleHeaderProperty in GO generates bad CF template (capitalized "Name" property) #28074
Labels
@aws-cdk/aws-wafv2
bug
This issue is a bug.
jsii
This issue originates in jsii, or this feature must be implemented in jsii.
p2
Describe the bug
The use of SingleHeaderProperty in GO CDK for waf header validatrion is synthesizing a nonvalid template.
this is the code used:
This is the generated template portion
"FieldToMatch": { "SingleHeader": { "name": "issued" } },
and this is the error in deployment.
#/Rules/3/Statement/NotStatement/Statement/ByteMatchStatement/FieldToMatch/SingleHeader: required key [Name] not found
#/Rules/3/Statement/NotStatement/Statement/ByteMatchStatement/FieldToMatch/SingleHeader: extraneous key [name] is not permitted
Expected Behavior
synthesize a template with capitalized property
"FieldToMatch": { "SingleHeader": { "Name": "issued" }
Current Behavior
This is the generated template portion
"FieldToMatch": { "SingleHeader": { "name": "issued" } },
Reproduction Steps
create a waf with a rule that validates the header using ByteMathStament:
Possible Solution
No response
Additional Information/Context
No response
CDK CLI Version
2.110.0
Framework Version
No response
Node.js Version
18.14.0
OS
windows 10
Language
Go
Language Version
No response
Other information
#27537
#23709
The text was updated successfully, but these errors were encountered: