You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
title: Web application firewall request size limits and exclusion lists in Azure Application Gateway - Azure portal
3
-
description: This article provides information on Web Application Firewall request size limits and exclusion lists configuration in Application Gateway with the Azure portal.
2
+
title: Web application firewall exclusion lists in Azure Application Gateway - Azure portal
3
+
description: This article provides information on Web Application Firewall exclusion lists configuration in Application Gateway with the Azure portal.
4
4
services: web-application-firewall
5
5
author: vhorne
6
6
ms.service: web-application-firewall
7
-
ms.date: 02/10/2022
7
+
ms.date: 03/08/2022
8
8
ms.author: victorh
9
9
ms.topic: conceptual
10
10
ms.custom: devx-track-azurepowershell
11
11
---
12
12
13
-
# Web Application Firewall request size limits and exclusion lists
13
+
# Web Application Firewall exclusion lists
14
14
15
-
The Azure Application Gateway Web Application Firewall (WAF) provides protection for web applications. This article describes WAF request size limits and exclusion lists configuration. These settings are located in the WAF Policy associated to your Application Gateway. To learn more about WAF Policies, see [Azure Web Application Firewall on Azure Application Gateway](ag-overview.md) and [Create Web Application Firewall policies for Application Gateway](create-waf-policy-ag.md)
The Azure Application Gateway Web Application Firewall (WAF) provides protection for web applications. This article describes the configuration for WAF exclusion lists. These settings are located in the WAF Policy associated to your Application Gateway. To learn more about WAF Policies, see [Azure Web Application Firewall on Azure Application Gateway](ag-overview.md) and [Create Web Application Firewall policies for Application Gateway](create-waf-policy-ag.md)
20
16
21
17
Sometimes Web Application Firewall (WAF) might block a request that you want to allow for your application. WAF exclusion lists allow you to omit certain request attributes from a WAF evaluation. The rest of the request is evaluated as normal.
22
18
23
19
For example, Active Directory inserts tokens that are used for authentication. When used in a request header, these tokens can contain special characters that may trigger a false positive from the WAF rules. By adding the header to an exclusion list, you can configure WAF to ignore the header, but WAF still evaluates the rest of the request.
24
20
25
21
Exclusion lists are global in scope.
26
22
23
+
To set exclusion lists in the Azure portal, configure **Exclusions** in the WAF policy resource's **Policy settings** page:
24
+
25
+

26
+
27
+
## Attributes
28
+
27
29
The following attributes can be added to exclusion lists by name. The values of the chosen field aren't evaluated against WAF rules, but their names still are (see Example 1 below, the value of the User-Agent header is excluded from WAF evaluation). The exclusion lists remove inspection of the field's value.
28
30
29
31
* Request Headers
@@ -49,13 +51,13 @@ In all cases matching is case insensitive and regular expression aren't allowed
49
51
> [!NOTE]
50
52
> For more information and troubleshooting help, see [WAF troubleshooting](web-application-firewall-troubleshoot.md).
The following examples demonstrate the use of exclusions.
57
59
58
-
####Example 1
60
+
### Example 1
59
61
60
62
In this example, you want to exclude the user-agent header. The user-agent request header contains a characteristic string that allows the network protocol peers to identify the application type, operating system, software vendor, or software version of the requesting software user agent. For more information, see [User-Agent](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent).
This example excludes the value in the *user* parameter that is passed in the request via the URL. For example, say it’s common in your environment for the user field to contain a string that the WAF views as malicious content, so it blocks it. You can exclude the user parameter in this case so that the WAF doesn't evaluate anything in the field.
So if the URL `http://www.contoso.com/?user%281%29=fdafdasfda` is passed to the WAF, it won't evaluate the string **fdafdasfda**, but it will still evaluate the parameter name **user%281%29**.
85
87
86
-
## WAF request size limits
87
-
88
-
89
-
90
-
Web Application Firewall allows you to configure request size limits within lower and upper bounds. The following two size limits configurations are available:
91
-
92
-
- The maximum request body size field is specified in kilobytes and controls overall request size limit excluding any file uploads. This field has a minimum value of 8 KB and a maximum value of 128 KB. The default value for request body size is 128 KB.
93
-
- The file upload limit field is specified in MB and it governs the maximum allowed file upload size. This field can have a minimum value of 1 MB and the following maximums:
94
-
95
-
- 100 MB for v1 Medium WAF gateways
96
-
- 500 MB for v1 Large WAF gateways
97
-
- 750 MB for v2 WAF gateways
98
-
99
-
The default value for file upload limit is 100 MB.
100
-
101
-
For CRS 3.2 (on the WAF_v2 SKU) and newer, these limits are as follows when using a WAF Policy for Appplication Gateway:
102
-
103
-
- 2MB request body size limit
104
-
- 4GB file upload limit
105
-
106
-
WAF also offers a configurable knob to turn the request body inspection on or off. By default, the request body inspection is enabled. If the request body inspection is turned off, WAF doesn't evaluate the contents of HTTP message body. In such cases, WAF continues to enforce WAF rules on headers, cookies, and URI. If the request body inspection is turned off, then maximum request body size field isn't applicable and can't be set. Turning off the request body inspection allows for messages larger than 128 KB to be sent to WAF, but the message body isn't inspected for vulnerabilities.
107
-
108
88
## Next steps
109
89
110
90
After you configure your WAF settings, you can learn how to view your WAF logs. For more information, see [Application Gateway diagnostics](../../application-gateway/application-gateway-diagnostics.md#diagnostic-logging).
title: Web application firewall request size limits in Azure Application Gateway - Azure portal
3
+
description: This article provides information on Web Application Firewall request size limits in Application Gateway with the Azure portal.
4
+
services: web-application-firewall
5
+
author: vhorne
6
+
ms.service: web-application-firewall
7
+
ms.date: 03/08/2022
8
+
ms.author: victorh
9
+
ms.topic: conceptual
10
+
ms.custom: devx-track-azurepowershell
11
+
---
12
+
13
+
# Web Application Firewall request size limits
14
+
15
+
Web Application Firewall allows you to configure request size limits within lower and upper bounds.
16
+
17
+
Request size limits are global in scope.
18
+
19
+
## Limits
20
+
21
+
The following two size limits configurations are available:
22
+
23
+
- The maximum request body size field is specified in kilobytes and controls overall request size limit excluding any file uploads. This field has a minimum value of 8 KB and a maximum value of 128 KB. The default value for request body size is 128 KB.
24
+
- The file upload limit field is specified in MB and it governs the maximum allowed file upload size. This field can have a minimum value of 1 MB and the following maximums:
25
+
26
+
- 100 MB for v1 Medium WAF gateways
27
+
- 500 MB for v1 Large WAF gateways
28
+
- 750 MB for v2 WAF gateways
29
+
30
+
The default value for file upload limit is 100 MB.
31
+
32
+
For CRS 3.2 (on the WAF_v2 SKU) and newer, these limits are as follows when using a WAF policy for Appplication Gateway:
33
+
34
+
- 2MB request body size limit
35
+
- 4GB file upload limit
36
+
37
+
To set request size limits in the Azure portal, configure **Global parameters** in the WAF policy resource's **Policy settings** page:
38
+
39
+

40
+
41
+
## Request body inspection
42
+
43
+
WAF offers a configuration setting to enable or disable the request body inspection. By default, the request body inspection is enabled. If the request body inspection is disabled, WAF doesn't evaluate the contents of an HTTP message's body. In such cases, WAF continues to enforce WAF rules on headers, cookies, and URI. If the request body inspection is turned off, then maximum request body size field isn't applicable and can't be set.
44
+
45
+
Turning off the request body inspection allows for messages larger than 128 KB to be sent to WAF, but the message body isn't inspected for vulnerabilities.
46
+
47
+
When your WAF receives a request that's over the size limit, the behavior depends on the mode of your WAF and the version of the managed ruleset you use.
48
+
- When your WAF policy is in prevention mode, WAF blocks requests that are over the size limit.
49
+
- When your WAF policy is in detection mode:
50
+
- If you use CRS 3.2 or newer, WAF inspects the body up to the limit specified and ignores the rest.
51
+
- If you use CRS 3.1 or earlier, WAF inspects the entire message.
52
+
53
+
## Next steps
54
+
55
+
After you configure your WAF settings, you can learn how to view your WAF logs. For more information, see [Application Gateway diagnostics](../../application-gateway/application-gateway-diagnostics.md#diagnostic-logging).
Copy file name to clipboardExpand all lines: articles/web-application-firewall/ag/web-application-firewall-troubleshoot.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -136,7 +136,7 @@ With this information, and the knowledge that rule 942130 is the one that matche
136
136
137
137
- Use an Exclusion List
138
138
139
-
See [WAF configuration](application-gateway-waf-configuration.md#waf-exclusion-lists) for more information about exclusion lists.
139
+
See [WAF configuration](application-gateway-waf-configuration.md) for more information about exclusion lists.
140
140
- Disable the rule.
141
141
142
142
### Using an exclusion list
@@ -171,7 +171,7 @@ In this example, you can see that the field where the *1=1* string was entered i
171
171
172
172
:::image type="content" source="../media/web-application-firewall-troubleshoot/fiddler-1.png" alt-text="Screenshot of the Progress Telerik Fiddler Web Debugger. In the Raw tab, 1 = 1 is visible after the name text1." border="false":::
173
173
174
-
This is a field you can exclude. To learn more about exclusion lists, See [Web application firewall request size limits and exclusion lists](application-gateway-waf-configuration.md#waf-exclusion-lists). You can exclude the evaluation in this case by configuring the following exclusion:
174
+
This is a field you can exclude. To learn more about exclusion lists, See [Web application firewall exclusion lists](application-gateway-waf-configuration.md). You can exclude the evaluation in this case by configuring the following exclusion:
0 commit comments