CVE explainer

CVE-2026-129289: is your nginx or Apache config exposing PHP-FPM?

Short answer

CVE-2026-129289 is a critical PHP-FPM request smuggling flaw, fixed on 19 November 2026 in 8.5.13, 8.4.28, 8.3.37 and 8.2.36. It needs a web server that reuses FastCGI connections (nginx fastcgi_keep_conn on, Apache enablereuse=on). Stock nginx and Apache setups close the connection after each request and aren’t exposed to the demonstrated attack.

On this page

What is CVE-2026-129289?

It’s a request smuggling bug in PHP-FPM, one of the seven critical issues fixed in PHP’s 19 November 2026 security release. PHP’s advisory title says it plainly: “PHP-FPM request smuggling through an unread HTTP request body”.

The mechanism, minus the attack details: when a PHP script opens php://input but doesn’t read the request body to the end, PHP-FPM leaves the unread bytes on the connection. If the web server then sends the next request down that same connection, FPM can read those leftover bytes as a second FastCGI request. The web server never sent that request, never logged it and never applied its rules to it. According to the advisory, an unauthenticated attacker can use this to run PHP of their choosing as the FPM worker.

The behaviour goes back to lazy php://input handling, added in PHP 5.6.0.

Am I exposed?

Two things have to be true at the same time:

  1. Your web server reuses backend connections to PHP-FPM. PHP names nginx with fastcgi_keep_conn, Apache mod_proxy_fcgi with enablereuse=on, HAProxy and LSAPI.
  2. Some code path opens php://input without reading all of it. You can’t easily audit this one. ComputingForGeeks and others point out that frameworks often create the input stream before routing or authentication, so an endpoint that never uses the body can still leave bytes behind.

Condition 1 is the one you can check in a minute, and it’s the one you control. PHP’s advisory says standard nginx and Apache configurations that close the connection after each request are not affected by the demonstrated attack. That matches PHP’s pre-announcement on 18 November: the critical issues “require either non-default configuration or uncommon setups”.

So the question is whether someone (you, a control panel, a server template, a tuning guide) switched connection reuse on.

Check nginx

nginx closes the FastCGI connection after each response unless fastcgi_keep_conn on is set. Keeping connections between requests also needs a keepalive directive in an upstream block. Dump the full running config, includes and all, and search it:

sudo nginx -T 2>/dev/null | grep -nE 'fastcgi_keep_conn|(^|[[:space:]])keepalive[[:space:]]+[0-9]'

Read the result like this:

  • No output: nginx isn’t reusing FastCGI connections. You’re not exposed to the demonstrated attack. Patch PHP anyway.
  • fastcgi_keep_conn on; anywhere that serves PHP: treat the site as exposed until PHP is updated.
  • Only keepalive 32; (or similar) inside an upstream: check whether that upstream is a PHP-FPM pool or an HTTP backend. Keepalive to an HTTP app server has nothing to do with this CVE.

PHP’s advisory names fastcgi_keep_conn as the trigger, so that directive is the one to find. Don’t stop at /etc/nginx/sites-enabled: panels and templates often keep snippets in conf.d, snippets or a vendor directory, which is why nginx -T is better than grepping one folder.

Check Apache

With Apache and PHP-FPM, connection reuse is a worker parameter on the fcgi:// backend. For FastCGI it’s off unless someone turned it on. Search every Apache config directory:

sudo grep -rniE 'enablereuse|disablereuse' /etc/apache2 /etc/httpd 2>/dev/null

Look for enablereuse=on on a ProxyPass, ProxyPassMatch or <Proxy "fcgi://..."> line, or on the proxy that a SetHandler "proxy:fcgi://..." or "proxy:unix:/run/php/...sock|fcgi://localhost" handler points to. If you find it, that vhost is exposed until PHP is patched. disablereuse=on is the safe direction.

HAProxy, LiteSpeed, Caddy and mod_php

HAProxy. PHP lists HAProxy among the front ends that can reuse connections. If HAProxy talks FastCGI to PHP-FPM through an fcgi-app section, look at option keep-conn. ComputingForGeeks reported that HAProxy’s manual has this option enabled by default, so an fcgi-app section without no option keep-conn may be reusing connections. Their suggested stopgap is to add no option keep-conn to each fcgi-app section.

LiteSpeed (LSAPI). PHP’s advisory says LSAPI has a related cleanup error, but no code execution path was shown. Update PHP; there’s no FPM setting to change.

Caddy. None of the advisories or analyses we read mention Caddy. Caddy’s php_fastcgi is built on reverse_proxy with a FastCGI transport, so check your Caddy version’s documentation for whether that transport keeps backend connections open, and patch PHP either way.

Apache with mod_php. mod_php runs PHP inside Apache and doesn’t speak FastCGI, so this particular bug doesn’t apply. Other bugs in the same release do affect mod_php, including CVE-2026-129496, so mod_php servers still need the update.

Fixed versions

Branch Affected Fixed in
8.5 8.5.0 to 8.5.12 8.5.13
8.4 8.4.0 to 8.4.27 8.4.28
8.3 8.3.0 to 8.3.36 8.3.37
8.2 8.2.0 to 8.2.35 8.2.36

PHP 8.6.0, released the same day, includes the fix. PHP 8.1 and older get no release from the PHP project, even though the code dates back to 5.6. If you’re on one of those, see patched builds for PHP 8.1 and older.

Distribution packages keep their own version numbers. Ubuntu, Debian and RHEL builds won’t say 8.3.37; check the package changelog for CVE-2026-129289 instead (how). Step-by-step upgrades are in the patch guides.

The stopgap: stop reusing backend connections

If you can’t upgrade PHP today, switch reuse off. Every source agrees on this one, from PHP’s advisory to Red Hat’s bulletin.

nginx: remove the directive or set it explicitly, then reload nginx.

location ~ \.php$ {
    # ...
    fastcgi_keep_conn off;   # or delete the "fastcgi_keep_conn on;" line
}

Apache: drop enablereuse=on from the backend definition (or set it to off), then do a graceful reload.

<Proxy "fcgi://localhost/" enablereuse=off>
</Proxy>

The cost is a fresh connection to PHP-FPM for every request. On a Unix socket on the same machine you’re unlikely to notice. Over TCP to FPM on another host, expect a little extra latency per request. That’s a fair trade for a few days, and you can switch reuse back on after patching if you measured a real benefit from it.

Why “read the whole body” isn’t a fix

It’s tempting to fix this in the application: make sure every endpoint drains php://input. Red Hat calls reading php://input to completion “unreliable as the sole mitigation”, and we agree. You’d need to know every code path in your framework, every plugin and every error path that exits early. The bug is in PHP-FPM, so the fix belongs there. Update PHP, and turn off reuse until you have.

WordPress: what Wordfence reported

Wordfence reported reproducing unauthenticated PHP code execution in an isolated lab using an ordinary request to a stock WordPress 7.1.5 REST endpoint. The target was PHP 8.2.35 behind NGINX with FPM connection reuse on. The same request didn’t run code on 8.2.36, or with reuse switched off. No plugin, theme or account was involved.

Wordfence also noted that WordOps ships fastcgi_keep_conn on in its templates, and PHP Architect reported that the wodby/nginx image hard-codes it. If your server was built from either, check it first. More for site owners in WordPress and the November 2026 PHP flaws.

Why one score says 9.2 and another 8.1

PHP rates CVE-2026-129289 at 9.2 using CVSS 4.0, which records the configuration requirement as a separate “attack requirements” factor. Red Hat’s CVE page scores it 8.1 using CVSS 3.1, which folds that requirement into “high attack complexity”. Red Hat’s bulletin still labels it Critical. Both agree on the substance: network-reachable, no login needed, full impact when the conditions are met.

Signs to look for in your logs

No exploitation in the wild had been reported as of 20 November. If you want to look anyway, the useful signal is a mismatch between what the web server sent and what PHP-FPM ran. ArmorCode reported researchers seeing PHP-FPM access-log entries with no matching front-end request, plus PHP warnings about garbled “File Upload Mime” headers.

PHP-FPM’s per-pool access log is off unless you set it. To make this comparison possible in future, add it to the pool:

; e.g. /etc/php/8.3/fpm/pool.d/www.conf
access.log = /var/log/php8.3-fpm.access.log

Then compare request counts and paths for the same time window against the nginx or Apache access log. A run of FPM entries for scripts nobody requested through the web server is worth a closer look. Our compromise checklist covers the general checks.

After patching

Restart PHP-FPM rather than reloading it, so no worker from the old binary keeps running, and rebuild containers so they pick up the new image. Then confirm the version from the web runtime, not just the command line: find the PHP that serves your site. While you’re in the pool config, our PHP-FPM hardening checklist covers the other settings this release touched.

Rather not do it yourself? We patch and verify one server, from €79.

Shayan Abbas writes these PHP security guides from the official advisories and vendor guidance listed below, and updates them when those change. About this site

Sources

  1. PHP security advisory GHSA-qc49-hpvq-g2w6 (CVE-2026-129289)
  2. php.net: Upcoming critical PHP security release (18 Nov 2026)
  3. Red Hat: RHSB-2026-020, multiple PHP vulnerabilities
  4. Red Hat: CVE-2026-129289
  5. nginx: ngx_http_fastcgi_module (fastcgi_keep_conn)
  6. Apache HTTP Server: mod_proxy_fcgi
  7. Wordfence: CVE-2026-129289 and other critical PHP vulnerabilities for WordPress
  8. PHP Architect: PHP's November security release, seven critical fixes explained
  9. ComputingForGeeks: PHP CVE-2026-115560 and CVE-2026-129289, am I affected?
  10. ArmorCode: Triaging CVE-2026-126714 and PHP's November 2026 critical RCEs

Know about the next critical PHP bug first

Short, plain-English alerts when a serious PHP vulnerability or fix lands — with what to patch and how. About two emails a month.