Azure ARM Templates - Appication Gateway Web Application Firewall Configuration SelectorMatchOperator Syntax

292 views Asked by At

I'm using an ARM template for creating an application gateway in Azure. When creating the web application firewall configuration section I'm adding exclusions in the firewall. One of the exclusions I'm trying to add has an operator of "Equals any". I know the syntax for Equals, contains, StartsWith and EndsWith but I cannot figure out what needs to be put for "Equals Any".

I have tried the below examples but the ARM template fails validation for them due to the SelectorMatchOperator being unsupported. If anyone knows the syntax for "Equals any" in the ARM template I'd greatly appreciate it. Thanks.

{
  "matchVariable": "RequestCookieNames",
  "selectorMatchOperator": "EqualsAny",
  "selector": "*"
}

{
  "matchVariable": "RequestCookieNames",
  "selectorMatchOperator": "Equals_Any",
  "selector": "*"
}

{
  "matchVariable": "RequestCookieNames",
  "selectorMatchOperator": "Equals Any",
  "selector": "*"
}

{
  "matchVariable": "RequestCookieNames",
  "selectorMatchOperator": "*",
  "selector": "*"
}

{
  "matchVariable": "RequestCookieNames",
  "selectorMatchOperator": "Any",
  "selector": "*"
}
1

There are 1 answers

0
BigNull On

For anyone else looking into this. The exclusion needs to be setup like below to have an "Equals any" exclusion.

{
  "matchVariable": "RequestCookieNames",
  "selectorMatchOperator": "",
  "selector": ""
}