Two critical vulnerabilities in PHP have triggered urgent security updates around the world. Tracked as CVE-2026-109618 and CVE-2026-109619, the flaws could let an unauthenticated attacker run malicious code on a vulnerable web server. PHP released fixes on October 21, 2026, and strongly urges users to update immediately. Read PHP’s official security advisory.
The vulnerabilities have been called PHP2Shell. The weakness is in PHP itself—the engine that runs many websites—so updating WordPress or another website platform alone may not fix it. The PHP version serving the site must also be patched.
What can an attacker do?
“Remote code execution” means an attacker may be able to make a server run commands they choose by sending requests over the internet. Researchers demonstrated attack paths that did not require a valid account or password. If successful, this kind of access could expose data stored on a server, disrupt a website, or give an attacker a path to alter site files.
These vulnerabilities are in PHP’s engine, below the website application layer. Researchers demonstrated attack paths involving WordPress, Drupal, and Joomla, but the problem is not limited to a flaw in any one of those platforms. A site can use one of these systems—or custom PHP code—and still depend on the affected PHP runtime. Wiz Research’s technical analysis explains the demonstrated attack chains.
How did it happen? A simple explanation
PHP handles each web request using internal memory. Think of that memory as a workbench: PHP places temporary notes and tools on it while handling a request, then clears them when the request is done.
The vulnerabilities involve cases where that setup or cleanup can go wrong:
- CVE-2026-109618 involves memory exhaustion. If PHP runs out of memory at a particular point while handling a request, it can be interrupted before its internal data is fully set up or cleaned up. Later cleanup may then treat incomplete or invalid data as usable.
- CVE-2026-109619 involves stale internal state. Some request data can outlive the memory it was stored in. If a later request handled by the same PHP worker uses that leftover reference before PHP resets it, the worker may act on memory that no longer belongs to that request.
In computer security, using a reference to memory after that memory has been released is called a use-after-free. It is like keeping an old address label after a parcel has moved: the label still points somewhere, but it no longer describes what is there. Researchers combined these memory mistakes with additional techniques to demonstrate ways of reading process memory or achieving code execution.
How were the PHP2Shell issues discovered?
The story began before the public emergency. The PHP Foundation says a 2024 external security audit uncovered early signs of the memory-exhaustion problem, although researchers did not yet have a concrete way to exploit it. In August 2026, researchers from Calif, OpenAI, and Wiz reported findings that helped show how the underlying issue could become a serious attack. The PHP security team and industry partners coordinated on fixes before public disclosure. The PHP Foundation describes the discovery and response.
AI tools helped researchers inspect and test complex PHP code, but people still validated the findings, coordinated the disclosure, and developed the fixes. The case shows how these tools can help uncover bugs that are difficult to spot by manual review alone—and why maintainers need time and resources to fix them safely.
Which PHP versions include the patch?
PHP’s security release lists these fixed versions:
- PHP 8.5.12
- PHP 8.4.27
- PHP 8.3.36
- PHP 8.2.35
If your hosting company or Linux distribution provides PHP, check for its patched package. Some vendors apply the fix to their own builds, so the version label may differ from the upstream release number. PHP 8.1 and older no longer receive updates from the PHP project; ask your vendor whether it has supplied a backport or plan an upgrade to a supported branch. PHP 8.2 is scheduled to reach end of life on December 31, 2026. Check the official PHP release guidance.
How to protect your website
- Find every PHP installation. Check your hosting control panel, containers, servers, staging sites, and separate PHP-FPM or application workers. A site may use a different PHP version from the one shown by a command-line check.
- Install the patched version through your host or package vendor. For managed WordPress hosting, ask the provider to confirm that the PHP runtime for your domain is patched.
- Restart or reload PHP workers if your setup requires it. An updated package does not help a worker that is still running the old process.
- Verify the version serving web traffic. Check the runtime used by the actual website, then confirm the site and its important features still work.
- Review logs and investigate suspicious activity. Look for unusual multipart upload requests, memory-limit errors, repeated server errors, unexpected PHP worker restarts, or malformed session cookies. These can be clues, not proof of an attack. If you find signs of compromise, involve your hosting provider or security team and rotate affected credentials.
- Keep the rest of your stack updated. Update your CMS, themes, plugins, and server software too. The PHP issue is separate from application vulnerabilities, but outdated components can create additional ways into a site.
Are temporary protections enough?
No temporary setting is a complete fix. PHP’s security team says updating is the only safe choice. If an update is delayed, PHP lists measures that can reduce exposure to specific attack paths—for example, disabling session.upload_progress in server-level configuration and limiting oversized request bodies. These controls need to be configured carefully, may affect uploads, and do not cover every variant. A web application firewall can add another layer, but it cannot replace the PHP security update.
These are server-administration changes. On managed or shared hosting, ask your provider to apply the appropriate settings rather than changing PHP configuration blindly. PHP’s advisory explains the temporary mitigations and their limits.
The takeaway
PHP2Shell is serious because it affects the language runtime beneath many websites, and demonstrated attack paths need no login. The response is practical: identify the PHP version your site actually runs, apply the patched release from your host or vendor, restart workers where needed, and verify the result. If you cannot patch immediately, use PHP’s temporary mitigations to reduce risk while you arrange the update—but treat them only as a short-term bridge.

