CVE explainer

CVE-2026-129291: the PHP-FPM setting the Docker images turn on

Short answer

CVE-2026-129291 is a high-severity (8.8) PHP-FPM bug fixed on 19 November 2026 in 8.5.13, 8.4.28, 8.3.37 and 8.2.36. Someone who can already run PHP code in a worker can gain the FPM master’s privileges, usually root, if the pool has catch_workers_output on. The official php:*-fpm Docker images turn it on.

On this page

What is CVE-2026-129291?

It’s a use-after-free in PHP-FPM’s master process, fixed in PHP’s 19 November 2026 security release. PHP’s advisory title: “PHP-FPM epoll use-after-free can lead to local privilege escalation”. It’s rated High, CVSS 4.0 score 8.8, so it sits just below the seven critical issues in the same release.

When a pool captures worker output, the FPM master can act on an event that points at a worker record it has already freed. Someone who can already run code inside an unprivileged FPM worker can use that to run commands with the master’s privileges. On most servers the master runs as root, because it has to start pools under different users.

This is a local bug. Nobody can use it from the internet on its own. It matters because it turns “an attacker has a web shell running as www-data” into “an attacker has root”, and because of one default you probably didn’t choose.

The Docker images turn the setting on

PHP-FPM’s own default is catch_workers_output = no. The official PHP-FPM Docker images set it to yes, so that anything workers print ends up in the container log. PHP’s advisory calls the Docker images a common affected configuration, and says root command execution was reproduced from a www-data worker against unmodified PHP 8.5.12 Docker images on both x86-64 and arm64.

If you build on php:8.x-fpm, php:8.x-fpm-alpine or anything derived from them, assume the setting is on until you’ve checked.

Who should care most?

  • Shared hosting. Several customers’ pools run under one FPM master, and any customer can run PHP. A malicious or compromised account is exactly the “local code execution in a worker” the bug needs.
  • Containers built on the official FPM images. The master runs as root inside the container and the setting is on. The advisory notes this doesn’t by itself give a container escape, but root inside the container can read every secret mounted into it.
  • Anyone already worried about a web shell. If PHP2Shell or one of November’s bugs got someone code execution as the web user, this is the next step up. Patching it shrinks what a foothold is worth. See the compromise checklist if that’s a live question for you.

A single-site server where the master doesn’t run as root is the least affected case: the advisory says escalation is then limited to the master’s own user.

Am I affected?

Three conditions, all from PHP’s advisory:

  1. A PHP version in the affected range (below).
  2. A pool with catch_workers_output enabled.
  3. The epoll event backend, which is what PHP-FPM picks on Linux.

Plus an attacker who can already run code in a worker. Check the setting across every pool:

sudo grep -rn 'catch_workers_output' /etc/php/*/fpm/ /etc/php-fpm.d/ /etc/php-fpm.conf /opt/cpanel/ea-php*/root/etc/php-fpm.d/ 2>/dev/null

Adjust the paths to your layout. A line reading catch_workers_output = yes (not commented out with ;) means that pool is affected until PHP is updated. You can also dump FPM’s effective configuration, which includes defaults:

sudo php-fpm8.3 -tt 2>&1 | grep -i catch_workers_output

For containers, look at the pool config inside the image you deploy:

docker run --rm php:8.4-fpm grep -rn catch_workers_output /usr/local/etc/php-fpm.d/

Swap in your own image name to check what you actually ship.

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.7 to 8.2.35 8.2.36

The 8.2 range starts at 8.2.7, not 8.2.0, according to the advisory. That’s no reason to stay on an early 8.2: those releases miss years of other fixes, including PHP2Shell. PHP 8.6.0 includes the fix. The advisory doesn’t list 8.1 or older, and those branches get no releases from the PHP project anyway.

For containers, rebuild on a patched base image and redeploy every service; a running container keeps the PHP it was built with. Our Docker guide has the steps. For servers, the patch guides cover each distribution and panel.

The stopgap: switch catch_workers_output off

PHP’s temporary workaround is to disable worker output capture in the affected pools:

; in each pool file, e.g. /etc/php/8.3/fpm/pool.d/www.conf
; or a later-loaded file in /usr/local/etc/php-fpm.d/ in Docker
catch_workers_output = no

Restart PHP-FPM afterwards. In a Docker image, put the override in a file that loads after the image’s own pool config, or sed the existing line during the build.

What you lose: anything workers write to stdout or stderr no longer reaches the FPM log. In Docker, that output disappears from docker logs. Before you switch it off, make sure PHP’s error_log points somewhere you actually read, or you’ll lose PHP errors along with it. Turn it back on after upgrading if you rely on it.

Run the master without root where you can

The advisory adds one more defence: if the FPM master doesn’t run as root, a successful attack only gets the master’s user. That doesn’t fix the bug, but it caps the damage from this one and from whatever comes next.

The master needs root to run pools as different users. If a server or container runs a single pool as a single user, it doesn’t. In a container, that can mean starting PHP-FPM as www-data; the pool’s user and group lines are then ignored, because only a root master can switch users. The default listen port 9000 doesn’t need root to bind. Test this in staging first: file permissions on logs, sockets and the application tree all need to suit the unprivileged user.

On shared hosting you can’t change any of this. Ask your host whether they’ve updated PHP and whether catch_workers_output is enabled on their pools; did my host patch? has a list of questions that work.

What doesn’t help

The advisory says disabling the curl or OPcache extensions is not a complete mitigation. Running the master as non-root limits the impact but doesn’t remove the use-after-free. Upgrading does.

The rest of the FPM settings this year’s bugs touched (socket permissions, connection reuse, the status page) are in our PHP-FPM hardening checklist. The internet-facing FPM bug from the same release is CVE-2026-129289.

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-jm4m-qfqx-967m (CVE-2026-129291)
  2. php.net: PHP 8.5.13 released (19 Nov 2026)
  3. php.net: ChangeLog for PHP 8
  4. PHP Architect: PHP's November security release, seven critical fixes explained
  5. Semgrep: 18 vulnerabilities hit the PHP runtime

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.