Web Application Firewall DRS rule groups and rules
Article
32 minutes to read
Azure Front Door web application firewall (WAF) protects web applications from common vulnerabilities and exploits. Azure-managed rule sets provide an easy way to deploy protection against a common set of security threats. Since such rule sets are managed by Azure, the rules are updated as needed to protect against new attack signatures. Default rule set also includes the Microsoft Threat Intelligence Collection rules that are written in partnership with the Microsoft Intelligence team to provide increased coverage, patches for specific vulnerabilities, and better false positive reduction.
Default rule sets
The Azure-managed Default Rule Set (DRS) includes rules against the following threat categories:
Cross-site scripting
Java attacks
Local file inclusion
PHP injection attacks
Remote command execution
Remote file inclusion
Session fixation
SQL injection protection
Protocol attackers
The version number of the DRS increments when new attack signatures are added to the rule set.
DRS is enabled by default in Detection mode in your WAF policies. You can disable or enable individual rules within the Default Rule Set to meet your application requirements. You can also set specific actions per rule. The available actions are: Allow, Block, Log, and Redirect.
Sometimes you might need to omit certain request attributes from a WAF evaluation. A common example is Active Directory-inserted tokens that are used for authentication. You may configure an exclusion list for a managed rule, rule group, or for the entire rule set. For more information, see Web Application Firewall (WAF) with Front Door exclusion lists.
By default, DRS versions 2.0 and above will leverage anomaly scoring when a request matches a rule, DRS versions earlier than 2.0 blocks requests that trigger the rules. Additionally, custom rules can be configured in the same WAF policy if you wish to bypass any of the pre-configured rules in the Default Rule Set.
Custom rules are always applied before rules in the Default Rule Set are evaluated. If a request matches a custom rule, the corresponding rule action is applied. The request is either blocked or passed through to the back-end. No other custom rules or the rules in the Default Rule Set are processed. You can also remove the Default Rule Set from your WAF policies.
Microsoft Threat Intelligence Collection rules
The Microsoft Threat Intelligence Collection rules are written in partnership with the Microsoft Threat Intelligence team to provide increased coverage, patches for specific vulnerabilities, and better false positive reduction.
Some of the built-in DRS rules are disabled by default because they've been replaced by newer rules in the Microsoft Threat Intelligence Collection. For example, rule ID 942440, SQL Comment Sequence Detected., has been disabled, and replaced by the Microsoft Threat Intelligence Collection rule 99031002. The replaced rule reduces the risk of false positive detections from legitimate requests.
Anomaly scoring
When you use DRS 2.0 or later, your WAF uses anomaly scoring. Traffic that matches any rule isn't immediately blocked, even when your WAF is in prevention mode. Instead, the OWASP rule sets define a severity for each rule: Critical, Error, Warning, or Notice. The severity affects a numeric value for the request, which is called the anomaly score:
Rule severity
Value contributed to anomaly score
Critical
5
Error
4
Warning
3
Notice
2
If the anomaly score is 5 or greater, WAF blocks the request.
For example, a single Critical rule match is enough for the WAF to block a request, because the overall anomaly score is 5. However, one Warning rule match only increases the anomaly score by 3, which isn't enough by itself to block the traffic.
When your WAF uses older version of the default rule set (before DRS 2.0), your WAF runs in the traditional mode. Traffic that matches any rule is considered independently of any other rule matches. In traditional mode, you don't have visibility into the complete set of rules that a specific request matched.
The version of the DRS that you use also determines which content types are supported for request body inspection. For more information, see What content types does WAF support? in the FAQ.
DRS 2.1
DRS 2.1 rules offer better protection than earlier versions of the DRS. It includes additional rules developed by the Microsoft Threat Intelligence team and updates to signatures to reduce false positives. It also supports transformations beyond just URL decoding.
DRS 2.1 includes 17 rule groups, as shown in the following table. Each group contains multiple rules, and you can customize behavior for individual rules, rule groups, or entire rule set. For more information, see Tuning Web Application Firewall (WAF) for Azure Front Door.
Note
DRS 2.1 is only available on Azure Front Door Premium.
Restricted SQL Character Anomaly Detection (args): # of special characters exceeded (12)
Too many false positives.
942440
SQLI
SQL Comment Sequence Detected
Replaced by MSTIC rule 99031002
99005006
MS-ThreatIntel-WebShells
Spring4Shell Interaction Attempt
Enable rule to prevent against SpringShell vulnerability
99001014
MS-ThreatIntel-CVEs
Attempted Spring Cloud routing-expression injection CVE-2022-22963
Enable rule to prevent against SpringShell vulnerability
99001015
MS-ThreatIntel-WebShells
Attempted Spring Framework unsafe class object exploitation CVE-2022-22965
Enable rule to prevent against SpringShell vulnerability
99001016
MS-ThreatIntel-WebShells
Attempted Spring Cloud Gateway Actuator injection CVE-2022-22947
Enable rule to prevent against SpringShell vulnerability
DRS 2.0
DRS 2.0 rules offer better protection than earlier versions of the DRS. It also supports transformations beyond just URL decoding.
DRS 2.0 includes 17 rule groups, as shown in the following table. Each group contains multiple rules, and you can disable individual rules as well as entire rule groups.
Note
DRS 2.0 is only available on Azure Front Door Premium.
This article contains references to the term blacklist, a term that Microsoft no longer uses. When the term is removed from the software, we’ll remove it from this article.
SQLI - SQL Injection
RuleId
Description
942100
SQL Injection Attack Detected via libinjection
942110
SQL Injection Attack: Common Injection Testing Detected
942120
SQL Injection Attack: SQL Operator Detected
942140
SQL Injection Attack: Common DB Names Detected
942150
SQL Injection Attack
942160
Detects blind sqli tests using sleep() or benchmark().
942170
Detects SQL benchmark and sleep injection attempts including conditional queries
Attempted SharePoint insecure XML deserialization CVE-2019-0604
99001014
Attempted Spring Cloud routing-expression injection CVE-2022-22963
99001015
Attempted Spring Framework unsafe class object exploitation CVE-2022-22965
99001016
Attempted Spring Cloud Gateway Actuator injection CVE-2022-22947
Note
When reviewing your WAF's logs, you might see rule ID 949110. The description of the rule might include Inbound Anomaly Score Exceeded.
This rule indicates that the total anomaly score for the request exceeded the maximum allowable score. For more information, see Anomaly scoring.
When you tune your WAF policies, you need to investigate the other rules that were triggered by the request so that you can adjust your WAF's configuration. For more information, see Tuning Web Application Firewall (WAF) for Azure Front Door.
2.0 rule sets
General
RuleId
Description
200002
Failed to parse request body.
200003
Multipart request body failed strict validation
METHOD ENFORCEMENT
RuleId
Description
911100
Method is not allowed by policy
PROTOCOL-ENFORCEMENT
RuleId
Description
920100
Invalid HTTP Request Line
920120
Attempted multipart/form-data bypass
920121
Attempted multipart/form-data bypass
920160
Content-Length HTTP header is not numeric.
920170
GET or HEAD Request with Body Content.
920171
GET or HEAD Request with Transfer-Encoding.
920180
POST request missing Content-Length Header.
920190
Range: Invalid Last Byte Value.
920200
Range: Too many fields (6 or more)
920201
Range: Too many fields for pdf request (35 or more)
920210
Multiple/Conflicting Connection Header Data Found.
920220
URL Encoding Abuse Attack Attempt
920230
Multiple URL Encoding Detected
920240
URL Encoding Abuse Attack Attempt
920260
Unicode Full/Half Width Abuse Attack Attempt
920270
Invalid character in request (null character)
920271
Invalid character in request (non printable characters)
920280
Request Missing a Host Header
920290
Empty Host Header
920300
Request Missing an Accept Header
920310
Request Has an Empty Accept Header
920311
Request Has an Empty Accept Header
920320
Missing User Agent Header
920330
Empty User Agent Header
920340
Request Containing Content, but Missing Content-Type header
This article contains references to the term blacklist, a term that Microsoft no longer uses. When the term is removed from the software, we’ll remove it from this article.
SQLI - SQL Injection
RuleId
Description
942100
SQL Injection Attack Detected via libinjection
942110
SQL Injection Attack: Common Injection Testing Detected
942120
SQL Injection Attack: SQL Operator Detected
942140
SQL Injection Attack: Common DB Names Detected
942150
SQL Injection Attack
942160
Detects blind sqli tests using sleep() or benchmark().
942170
Detects SQL benchmark and sleep injection attempts including conditional queries
Path Traversal Evasion in Request Body (/.././../)
MS-ThreatIntel-SQLI
RuleId
Description
99031001
SQL Injection Attack: Common Injection Testing Detected
99031002
SQL Comment Sequence Detected.
MS-ThreatIntel-CVEs
RuleId
Description
99001001
Attempted F5 tmui (CVE-2020-5902) REST API Exploitation with known credentials
99001014
Attempted Spring Cloud routing-expression injection CVE-2022-22963
99001015
Attempted Spring Framework unsafe class object exploitation CVE-2022-22965
99001016
Attempted Spring Cloud Gateway Actuator injection CVE-2022-22947
Note
When reviewing your WAF's logs, you might see rule ID 949110. The description of the rule might include Inbound Anomaly Score Exceeded.
This rule indicates that the total anomaly score for the request exceeded the maximum allowable score. For more information, see Anomaly scoring.
When you tune your WAF policies, you need to investigate the other rules that were triggered by the request so that you can adjust your WAF's configuration. For more information, see Tuning Web Application Firewall (WAF) for Azure Front Door.
1.1 rule sets
PROTOCOL-ATTACK
RuleId
Description
921110
HTTP Request Smuggling Attack
921120
HTTP Response Splitting Attack
921130
HTTP Response Splitting Attack
921140
HTTP Header Injection Attack via headers
921150
HTTP Header Injection Attack via payload (CR/LF detected)
921151
HTTP Header Injection Attack via payload (CR/LF detected)
921160
HTTP Header Injection Attack via payload (CR/LF and header-name detected)
LFI - Local File Inclusion
RuleId
Description
930100
Path Traversal Attack (/../)
930110
Path Traversal Attack (/../)
930120
OS File Access Attempt
930130
Restricted File Access Attempt
RFI - Remote File Inclusion
RuleId
Description
931100
Possible Remote File Inclusion (RFI) Attack: URL Parameter using IP Address
931110
Possible Remote File Inclusion (RFI) Attack: Common RFI Vulnerable Parameter Name used w/URL Payload
931120
Possible Remote File Inclusion (RFI) Attack: URL Payload Used w/Trailing Question Mark Character (?)
931130
Possible Remote File Inclusion (RFI) Attack: Off-Domain Reference/Link
RCE - Remote Command Execution
RuleId
Description
932100
Remote Command Execution: Unix Command Injection
932105
Remote Command Execution: Unix Command Injection
932110
Remote Command Execution: Windows Command Injection
932115
Remote Command Execution: Windows Command Injection
931120
Remote Command Execution: Windows PowerShell Command Found
932130
Remote Command Execution: Unix Shell Expression or Confluence Vulnerability (CVE-2022-26134) or Text4Shell (CVE-2022-42889) Found
932140
Remote Command Execution: Windows FOR/IF Command Found
932150
Remote Command Execution: Direct Unix Command Execution
This article contains references to the term blacklist, a term that Microsoft no longer uses. When the term is removed from the software, we’ll remove it from this article.
SQLI - SQL Injection
RuleId
Description
942100
SQL Injection Attack Detected via libinjection
942110
SQL Injection Attack: Common Injection Testing Detected
942120
SQL Injection Attack: SQL Operator Detected
942140
SQL Injection Attack: Common DB Names Detected
942150
SQL Injection Attack
942160
Detects blind sqli tests using sleep() or benchmark().
942170
Detects SQL benchmark and sleep injection attempts including conditional queries
This article contains references to the term blacklist, a term that Microsoft no longer uses. When the term is removed from the software, we’ll remove it from this article.
SQLI - SQL Injection
RuleId
Description
942100
SQL Injection Attack Detected via libinjection
942110
SQL Injection Attack: Common Injection Testing Detected
942120
SQL Injection Attack: SQL Operator Detected
942140
SQL Injection Attack: Common DB Names Detected
942150
SQL Injection Attack
942160
Detects blind sqli tests using sleep() or benchmark().
942170
Detects SQL benchmark and sleep injection attempts including conditional queries