# CVE-2025-57822: Next.js Improper Middleware Redirect Handling Leads to SSRF - Exploited (CISA KEV): no - Published: 2025-08-29 - CVSS: 6.5 MEDIUM (v3.1) - EPSS: 2.6% (85th percentile) - CWE: CWE-918 Next.js is a React framework for building full-stack web applications. Prior to versions 14.2.32 and 15.4.7, when next() was used without explicitly passing the request object, it could lead to SSRF in self-hosted applications that incorrectly forwarded user-supplied headers. This vulnerability has been fixed in Next.js versions 14.2.32 and 15.4.7. All users implementing custom middleware logic in self-hosted environments are strongly encouraged to upgrade and verify correct usage of the next() function. ## Edge WAF coverage (claimed by vendors, not measured) | Vendor | Status | First rule | Days after publication | |---|---|---|---| | Cloudflare | Blocks by default | 2025-09-08 | 10 | | AWS | No public claim | — | — | | Microsoft Azure | No public claim | — | — | | Google Cloud | No public claim | — | — | | Fastly | Before feed history | — | — | | F5 | No public claim | — | — | | Akamai | No public source | — | — | | OWASP CRS | No public claim | — | — | ### Cloudflare - 2025-09-08 · new · rule cd528243d6824f7ab56182988230a75b · default Block > Next.js - SSRF - CVE:CVE-2025-57822. Previous action: Log. New action: Block. This is a New Detection Source: https://developers.cloudflare.com/changelog/post/2025-09-08-waf-release/ ## Our test (measured) - OWASP Core Rule Set 4.25.0, paranoia level 1, anomaly threshold 5, default CRS settings: passed (0 of 2 requests blocked), template CVE-2025-57822, 2026-11-02 - OWASP Core Rule Set 4.25.0, paranoia level 2, anomaly threshold 5, default CRS settings: passed (0 of 2 requests blocked), template CVE-2025-57822, 2026-11-02 "No public claim" means no vendor statement names this CVE; "Before feed history" means the CVE is older than the vendor feed. In both cases generic rules may still block it. HTML: https://cve.vigilbase.com/cve/CVE-2025-57822 · JSON: https://cve.vigilbase.com/api/v1/cves/CVE-2025-57822