-
Notifications
You must be signed in to change notification settings - Fork 124
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
*.field_to_match.headers.match_pattern "all" option is not working #94
Comments
Hey, I created a PR which I think is supposed to fix this issue? |
Thanks @MatanHeledPort! I was thinking of something similar to what's done with the cookies: |
Maybe keeping convention is better - I will change it to match |
seems like the problem is with your use of the statement block. |
Would probably be good to add an example as well in https://github.com/umotif-public/terraform-aws-waf-webaclv2/blob/main/examples/wafv2-bytematch-rules/main.tf |
Sure!
Working on an example aswell |
What initial statement is the
|
Yes, exactly
|
Took a quick look here, seems like the problem is with the use of Replace |
When you get to merging LMK @felipe88alves |
I'm don't have write access, but maybe @Ohid25 can help 👍 |
Can we please get some feedback on this PR? |
Feel free to use my forked PR branch. Its what Im doing untill this merges @felipe88alves |
* Small fix for 'field_to_match' to enable 'all' option' * fixed for all header field matches * changed to match cookies * changed array output * changed array output * revert array change * added example * fix * chore: changelog + hooks update + lint --------- Co-authored-by: Abdul Wahid <[email protected]>
This should now be fixed as a part of 4.4.0. |
What is the current behavior?
Applying a rule with the
field_to_match
set toheaders
will fail when thematch_pattern
is set toall
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.
The following rule will not fail a
plan
, but will produce an empty statement, which fails when running anapply
What is the expected behavior?
It should not produce an empty statement and should not fail an
apply
Software versions?
umotif/terraform-aws-waf-webaclv2: v4.2.0
hashicorp/aws: v4.59.0
The text was updated successfully, but these errors were encountered: