Web Application Firewall (WAF) is a security solution that monitors, filters, and blocks HTTP/HTTPS traffic to and from a web application. WAFs protect against common attacks like XSS, SQL injection, and other OWASP Top 10 threats.
# Reverse proxy (inline)
Client → WAF → Application Server
# Out-of-band (monitoring only)
Client → Application Server
↓ (copy)
WAF
# Cloud-based
Client → Cloudflare/AWS WAF → Application
# SQL Injection patterns
' OR '1'='1
UNION SELECT
# XSS patterns
<script>
javascript:
# Path traversal
../../../etc/passwd
# Command injection
; cat /etc/passwd