INTEGRITY Cloudflare Docs

Managed Rules

Cloudflare provides pre-configured managed rulesets that protect against web application exploits such as the following:

Managed rulesets are regularly updated. Each rule has a default action that varies according to the severity of the rule. You can adjust the behavior of specific rules, choosing from several possible actions.

Rules of managed rulesets have associated tags (such as wordpress) that allow you to search for a specific group of rules and configure them in bulk.

Available managed rulesets

The following managed rulesets run in a response phase:

Availability

The managed rulesets you can deploy depend on your Cloudflare plan.

Free Pro Business Enterprise
Availability Yes Yes Yes Yes
Free Managed Ruleset Yes Yes Yes Yes
Cloudflare Managed Ruleset No Yes Yes Yes
Cloudflare OWASP Core Ruleset No Yes Yes Yes
Cloudflare Exposed Credentials Check (deprecated) No Yes Yes Yes
Cloudflare Sensitive Data Detection No No No Yes

Customize the behavior of managed rulesets

To customize the behavior of managed rulesets, do one of the following:

Exceptions have priority over overrides.

Interaction with other app security features

If you are using several app security features like custom rules, Managed Rules, and Super Bot Fight Mode, it is important to understand how these features interact and the order in which they execute. Refer to Security features interoperability for more information.

Important remarks

Maximum body size

Managed rules inspect the body of each incoming request up to a maximum size. This limit varies by plan:

Request content beyond this limit may not be fully analyzed, which can affect how managed rules behave. For example, the OWASP Core Ruleset calculates a cumulative threat score based on the scores of individual rules that match a request. Larger payloads give more content for rules to match against, which increases the score and makes it more likely to exceed the score threshold — resulting in a false positive.

If included in your plan, you can use request body fields in custom rules to apply appropriate actions to requests that have not been fully analyzed. The http.request.body.truncated field indicates whether the request body was truncated, while http.request.headers.truncated indicates whether the request contained too many headers for all of them to be included.

Zone-level deployment

At the zone level, you can deploy each managed ruleset once. At the account level, you can deploy each managed ruleset multiple times, which allows you to apply different configurations of the same ruleset to different subsets of incoming traffic.

Execution order

WAF Managed Rules run in the http_request_firewall_managed phase, which executes after:

This means a rule with a terminal action (such as Block or Managed Challenge) in any of these earlier phases prevents Managed Rules from evaluating that request. For the complete security feature execution order, refer to Security features interoperability.

WAF exceptions

WAF exceptions (skip rules) are rules with a skip action deployed to the http_request_firewall_managed phase entry-point ruleset. They are evaluated in list order within the entry-point ruleset — a skip rule only bypasses execute rules listed after it. Place exceptions before the managed ruleset execute rules they are intended to skip. For more information, refer to WAF exceptions.