PHP fixes seven critical flaws that can let attackers run code on web servers
PHP released versions 8.5.13, 8.4.28, 8.3.37 and 8.2.36 on November 19. The 8.5 release alone fixes 17 vulnerabilities, seven of which are rated critical with a CVSS 4.0 score of 9.2. The worst can let an attacker run code on a web server without logging in. In its notice a day earlier, the PHP security team said the critical issues require non-default configuration or uncommon setups, and urged users to upgrade promptly. The releases come four weeks after the emergency PHP2Shell patches, which SecurityWeek reports attackers had already exploited widely.
A forged request inside PHP-FPM
The flaw with the clearest path to an attack is CVE-2026-129289 in PHP-FPM, the process manager that runs PHP behind nginx and Apache on most servers. If an application opens the request body through php://input but does not read it to the end, leftover bytes stay on the connection. When the web server keeps that connection open for the next request, PHP-FPM can take those bytes for a new request that the front end never sent. The attacker then controls its parameters, can point it at any existing PHP script and switch on settings that run the attacker's own code, the advisory says. Many frameworks open the input stream before routing, even when the endpoint does not use the body.
There is an important condition. The attack needs a front end that reuses backend connections, such as nginx with fastcgi_keep_conn on or Apache mod_proxy_fcgi with enablereuse=on. Standard nginx and Apache setups close the FastCGI connection after each request and are not affected by the demonstrated attack. The bug dates back to PHP 5.6.
Three session bugs, one of them in the default handler
CVE-2026-115560 is the session upload progress flaw that PHP disclosed on October 23, two days after the PHP2Shell patches, and had suggested working around by setting session.upload_progress.enabled=0. It only matters when data written with one session format is later read with another, for example when an application switches the serializer at runtime, or when two sites with different settings share session storage.
CVE-2026-126714 is wider: the default files session handler could leave a file with pieces of two different sessions if a write was interrupted. An attacker who can influence session contents may then get PHP to restore objects of their choosing, which turns into code execution if the application has a suitable gadget chain. A third bug, CVE-2026-129481, is an incomplete fix for one of the PHP2Shell (CVE-2026-109619) flaws and affects PHP 8.3 and later.
The remaining critical flaws
CVE-2026-129496 is a use-after-free in the timezone cache. It needs PHP to write a warning to an error log file during startup, for example because of an invalid date.timezone value, after which a crafted request can corrupt memory and possibly run code as the PHP worker. Two more critical bugs, CVE-2026-129474 and CVE-2026-129182, affect only PHP 8.5. The first one needs fatal_error_backtraces=1 and zend.exception_ignore_args=0, while the recommended production configuration sets it to 1, according to the PHP changelog and the linked advisories. The advisories say nothing about attacks on the new flaws.
A day earlier NGINX fixed an HTTP/2 flaw that lets attackers take over servers. In October PHP had to rebuild its Windows packages because of a bug in the Brotli decoder.
What administrators should do
- Update: install 8.5.13, 8.4.28, 8.3.37 or 8.2.36, or your distribution's patched package once it is out, and restart PHP-FPM.
- Check connection reuse: if nginx has
fastcgi_keep_conn onor Apache usesenablereuse=onfor PHP-FPM, turn it off until the update is installed. - Keep the October workaround:
session.upload_progress.enabled=0can stay in place until the new version is running. - Look at the logs: warnings written to the PHP error log at startup, such as a wrong
date.timezone, are worth fixing in any case.
• News Archive - 2026 - PHP
• PHP 8 ChangeLog - PHP
• PHP-FPM request smuggling through an unread HTTP request body - php-src security advisory
• Partially overwritten session files can lead to remote code execution - php-src security advisory
• PHP Readies Critical Security Updates to Patch Another RCE Flaw - SecurityWeek