On 19 August 2026 a researcher pointed a set of AI tools at the PHP core and they found the first bug. By 20 August the same work had a working remote code execution against Drupal, on 21 August against WordPress, and on 24 August it went to the PHP team. PHP acknowledged it on 21 September. The fix and the disclosure landed on 21 October, about two months after the first find. Wiz published the timeline, and the line I keep coming back to is theirs: a single researcher completed in a week what would previously have taken a world-class team months.
This is part one of three posts about PHP security in autumn 2026. This one covers PHP core only. Part two is Drupal, part three is how Symfony, Laravel and Drupal are responding. I run two Drupal sites on PHP, so I read these advisories as someone who has to act on them.
What the two bugs actually are
PHP2Shell is two CVEs, CVE-2026-109618 and CVE-2026-109619, both disclosed and fixed on 21 October. php.net rates them CVSS v4.0 9.2 and describes them as allowing unauthenticated remote code execution.
The first is memory handling. When PHP runs out of memory in the middle of a request, its cleanup path can treat partly initialized request data as if it were valid. The name in the advisory is "RCE via OOM corruption".
The second is state that outlives its request. Data owned by one request survives after its memory is freed, and the next request on the same worker picks it up. "RCE via stale global state".
Neither needs a bug in your application. That is the uncomfortable part. Wiz writes that even a simple Hello World application can be vulnerable, and they demonstrated the attack against WordPress, Drupal and Joomla running their latest container images. php2shell.com is explicit that exploitation does not require one of those applications.
Who was exposed
Short answer: almost everyone serving PHP over HTTP. Every PHP version released in the last decade is affected by at least one of the bugs behind these two CVEs, going back to 5.4, per Wiz. php.net lists PHP-FPM, Apache with mod_php, php-cgi, FrankenPHP and LiteSpeed. They call the risk highest for mod_php, because they have a demonstrated exploit where an unauthenticated request triggers the attack before any application code runs.
Fixed versions are 8.2.35, 8.3.36, 8.4.27 and 8.5.12. PHP 8.1 and older got nothing, because those branches no longer receive updates.
One number to handle with care: PHP's share of websites is often quoted at around 70%. That is market share, not a count of vulnerable servers, and neither php.net nor the Wiz post cites a source for it. Use it as context, not as your risk number. My guess is that the share is lower today: new projects lean towards Python and TypeScript, partly because that is where language models are most fluent. But there is a lot of legacy PHP out there, and somebody has to keep it patched.
If you cannot upgrade today
php.net lists workarounds and is clear that none of them is complete. The two main ones: Set memory_limit to -1 where the application cannot override it, for example through php_admin_value. Set session.upload_progress.enabled to 0. Then restart every worker.
The first one is a bridge with a cost: an unlimited memory_limit is also no ceiling for a runaway script, so watch the host while you run that way. And do not sit on the settings. php.net says it plainly: "There are no complete mitigations, updating is the only safe choice."
I don't think you can be ready for a bug like this in advance. Nobody had PHP2Shell on their roadmap. What you can have is a system that lets you change what runs in production quickly, because these disclosures will keep coming. For Boardinn, the white-label SaaS I build, part of that system is a daily job that runs composer audit against the locked production packages and, when an advisory shows up, opens a pull request with the bumps. Merging and the release stay manual. On the hosts, Ubuntu's unattended-upgrades installs security packages every night. When I checked both servers on 27 November, they had installed that morning's batch without errors, and both also said "reboot required". One of them had been up for 15 weeks. Automatic reboots are off on purpose, because a production box should not reboot itself, but that makes the reboot a human job, and nobody had been doing it. I rebooted both the same day. For the signal itself, I watch php.net and cybersecurity forums, and every server now sends me a Telegram alert when it needs a reboot, so the next "reboot required" doesn't wait 15 weeks for me to notice it.
The catch is that composer audit knows nothing about the PHP binary itself. A PHP release reaches the server through the container image or the OS packages, and that path needs its own owner. On my two sites PHP-FPM runs in Docker from the floating php:8.3-fpm tag, so the host's automatic updates never touch PHP at all. PHP moves only when an image is rebuilt with a fresh base pull, which in my setup happens on every release. When I checked on 27 November, the latest builds of both sites had resolved to the same base digest as 8.3.37-fpm on Docker Hub, and replacing the containers restarted the workers. The weak spot is the opposite case: a quiet week with no release means PHP stays on whatever the last build pulled. A scheduled rebuild would close that gap, and I don't have one yet.
The 19 November release
The second wave arrived on 19 November: 8.2.36, 8.3.37, 8.4.28, 8.5.13, plus 8.6.0 as the new stable branch. php.net's notice the day before said the issues rated critical require either non-default configuration or uncommon setups, which is reassuring until you count how many production boxes have one non-default setting nobody documented.
The critical list on GitHub includes request smuggling in PHP-FPM through an unread request body, several use-after-free bugs (magic-method backtraces, last_fatal_error_backtrace, the timezone cache, an interrupted session shutdown), and partially overwritten session files leading to RCE. Lower down are a PHP-FPM epoll bug that gives local privilege escalation, an XSS in the FPM status page, a PHAR signature downgrade, and CVE-2026-115560, the session serializer issue from 23 October.
That last one needs a specific setup: an application that switches session.serialize_handler to php at runtime with ini_set() before session_start(), with upload progress still enabled. Not common, but not impossible in older code.
If you are on the 19 November builds, you also have the PHP2Shell fix. If you are on the 21 October builds, you have the PHP2Shell fix but not this batch.
EOL PHP is now a business decision
The part managers need to hear is not the CVE list. It is the support table.
- PHP 8.1 and older: end of life, no PHP2Shell fix, no 19 November fix. A known unauthenticated RCE with no vendor patch.
- PHP 8.2: security fixes only, end of life on 31 December 2026.
- PHP 8.3: security fixes until 31 December 2027.
- PHP 8.4: active until 31 December 2026, security until 31 December 2028.
- PHP 8.5: active until 31 December 2027.
- PHP 8.6: released 19 November 2026.
The choice is no longer patch or wait. For 8.1 and older it is upgrade or carry an unpatched RCE, and for 8.2 it is upgrade this quarter or join that group. An upgrade is a project with a budget, a test plan and a date. A CVE is a Tuesday.
What to tell management, in one pass: we run PHP version X on these hosts, this is where the support window ends, this is the cost of moving to a supported branch, and this is the deadline we commit to. If nobody can answer the first part, that is the finding.
A short checklist
- Inventory PHP versions and SAPIs on each host. php.net rates mod_php as the highest risk for PHP2Shell, and most of the 19 November criticals sit in PHP-FPM and sessions.
- Move to 8.2.36, 8.3.37, 8.4.28 or 8.5.13, then restart the workers. A patched binary with old workers still running is not patched.
- If you must wait, apply memory_limit=-1 through php_admin_value and session.upload_progress.enabled=0, restart, and put a date on the upgrade.
- Test the behaviour change. The fix adds a hard memory limit that terminates the process, and when it fires, shutdown handlers don't run, so code that logs or cleans up in a shutdown handler will notice.
- Put 8.2 on the calendar. 31 December 2026 ends security support, and the next PHP2Shell will not wait for your sprint.
Next
Part two is Drupal, including how I patched two Drupal sites through it. A core installer bug that allows a site takeover was exploited in the wild the day after its advisory, and Drupal shipped 106 advisories in October alone. Part three compares how Symfony, Laravel and Drupal are absorbing this volume of reports, because finding is now cheap and the patching is not.
One question for you: which PHP branch are your production servers on right now, and does the person who signs the infrastructure budget know its end of life date?
Top comments (0)