Missing Nginx Rate Limiting Configuration
ID: file-missing-nginx-rate-limiting
Severity: medium
Author: pussycat0x
Tags: audit,file,nginx,hardening
Description
Section titled “Description”Ensures that rate limiting is properly configured in Nginx to prevent excessive requests from a single client.
YAML Source
Section titled “YAML Source”id: file-missing-nginx-rate-limiting
info: name: Missing Nginx Rate Limiting Configuration author: pussycat0x severity: medium description: | Ensures that rate limiting is properly configured in Nginx to prevent excessive requests from a single client. remediation: | Add 'limit_req_zone $binary_remote_addr zone=mylimit:10m rate=10r/s;' in /etc/nginx/nginx.conf. reference: - https://wiki.devsecopsguides.com/docs/checklists/mongodb/ - https://nginx.org/en/docs/http/ngx_http_limit_req_module.html metadata: verified: true tags: audit,file,nginx,hardening
file: - extensions: - conf
matchers-condition: and matchers: - type: word words: - "http" - "events" condition: and
- type: word words: - "limit_req_zone $binary_remote_addr zone=" - "rate=" condition: and negative: true# digest: 4a0a00473045022100876d7bd496d8aafd74b3cc2879968f46d1dab56f86072bcee7a3d3fc4619579d022030b12c854fafb64fb3041a91ead557252c322011a37e9f602cf11b177078eb39:922c64590222798bb761d5b6d8e72950Guide to check the vulnerabilities
Section titled “Guide to check the vulnerabilities”This template is used to detect vulnerabilities in web applications. It can be used with the Nuclei tool to scan for specific patterns or behaviors.
$ nuclei -u "URL" -t "file/audit/nginx/file-nginx-rate-limiting.yaml"