Azure-docs: RequestCookie Example for ExclusionRule WAF CRS app Gateway

Created on 13 Jun 2019  Â·  11Comments  Â·  Source: MicrosoftDocs/azure-docs

Hi All,

Was reading this article :- https://docs.microsoft.com/en-us/azure/application-gateway/application-gateway-waf-configuration

But unfortunately I don't know if we have any examples which are more practical? like if a cookie that contains "X" and its value contains special characters, let is pass thru and not block.. how do we do such a evaluation?

I am struggling here instead of writing an Exclusion rule I tried something like this but I dnt know how to do the spcial character check in the string value. The case here is, if the cookie contains Key"__requestVerificationToken" and in that case if its value contains any special characters just ignore it and let the request pass thru:-

image


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

application-gatewasvc cxp in-progress product-question triaged

All 11 comments

@ketaanhshah do you still need assistance with this? I know you have a CSS case open and are also working via #33262.

@TravisCragg-MSFT yes I need help as I still dont know how to set that cookie thing as a customer rule. I think CSS case not opened by me though.

@ketaanhshah Exclusions can only be made on the Request Cookie Name, and 2 exclusion rules can not be combined.

The closest to your specification would be to check if a request cookie name contains 'X'

image

You might want to consider opening a CSS case to assist with your configuration, and possibly help you migrate to an App Gateway V2. If you do not have a support plan and would like to move forward with a support request, please Email me at [email protected] with your Subscription ID and a link to this post, and I will enable a one-time free support request for your subscription.

@TravisCragg-MSFT Thank you Travis, I really appreciate it a lot! Hey my colleague was able to find the MS scripts to migrate the V1 to V2 gateway and we were succesffully able to migrate it and attach the new custom rule (waf policy). Although what we found is when SSL is installed on the gateway these scripts for migrating gateway from V1 to V2 fail. But for now we are going ahead and provisioning new subnets and NSGs for V2 App Gateway and get it to work! Thank you again for your help!

No setting cookies

I'm sleeping no coo(he's

I got https too

In progress make in active

Delete in progress --

Thank you I just got here

Come on give me another com] and give me your meter read like always

Was this page helpful?
0 / 5 - 0 ratings