Skip to content
phprceCVEpatchcritical

PHP patch now: CVE-2026-109618 and CVE-2026-109619 enable unauthenticated RCE

3 min read
Share

On October 21, 2026, the PHP security team released emergency patches for two critical use-after-free vulnerabilities in the PHP core language runtime: CVE-2026-109618 and CVE-2026-109619, collectively named PHP2Shell. Both carry a CVSS v4.0 score of 9.2. Chained together, they allow an unauthenticated attacker to achieve remote code execution on any PHP-powered web server, with no authentication and no user interaction required. Zscaler ThreatLabz observed 1,156 exploitation attempts from 156 unique attacker IPs targeting 70 organizations within the first 48 hours of disclosure.

What the two CVEs do, and why they chain

CVE-2026-109618 is an out-of-memory corruption flaw. PHP uses longjmp() to abort a request when it hits its configured memory limit. If a web request triggers an OOM condition while internal POST data structures are only partially initialized, longjmp() bypasses normal control flow and leaves memory in an inconsistent state. PHP's cleanup code then misinterprets the invalid data as valid, following an attacker-controlled code pointer. CVE-2026-109619 is a use-after-free flaw. When PHP encounters a fatal error and calls zend_bailout() via longjmp(), certain global state pointers survive beyond the request's memory lifetime. A subsequent request handled by the same PHP worker process can reference those stale pointers before re-initialization, allowing the attacker to control what PHP reads and executes.

The two vulnerabilities chain in a two-stage exploit. Stage one sends a crafted multipart/form-data POST request containing a PHPSESSID field, a PHP_SESSION_UPLOAD_PROGRESS field, and an oversized body or malicious filename to trigger the OOM or fatal condition. Stage two sends an immediately following request sized and aligned to reclaim the freed memory, achieving code execution through the stale global pointers. The chain requires no authentication and no prior session state.

Affected versions and patch targets

  • PHP 8.5.0 through 8.5.11: patch to 8.5.12.
  • PHP 8.4.0 through 8.4.26: patch to 8.4.27.
  • PHP 8.3.0 through 8.3.35: patch to 8.3.36.
  • PHP 8.2.0 through 8.2.34: patch to 8.2.35.
  • PHP 8.1, 8.0, 7.x, and 5.4 and later (all end-of-life): no official patch. Upgrade to a supported branch.

Patch now, disable if you cannot patch

Organizations should treat this as an emergency patching event. PHP powers WordPress, Drupal, Joomla, Magento, and many hosting control panels including cPanel and Plesk. Any PHP-powered application exposed to the internet is a candidate for automated exploitation. Linux package maintainers received patches in advance and may already have updated packages in their repositories. Check your distribution's release notes for the specific package version that includes the fix. If immediate patching is not possible, disable the service entirely for internet-facing PHP instances until the upgrade can be completed. Setting session.upload_progress.enabled = Off and disabling multipart uploads at the network edge reduces the exploitable attack surface but is not a complete mitigation.

Inventory every PHP deployment in your environment, including standalone servers, bundled applications, and vendor appliances. Organizations still running PHP 8.1 or earlier have no patch path and must migrate to a supported branch. The window between disclosure and active exploitation for this class of vulnerability has narrowed to under 48 hours.

Related articles