aws-solutions / aws-waf-security-automations

This solution automatically deploys a single web access control list (web ACL) with a set of AWS WAF rules designed to filter common web-based attacks.
https://aws.amazon.com/solutions/aws-waf-security-automations
Apache License 2.0
835 stars 358 forks source link

Need help writing Custom ACL #247

Closed sam-germany closed 1 year ago

sam-germany commented 1 year ago

I am trying to write a custom ACL rule based on JWT token come in the request so that i WAF allow or block the request after decoding it. Somehow not able to find the correct way to do it. Can anyone help me sending any example code ?

OR my question in another way, Are we alloweed to write own custom ACL in python and deploy directly with thsi solution ?

WillAWS commented 1 year ago

Yes. You are allowed to write your own custom ACL & deploy directly :) Because this is open source, feel free to tweak it to make it work for you.

sam-germany commented 1 year ago

https://github.com/aws/aws-sdk-go/blob/v1.44.269/service/wafv2/api.go

I am developing a solution with Go SDK and trying to catch the request and based on some logic allow or block the request. but as in the whole Go SDK i do not find any method that catchs the request come to WAF. Is their is any sample code available for this usecase ?

aijunpeng commented 1 year ago

Unfortunately that is not in the scope of the WAF security automation solution. I would suggest you to check with the Go SDK team or WAF service team on this: https://docs.aws.amazon.com/awssupport/latest/user/case-management.html Thanks!