OpenAI is partnering with Hacktron to find vulnerabilities in its systems. Read the announcement.

Skip to content Hacktron Sign in [S]
Hacktron Sign in [S] Customers Docs Contact Sign in

nginx2root: RCE in nginx


Hacktron Team

, , X, LinkedIn

Share

nginx2root: RCE in nginx

XLinkedIn
8 min

nginx2root is Xint’s name for five nginx vulnerabilities and a separate Linux kernel flaw. Each nginx vulnerability can lead to code execution as the nginx worker, under a specific configuration. CVE-2026-123007 affects unpatched nginx builds with HTTP/2 enabled and has been in nginx since 2015. Xint chained it with the kernel flaw to get root on the host, including from inside a Docker container where SCTP was reachable. Fixes shipped on 18 November 2026 in nginx 1.31.9 and 1.30.7.

Who is affected

Each nginx vulnerability is a separate attack path. The table lists the first affected upstream release, from F5’s advisories. Fixed releases are 1.30.7 on stable and 1.31.9 on mainline; distribution backports may also contain the fixes.

CVE Affected configuration First affected
CVE-2026-123007 HTTP/2 enabled 1.9.5
CVE-2026-123633 HTTP/2 proxied to a backend, worker low on worker_connections 1.19.7
CVE-2026-121810 HTTP/3 (Xint’s path: requests forwarded to a backend) 1.25.0
CVE-2026-123634 Variable server name in proxy_pass, plus an SSI or mirror subrequest resolving it 0.6.18
CVE-2026-113425 Mail proxy (Xint’s path: proxy on and auth_http) 0.5.33

In Xint’s demonstrated chain, the kernel flaw is exploited after the attacker gains code execution as an nginx worker. It is a use-after-free in SCTP, present since Linux 4.15, with no CVE or kernel patch as of Xint’s disclosure. Whether it is reachable depends on the kernel, its modules and any container restrictions, and many distributions load the SCTP module the first time a program opens an SCTP socket.

How to check

These checks cover CVE-2026-123007. For the other four, compare your configuration with the table above. Run each command against the binary and configuration the service actually uses: containers, appliances and custom builds may have their own.

  1. Check the version with nginx -v. Versions 1.9.5–1.30.6 and 1.31.0–1.31.8 are vulnerable, but distributions often backport fixes without changing this version, so compare the full package version with your distribution’s advisory.

  2. Check whether the binary includes HTTP/2:

    Terminal window
    nginx -V 2>&1 | grep -q -- '--with-http_v2_module' && echo present || echo absent
  3. Check whether the configuration enables HTTP/2. The command joins each directive onto one line first, since a directive can span several lines. nginx -T reads the configuration on disk, so it doesn’t prove the running workers have loaded it:

    Terminal window
    sudo nginx -T 2>&1 | sed 's/#.*//' | tr '\n' ' ' | tr ';' '\n' | grep -E '(^|[[:space:]{])listen[[:space:]][^;]*[[:space:]]http2([[:space:]]|$)|(^|[[:space:]{])http2[[:space:]]+on[[:space:]]*$'
  4. From outside your network, check whether HTTP/2 is negotiated:

    Terminal window
    openssl s_client -connect HOST:443 -servername HOST -alpn h2 </dev/null 2>&1 | grep -E 'ALPN protocol:|No ALPN negotiated'

    ALPN protocol: h2 confirms HTTP/2 at the endpoint you reached. If a CDN or proxy sits in front, test the nginx server directly too. No output or a failed handshake is inconclusive. This check also doesn’t cover HTTP/2 over cleartext.

What to do

The demonstrated chain has two stages. Patch nginx to block initial access, and mitigate exposure to the kernel flaw:

HTTP/2 trafficCVE-2026-123007Invalid windowaccountingHeap read and writenginx workerCode executionSCTP kernel flawIf reachableHost rootShown by Xintfrom a containerUpdate nginxBlock SCTP loading HTTP/2 trafficCVE-2026-123007Invalid windowaccountingHeap read and writenginx workerCode executionSCTP kernel flawIf reachableHost rootShown by Xintfrom a containerUpdate nginxBlock SCTP loading

Update nginx

  • Update to nginx 1.31.9 (mainline) or 1.30.7 (stable), or a distribution package that lists these CVEs as fixed. For F5 products, use the fixed versions below.
  • Restart nginx or do a live binary upgrade. A configuration reload does not replace the running binary.

If you can’t update yet

These are Xint’s mitigations. They block the known attack paths but don’t fix the bugs.

  • For CVE-2026-123007 and CVE-2026-123633, disable HTTP/2 on affected ports:

    • On 1.25.1 and later, set http2 off; and remove any http2 parameter from listen directives.
    • On older versions, remove http2 from listen.
    • Check every server block that shares the same address and port.
    • Then run nginx -t, reload, repeat the ALPN check above and confirm the site still loads over HTTPS.
    • Services that need HTTP/2, such as gRPC, will break.
  • For CVE-2026-121810, remove the listen directives that contain quic, set http3 off; and replace any header advertising HTTP/3 with Alt-Svc: clear (add_header Alt-Svc 'clear' always;). Then check that nginx no longer listens on UDP on each port your QUIC listeners used, for example with sudo ss -lunp 'sport = :443'. If the output still shows nginx, a QUIC listener is active.

  • For CVE-2026-123634, point proxy_pass at a fixed upstream group instead of a variable. Setting mirror_request_body on; stopped Xint’s exploit, but doesn’t fix the bug.

  • For CVE-2026-113425, keep untrusted clients away from the mail proxy by binding it to loopback or restricting it with a firewall.

  • A reload only applies a change to new connections. If workers still show worker process is shutting down, restart nginx.

Mitigate the kernel flaw

On hosts that don’t use SCTP, stop the module loading until a kernel fix ships: add install sctp /bin/false to a .conf file in /etc/modprobe.d/. This stops modprobe from loading the module. It doesn’t unload a module that is already loaded, and doesn’t disable SCTP built into the kernel.

Fixed versions

These are from F5’s five advisories, linked under References. NGINX Plus fixes vary slightly by CVE, and 37.3.0.1 and 37.0.8.1 cover all five. BIG-IP, BIG-IQ and F5OS are not affected.

Product Fixed in Not fixed
nginx Open Source 1.31.9, 1.30.7
NGINX Plus 37.3.0.1, 37.0.8.1 R34–R36
F5 NGINX Ingress Controller 5.8.0, 2026-lts-r11 4.x, 3.x
NGINX Gateway Fabric 2.9.0 1.x
NGINX Instance Manager 2.25.0
F5 WAF for NGINX 5.16.2, 5.14.4
F5 DoS for NGINX 4.13.0
NGINX App Protect WAF, App Protect DoS No fix listed

We checked the Linux distributions’ trackers for CVE-2026-123007 on 20 November 2026 at 14:00 UTC:

These statuses change quickly. Check each tracker directly before acting.

What to monitor

  • Look for commands started by the nginx worker, the strongest sign of a successful attack. Xint gives an auditd rule for execve() by the worker’s user; other processes run as that user too, so check each event’s parent process.
  • Weaker signs, each with normal causes, are long-lived connections where inbound bytes keep climbing while nginx sends little back, many short TLS connections from one IP and worker crashes (signal 11 in error.log). Investigate when several appear together.
  • Access logs don’t record the HTTP/2 frames this attack uses, and patching doesn’t tell you whether a system was compromised before the update.

Timeline

  1. Xint reports the vulnerabilities to F5 through HackerOne

  2. Xint validates the nginx team's patches

  3. nginx releases 1.31.9 and 1.30.7; F5, Xint and Rapid7 publish, with Rapid7's proof of concept

watchTowr reported no exploitation in the wild in its FAQ, last updated 18 November. As of 20 November, none of the CVEs is in CISA’s Known Exploited Vulnerabilities catalog.

Rapid7’s public proof of concept gets code execution on a fresh nginx 1.31.8 container by sending about 128 GB of HTTP/2 data, which takes 2 minutes on a 10 Gbit/s link. Rapid7 expects that approach to fail below about 300 Mbit/s, since nginx closes connections after an hour, and against a busy server or through a proxy. Those are limits of its exploit, not of the bug. Xint has withheld its own exploits.

Technical summary

CVE-2026-123007 is an integer underflow (CWE-191) in HTTP/2 flow control. When streams with queued data close, nginx refunds their reserved send-window credit without rechecking the limit, so an attacker who has already raised the window can push it past its maximum. A later bounds check then underflows, letting the window grow to almost any 64-bit value, which nginx turns into a huge length for a memory copy. The result is a heap read and write that can leak addresses and overwrite a function pointer. F5 says code execution needs ASLR disabled or bypassed.

The other four are use-after-free bugs, in HTTP/2 and HTTP/3 connection handling under connection pressure, DNS resolution during subrequests and the mail proxy’s authentication.

In the kernel flaw, an SCTP association can be moved to another socket while a send is waiting, then freed, which Xint used to leak kernel addresses and call a kernel function of its choice.

References

F5 credits Xint for all five nginx vulnerabilities. It also credits Rapid7’s Stephen Fewer, Wiz Research and Ikotas Labs for CVE-2026-123007, and Metnir, Wiz Research and Palo Alto Networks Unit 42 for CVE-2026-123633. Xint’s researchers @imssm99, @cdor1, @tjbecker and @yves found the kernel flaw.

[↓] [↑] [enter] to visit
Menu
[M]
Next in menu
[J]
Previous in menu
[K]
Find
[F]
Ask
[A]
Sign in
[S]
Copy page
[C]
Listen
[L]
Justification
[R]
Language
[G]
Dark mode
[D]
High contrast
[H]
Shortcuts
[I]
Close
[Esc]