mirror of
https://github.com/fabriziosalmi/patterns.git
synced 2025-12-17 17:55:48 +00:00
722 B
722 B
Nginx WAF Rule Snippets
This directory contains Nginx WAF rule snippets generated from OWASP rules. You can include these snippets in your existing Nginx configuration to enhance security.
Usage
- Include the rule snippets in your
serverorlocationblock:server { # Your existing configuration include /path/to/waf_patterns/nginx/*.conf; } - Reload Nginx to apply the changes:
sudo nginx -t && sudo systemctl reload nginx
Notes
- The rules use
mapdirectives for efficient pattern matching. - Blocked requests return a
403 Forbiddenresponse by default. - You can enable logging for blocked requests by uncommenting the
access_logline.