Rift NGINX Vulnerability

Date: May 13, 2026
CVSS 3.0: 8.1 (High)

What is Rift?

Rift is a vulnerability in the ngx_http_rewrite module. An unauthorized user can exploit this vulnerability by sending crafted HTTP requests. This can cause a heap buffer overflow in the NGINX worker process, leading to a restart and resulting in a denial-of-service condition. This may also allow remote code execution by overflowing into adjacent heap memory.

The affected versions are:

  • NGINX Open Source 0.6.27 - 1.30.0
  • NGINX Plus R32 - R36
  • NGINX Instance Manager 2.16.0 - 2.21.1
  • F5 WAF for NGINX 5.9.0 - 5.12.1
  • NGINX App Protect WAF 4.9.0 - 4.16.0 and 5.1.0 - 5.8.0
  • F5 DoS for NGINX 4.8.0
  • NGINX App Protect DoS 4.3.0 - 4.7.0
  • NGINX Gateway Fabric 1.3.0 - 1.6.2 and 2.0.0 - 2.5.1
  • NGINX Ingress Controller 3.5.0 - 3.7.2, 4.0.0 - 4.0.1, and 5.0.0 - 5.4.1

Disclosure Information

DepthFirst and F5, the parent company of NGINX, disclosed the vulnerability on May 13, 2026. DepthFirst used its autonomous, AI-driven analysis system to scan the NGINX source code, discovering the vulnerability in about six hours. As of May 2026, there are no confirmed reports of Rift being actively exploited in the wild.

How It Works

This exploit works by abusing configurations where an if, set, or rewrite directive uses an unnamed PCRE capture group together with a question mark quantifier. NGINX computes the memory buffer size needed for a rewritten URL. During the length calculation, it uses an unescaped length, but during the copy pass, it uses escaped characters.

Special characters in the attacker's URI expand into multi-byte escaped sequences during the copy pass. Because the buffer was sized for unescaped data, the additional escaped bytes overflow into adjacent heap memory.

Mitigation Steps

NGINX has released updates for both the open source packages, versions 1.30.1 and 1.31.0, and NGINX Plus packages, versions R36 P4 and R32 P6. If the server cannot be taken offline, the configuration can be manually updated by replacing vulnerable unnamed capture groups with named capture groups. This safely bypasses the vulnerable code path.

Sources



Loading...