Web Application Firewall: Managed Rules, Traffic Detection, and Security Dashboard
How edge WAF detection and mitigation work, which rules to enable first, and how to monitor application security in the dashboard.
This page summarizes Cloudflare documentation on Application Security, centered on the Cloudflare Web Application Firewall (WAF). The WAF inspects incoming web and API requests at the edge, enriches them with security scores, and applies rulesets to block, challenge, or throttle unwanted traffic—often together with DDoS Protection, Bot Management, and Turnstile.
Cloudflare WAF: what it checks on each request
Section titled “Cloudflare WAF: what it checks on each request”The WAF is the main Layer 7 control for public sites and APIs proxied through Cloudflare. It filters traffic using rulesets written in the Rules language, which can match IP address, URL path, headers, body content, and scores from traffic detections.
The Cloudflare Web Application Firewall (Cloudflare WAF) checks incoming web and API requests and filters undesired traffic based on sets of rules called rulesets. The WAF uses the Rules language, a flexible expression syntax that lets you filter traffic by request properties such as IP address, URL path, headers, and body content.
— Cloudflare, Cloudflare Web Application Firewall
In plain terms: every HTTP request can be scored, compared to managed signatures, and acted on before it reaches your origin. The same pass can also apply performance and other security products; reference architecture describes requests being inspected once across security services at the closest data center.
| Component | Role |
|---|---|
| Managed rules | Pre-configured rulesets (e.g. OWASP, Cloudflare Managed) for known attack patterns and zero-day updates |
| Traffic detections | Metadata such as attack score and bot score on requests |
| Custom rules | Your expressions to block, challenge, or skip traffic |
| Rate limiting rules | Thresholds per client or path for brute force and abuse |
For a concise definition of what a WAF is in this stack, see WAF Concepts.
Detection versus mitigation: scores alone do not block traffic
Section titled “Detection versus mitigation: scores alone do not block traffic”Operators often enable detections and expect automatic blocking. Cloudflare separates finding risk from acting on it.
The two main roles of the Cloudflare WAF are the following:
Detection: Run incoming requests through one or more traffic detections to find malicious or potentially malicious activity. The scores from enabled detections are available in the Security Analytics dashboard, where you can analyze your security posture and determine the most appropriate mitigation rules.
Mitigation: Blocks, challenges, or throttles requests through different mitigation features such as custom rules, Managed Rules, and rate limiting rules. Rules that mitigate traffic can include scores from traffic scans in their expressions to better address possibly malicious requests.
— Cloudflare, Concepts
Use Security Analytics to study scored traffic, then wire scores into custom rules or rate limits.
Traffic detections available in Security Settings
Section titled “Traffic detections available in Security Settings”Detections are enabled under Security settings (Web application exploits category). Documented detections include:
| Detection | What it does (per docs) |
|---|---|
| Attack score | 1 (likely malicious) to 99 (unlikely); known attack variants and payloads |
| Leaked credentials | Usernames/passwords seen in known breaches |
| Malicious uploads | Malware-like signatures in uploaded content objects |
| AI Security for Apps | Abuse protection for LLM-powered services |
| Bot score | 1 (likely bot) to 99 (likely human) |
Definitions align with the WAF glossary (e.g. attack score, credential stuffing, rate limiting). Bot score and attack score availability in the Settings UI may differ by plan; the Concepts page notes you cannot manage bot score and attack score from Settings alone—see each feature’s documentation.
WAF attack score: when to block in a custom rule
Section titled “WAF attack score: when to block in a custom rule”WAF get started recommends complementing managed rules with attack-score-based custom rules on supported plans:
WAF attack score is a machine-learning layer that complements Cloudflare’s managed rulesets, providing additional protection against SQL injection ↗︎ (SQLi), cross-site scripting ↗︎ (XSS), and many remote code execution ↗︎ (RCE) attacks. It helps identify rule bypasses and potentially new, undiscovered attacks.
Enterprise: custom rule when WAF Attack Score is less than 20, action Block (after access from your account team).
Business: use WAF Attack Score Class (e.g. equals Attack) because full attack score field access is limited.
Attack score is not on all plans; Business and Enterprise are called out explicitly on the get-started page.
Managed rules and baseline protection after DNS proxying
Section titled “Managed rules and baseline protection after DNS proxying”Once DNS records are proxied, Cloudflare recommends enabling WAF rulesets. All plans get at least the Cloudflare Free Managed Ruleset for high-impact vulnerabilities (Enable WAF).
Block application attacks summarizes the managed-rules value:
Managed rulesets - Pre-configured rules covering OWASP Top 10 and emerging threats, updated by Cloudflare
Zero-day protection - Rules are updated as new vulnerabilities are discovered, with no action required from you
Custom rules - Block or challenge requests based on any request attribute including headers, cookies, and IP reputation
The OWASP Core Ruleset is configurable in the dashboard, API, or Terraform. Security settings lists Cloudflare managed ruleset and OWASP Core ruleset under Web application exploits.
WAF managed rules are described as mitigating zero-day issues, OWASP Top 10 techniques, stolen credentials, and sensitive data extraction—via deployable managed rulesets.
Common attacks: which Cloudflare products the docs map
Section titled “Common attacks: which Cloudflare products the docs map”Cloudflare Security Architecture ties attack types to products. Patterns that matter for WAF configuration:
| Attack | Documented mitigations |
|---|---|
| Credential stuffing | Bot Management, challenges (Cloudflare Challenges), WAF, Exposed Credentials Check managed ruleset, rate limiting |
| Brute force | Bot Management, challenges, WAF, rate limiting on login paths |
| XSS / injection | WAF ML and attack score; managed rules |
| Fuzzing / API scanning | WAF attack score, Bot Management, API Shield schema validation |
| Unauthorized API access | mTLS, JWT validation (API Shield), WAF path restrictions |
E-commerce and secure your application describe the same layered model: SSL/TLS, application security managed rules, bot security, Turnstile on forms, and client-side security for third-party scripts.
Login and form abuse: WAF plus Turnstile
Section titled “Login and form abuse: WAF plus Turnstile”For login and registration endpoints, server-side rate limiting catches direct POST abuse that never runs browser checks. Stop account takeover attacks states:
Turnstile verifies that visitors are human without showing a CAPTCHA. … Use Turnstile to challenge automated form submissions.
Application Security rate limiting rules define rate limits for requests matching an expression and the action to perform when those limits are reached. Use rate limiting to protect login endpoints from abuse, such as brute-force attacks.
Both together provide the strongest coverage.
Integrate Turnstile, WAF, & Bot Management explains the layers: WAF on network signals, Bot Management on automation, Turnstile on client/browser signals. Turnstile works on sites not on Cloudflare; WAF and Bot Management require proxied DNS.
Protect your forms from spam and abuse adds that custom rules run before rate limiting rules and managed rulesets in execution order—important when tuning form endpoints. See security features interoperability in related resources.
Account abuse (bots product)
Section titled “Account abuse (bots product)”Fraud detection / Account Abuse Protection (Early Access) targets bulk sign-up and account takeover with detections for account takeover, bulk creation, and credential quality, usable in Cloudflare Rules on sign-up and login endpoints. Prerequisites and full setup are on that product page; it extends bot/WAF thinking to account lifecycle abuse.
Application security dashboard: monitor, assets, rules, settings
Section titled “Application security dashboard: monitor, assets, rules, settings”The application security dashboard is the control plane for posture, analytics, assets, and rules.
The application security dashboard is your starting point to better understand the security posture of your web applications, and to configure rules to protect them.
— Cloudflare, Application security dashboard
The dashboard walkthrough maps main areas:
- Security overview — misconfigurations, detected threats, suggested improvements.
- Security Analytics — Traffic (all HTTP requests, including unaffected) vs Events (actions taken by security tools).
- Web assets — endpoint insights, schema validation against your API schema, client-side resources (scripts, connections, cookies).
- Security rules — custom rules, templates, and DDoS ruleset overrides when you need to change default DDoS behavior.
- Settings — detection tools grouped by threat type; use filters to find relevant controls (Security settings).
WAF Security Events and Security Analytics both support reviewing mitigated requests and tuning rules from sampled logs.
Get started: recommended first steps on a zone
Section titled “Get started: recommended first steps on a zone”Get started with WAF focuses on per-zone configuration (account-level rulesets are Enterprise with a paid add-on):
- Proxy the zone and enable at least the Free Managed Ruleset (Enable WAF).
- Turn on relevant detections under Security settings (e.g. leaked credentials, malicious uploads where available).
- Deploy OWASP / Cloudflare managed rulesets appropriate to your plan (managed rules).
- On Business or Enterprise, add an attack-score custom rule per get started.
- Add rate limiting on
/login, registration, and sensitive APIs; add Turnstile where browsers submit forms.
For multi-zone baselines and exceptions (legacy apps with false positives), see Streamlined WAF deployment across zones and applications. The application security learning path and Web Application Firewall module walk through components in more depth.
Additional WAF tools (edge policy, not a substitute for rulesets)
Section titled “Additional WAF tools (edge policy, not a substitute for rulesets)”WAF additional tools lists complements: IP Access rules, User Agent Blocking, Zone Lockdown, Browser Integrity Check, Security Level, lists, and related controls. These are useful for admin path lockdown (see WordPress security guidance) but do not replace managed and custom WAF rules for OWASP-class attacks.
SaaS providers can attach different WAF configurations per custom hostname—same rules language, scoped to customer domains.
Common mistakes
Section titled “Common mistakes”- Enabling attack score but no blocking rule — detections only enrich requests until a mitigation rule uses the score (Concepts).
- Rate limiting without WAF on forms — injection in fields is not solved by rate limits alone; use managed/custom rules (protect forms).
- Browser-only protection on login — bots that
POSTdirectly to the API need edge rate limiting (stop account takeover). - Tightening CMS security without admin exceptions — staged hardening may break admin login or uploads until exceptions exist (CMS security).
- Expecting attack score on Free/Pro — plan limits are explicit on WAF get started.
How to check this on your site
Section titled “How to check this on your site”- Open the Application security dashboard for your domain and review Security overview for misconfigurations and suggested actions.
- In Security Analytics, compare the Traffic and Events tabs to see raw volume versus mitigated requests (dashboard walkthrough).
- Confirm managed rulesets are enabled (Enable WAF) and inspect Security Events for rule matches (WAF).
- For login or form paths, verify rate limiting and Turnstile are active, then watch those endpoints in Events (stop account takeover).
- You can check automatically in Answerwell (our tool): https://answerwell.org/workspace
Report an error or ask a question
Section titled “Report an error or ask a question”If something on this page is wrong or unclear, email yimasynthetic@gmail.com with the page URL and the exact statement you are asking about.