What it is
The Web Application FirewallWAFWeb Application Firewall โ inspects web requests and blocks malicious ones (like SQL injection and XSS) before they reach your site. inspects every incoming HTTP request at Cloudflare's edgethe edgeโThe edgeโ means Cloudflare's servers spread across the world, close to your users โ as opposed to one central data center. and blocks application-layerL7Layer 7 โ the application (HTTP) layer, where smart, web-specific attacks happen. attacks โ SQL injectionSQL injectionAn attack that sneaks malicious database commands in through input fields to steal or damage data., cross-site scriptingXSSCross-Site Scripting โ an attack that injects malicious scripts into web pages other people view., and known CVECVECommon Vulnerabilities and Exposures โ a publicly catalogued security flaw, each with a unique ID. exploits โ using managed rulesetsmanaged rulesetA set of security rules that Cloudflare writes and keeps up to date for you, so you don't have to maintain them. that Cloudflare's threat intelligence keeps continuously up to date. Custom rules let you enforce your own business logic.
Why it helps the client
- Protection against the OWASP Top 10 and common web exploits out of the box.
- Virtual patching โ new CVEs are covered by managed rules automatically, often before you can patch.
- Custom rules with a no-regex expression builder for business-specific logic.
- Less load and risk on your origin, plus support for PCI-DSS requirements.
Why they'd want it
- Managed protection maintained by Cloudflare's view of ~20% of the web โ not a rule set you must babysit.
- Deploy in seconds with low false positives, and full logging of every action.
- One place to enforce both known-threat protection and custom guardrails.
๐ฌ How it actually works
- The WAFWAFWeb Application Firewall โ inspects web requests and blocks malicious ones (like SQL injection and XSS) before they reach your site. evaluates every proxied L7L7Layer 7 โ the application (HTTP) layer, where smart, web-specific attacks happen. request before it reaches originoriginYour own web server or host where your website actually lives. Cloudflare sits in front of it., running Cloudflare Managed Rulesmanaged rulesetA set of security rules that Cloudflare writes and keeps up to date for you, so you don't have to maintain them. (curated signatures for the OWASP Top 10OWASP Top 10The industry-standard list of the ten most critical web-application security risks, published by the OWASP nonprofit. and known CVEsCVECommon Vulnerabilities and Exposures โ a publicly catalogued security flaw, each with a unique ID.), the OWASP Core Ruleset (anomaly scoring), and your Custom Rules โ all through the same Ruleset Engine and wirefilter expression language.
- Custom Rules use a point-and-click expression builder over fields like URI, headers, method, IPIP addressA numeric address that identifies a device or server on the Internet., country, ASN, bot scorebot scoreCloudflare's 1โ99 rating of how likely a request came from a bot (1) versus a real human (99)., and threat score, with actions block, managed challenge, JS challenge, skip, or log. Regex is supported but not required.
- Managed Rulesmanaged rulesetA set of security rules that Cloudflare writes and keeps up to date for you, so you don't have to maintain them. are updated continuously by Cloudflare threat intelligence โ new high-profile CVEsCVECommon Vulnerabilities and Exposures โ a publicly catalogued security flaw, each with a unique ID. get emergency 'virtual patch' rules, often before customers can patch code. Any rule can run in Log mode first, then be switched to Block to tune false positives.
- Everything is observable in Security Events with full request detail and the matched rule, and rule changes deploy across all 330+ cities in seconds.
๐ Key terms on this page hover any underlined term anywhere on the site for its definition
- L7
- Layer 7 โ the application (HTTP) layer, where smart, web-specific attacks happen.
- origin
- Your own web server or host where your website actually lives. Cloudflare sits in front of it.
- SQL injection
- An attack that sneaks malicious database commands in through input fields to steal or damage data.
- the edge
- โThe edgeโ means Cloudflare's servers spread across the world, close to your users โ as opposed to one central data center.
- WAF
- Web Application Firewall โ inspects web requests and blocks malicious ones (like SQL injection and XSS) before they reach your site.
- XSS
- Cross-Site Scripting โ an attack that injects malicious scripts into web pages other people view.
- managed ruleset
- A set of security rules that Cloudflare writes and keeps up to date for you, so you don't have to maintain them.
- OWASP Top 10
- The industry-standard list of the ten most critical web-application security risks, published by the OWASP nonprofit.
- OWASP
- Open Worldwide Application Security Project โ a nonprofit best known for its โTop 10โ list of common web security risks.
- virtual patching
- Blocking exploitation of a known vulnerability with an edge rule before you've fixed the underlying code.
- CVE
- Common Vulnerabilities and Exposures โ a publicly catalogued security flaw, each with a unique ID.
- bot
- Automated software making requests instead of a human. Some bots are good (search engines); many are malicious.
- DDoS
- Distributed Denial of Service โ an attack that floods a site with junk traffic from many sources to knock it offline.
- IP address
- A numeric address that identifies a device or server on the Internet.
- bot score
- Cloudflare's 1โ99 rating of how likely a request came from a bot (1) versus a real human (99).
- PCI DSS
- Payment Card Industry Data Security Standard โ the security rules everyone handling credit-card data must follow.
Live demo walkthrough
6 stepsScreens below are annotated recreations of the Cloudflare dashboard. The numbered orange pin marks exactly where to click.
Select the website
Websites
Select a website to manage its configuration.
๐ Do this
Open the site you want to protect.
๐ฌ Say this
โSecurity in Cloudflare is configured per site. I'll open our demo site to walk through the application security stack, starting with the WAF.โ
Open Security โ WAF
Security
WAF
๐ Do this
Expand Security in the sidebar and click WAF.
๐ฌ Say this
โAll application security lives under Security. The WAF is our first line of defense at the application layer โ Layer 7.โ
Show the Managed Rulesets
Security
WAF
๐ Do this
Point to the Cloudflare Managed Ruleset, deployed and enabled.
๐ฌ Say this
โThese are Cloudflare-managed rules, updated by our threat intelligence drawn from a huge share of the web's traffic. When a new CVE drops, customers get virtual patching automatically โ usually before their own teams can deploy a fix.โ
Add a custom rule
Security
WAF › Create custom rule
๐ Do this
Build an expression, then set the Action to Block and Deploy.
๐ฌ Say this
โFor business-specific logic we add custom rules with a point-and-click builder โ no regex. Here: block anyone hitting /admin from outside our office IPs. Choose the action, hit Deploy, and it's live at the edge in seconds.โ
Review Security Events
Security
Events
๐ Do this
Open Events and filter to WAF actions.
๐ฌ Say this
โEvery action is logged in real time. We can show the customer exactly what we blocked, why, and from where โ perfect for reporting and tuning.โ
Zoom out to Security Analytics
Security
Analytics
๐ Do this
Open Security โ Analytics to show the aggregate view across all security products.
๐ฌ Say this
โAnd here's the executive view: total requests versus mitigated, broken down by service and rule. It ties the whole security story together โ WAF, bots, rate limiting, and DDoS โ in one board-ready chart.โ