Skip to content
Introducing AI OS for Business & School — our most powerful products yet.Explore →
App Corp iconApp Corp
Security
PHP2Shell
PHP
WordPress

PHP2Shell Explained: CVE-2026-109618 & 109619 Guide

PHP2Shell Explained: What CVE-2026-109618 and CVE-2026-109619 Mean for Your Business Website

AE

App Corp Engineering

Editorial Team

October 21, 202612 mins read
12 mins readRead time
1,303Words
Oct 2026Published

This free scan includes a PHP2Shell runtime check

Fixed in 8.5.12, 8.4.27, 8.3.36, 8.2.35. Reviewed 27 October 2026.

What to do now
App Corp Engineering·Editorial Team
Last updated 2026-10-23

What is PHP2Shell Explained?

PHP2Shell is a pair of memory-safety vulnerabilities in the core PHP interpreter, tracked as CVE-2026-109618 and CVE-2026-109619, that let an unauthenticated attacker execute code or read sensitive memory on any web server running a vulnerable PHP build. PHP released emergency patches on 21 October 2026, and the name deliberately echoes Log4Shell.

PHP2Shell is the nickname for two critical flaws in the PHP engine, CVE-2026-109618 and CVE-2026-109619, each rated 9.2 on CVSS v4.0 and each able to give an unauthenticated attacker remote code execution on a web server, or to read memory that may hold passwords, tokens and API keys. The flaws sit in PHP itself, so WordPress, Drupal, Joomla, Laravel and custom PHP applications are all exposed when they run on a vulnerable PHP build. Fixed versions 8.5.12, 8.4.27, 8.3.36 and 8.2.35 were released on 21 October 2026, while PHP 7.4, 8.0 and 8.1 received source-only backports and 7.3 and older got no fix at all. Governments in France, Denmark, Finland and the Netherlands took websites offline while they patched. The bigger question for many businesses is whether to keep running a decade-old PHP stack or move to a modern TypeScript and Next.js architecture.

What is PHP2Shell?

PHP2Shell is a pair of memory-safety vulnerabilities in the core PHP interpreter that can give an attacker remote code execution with no login required. The name deliberately echoes Log4Shell, the 2021 Java logging flaw that sent security teams into weeks of emergency work, and the comparison is fair because PHP sits underneath a huge share of the web, often in places business owners never think about. According to W3Techs, PHP runs on about 70.8% of websites whose server-side language is known, and WordPress alone runs 59.2% of websites with a known CMS, which is why headlines described the issue as affecting 70% of the internet. One important nuance: that figure measures exposure, not confirmed compromises, and as of 23 October 2026 there is no reliable public count of breached websites. The other reason PHP2Shell matters is how it was found: Wiz Research discovered the bugs with Calif and OpenAI, and says frontier AI models helped both find them and chain them into working exploits. We cover what that means for legacy codebases in AI Found PHP2Shell, and It Will Find the Next One.

Timeline: from discovery to Black October

Axios called the week Black October, and the timeline ran fast. Wiz Research found the first PHP memory-safety bug on 19 August 2026 and confirmed unauthenticated remote code execution against Drupal on 20 August and WordPress on 21 August. The findings went privately to the PHP security team on 24 August, and PHP acknowledged the reports on 21 September. Details leaked on 20 October, watchTowr confirmed the flaws were real, and PHP announced an out-of-band release. An archive of leaked vulnerability information appeared on VirusTotal at 02:29 UTC on 21 October, Patchstack reported multiple active exploitation incidents from hosting partners at 07:34 UTC, and PHP released 8.5.12, 8.4.27, 8.3.36 and 8.2.35 at 13:52 UTC the same day. Government sites went offline on 21 and 22 October, and 22 October was the originally planned coordinated disclosure date. The leak pushed the timeline forward and the patch arrived only after exploitation reports had started, so defenders had no head start.

Warning

The patch landed hours after leaked details and reports of active exploitation. Assume your servers were reachable before 13:52 UTC on 21 October 2026.

How the vulnerabilities work

Both CVEs come from the same weak spot: what PHP does when a request crashes partway through, especially when it runs out of memory, and four underlying bugs feed into the two CVE identifiers. CVE-2026-109618 treats half-built data as real: when PHP hits a fatal out-of-memory error the request stops while some internal data is only partly set up, and cleanup code can then treat that data as valid. This class includes a use-after-free in the session upload-progress feature, which has existed since PHP 5.4.0 and is enabled by default, plus a related flaw that can leak PHP worker memory.

CVE-2026-109619 is state left behind after a crash: some request data lives in PHP's global state and can still point at memory that has already been freed, so a later request handled by the same worker process uses that stale state. This class includes a use-after-free in fatal-error backtraces and an OPcache type confusion. Neither bug needs a login, both run before any application code, and Wiz showed exploitation against stock WordPress, Drupal and Joomla container images. Memory disclosure alone can expose passwords, session tokens, API keys and certificates from other users' requests, and because exploitation happens below the application layer, plugin firewalls and application logs can miss it.

mermaid
flowchart LR
    A[Attacker<br/>no credentials] -->|crafted multipart request| B[Web server]
    B --> C{PHP SAPI<br/>mod_php / FPM / CGI}
    C -->|forced out-of-memory| D[Request aborted<br/>mid-initialisation]
    D --> E[Corrupted or stale<br/>engine state]
    E -->|next request on same worker| F[Use-after-free]
    F --> G[Remote code execution<br/>or memory disclosure]
    G --> H[(Database creds,<br/>API keys, sessions)]

Who is affected?

In short, any PHP installation that serves web requests and has not been updated to a fixed release. PHP says the risk is highest for Apache with mod_php, where a demonstrated exploit runs before any application code, while PHP-FPM, php-cgi, FrankenPHP and LiteSpeed are also at risk. Wiz says every PHP release from the past decade, back to 5.4, is affected by at least one of the bugs. Fixed releases are 8.5.12, 8.4.27, 8.3.36 and 8.2.35, PHP 8.1, 8.0 and 7.4 received source-only backports, and PHP 7.3 and older received no fix at all. Internet scans show the scale of the problem: Modat found 4,384,302 PHP services on 1,886,612 hosts that report a readable version, about 79% of which run unsupported branches, with PHP 7.4 alone accounting for 878,761 services. VirusTotal found about 5.1 million IP addresses running PHP, and roughly 758,000 of the 1.1 million that disclose a version run end-of-life branches. A large part of the web is therefore running PHP versions that will never get an official patch, and that fact drives the rest of this series.

Why governments took websites offline

CNBC and RTE reported that government websites in France, Denmark, Finland and the Netherlands, including the Dutch cybersecurity agency's own site, were temporarily taken offline while fixes were applied. The National reported similar precautionary shutdowns elsewhere, including Australia, and dozens of sites in the US and UK. Coverage said the NSA urged organizations to patch immediately or take servers offline, and Cloudflare reported seeing early attacks and deployed WAF rules against known exploit paths. Wordfence warned that automatic WordPress updates will not apply the fix, because the fix is in PHP, not WordPress. Even criminal forums such as BreachForums and Dread went offline as a precaution. When well-resourced governments decide that going dark is safer than staying online, a business has to ask how long it could survive being offline and how quickly it could patch. The full step-by-step playbook lives in the PHP2Shell Emergency Checklist.

Warning

Automatic WordPress updates will not apply this fix. The vulnerability is in PHP itself, so only upgrading PHP closes it.

The bigger question: patch, or move on?

Patching closes this hole. It does not answer the strategic question PHP2Shell raises for businesses on WordPress or older PHP applications: how many more emergencies like this can you afford? Three facts make the question urgent. Most exposed PHP runs unsupported versions, so for about 79% of versioned services just patch means a risky major upgrade under time pressure. AI is speeding up vulnerability discovery, because bugs that hid for a decade were found and turned into exploits within days, and older codebases will be scanned more and more by the same tools. We expand on that in AI Found PHP2Shell. WordPress risk stacks up as well: the PHP runtime, WordPress core, plugins and themes are each a separate layer to patch, and Patchstack research has repeatedly found that most WordPress vulnerabilities live in plugins rather than core. Modern stacks are not immune to vulnerabilities, but a TypeScript, Next.js and Payload CMS architecture changes the shape of the risk with static or edge-rendered public pages, no plugin marketplace running third-party code with full privileges, typed code with automated dependency scanning, and reproducible infrastructure that can be redeployed in minutes. We set out that argument in Beyond the Patch.

Sources and references

Wiz Research published PHP2Shell: AI uncovers critical RCE vulnerabilities affecting 70% of the Internet at wiz.io/blog/php2shell-php-rce. Recorded Future's Insikt Group explained the exploitation timeline at recordedfuture.com/blog/php2shell-vulnerability-exploitation. SOCRadar listed affected versions and fixes at socradar.io/blog/php2shell-cve-2026-109618-cve-2026-109619. CNN reported the global shutdowns at cnn.com/2026/10/21/tech/php2shell-vulnerability-ai-intl, CNBC covered the government sites at cnbc.com/2026/10/21/government-websites-go-dark-as-software-flaw-sparks-security-scramble.html, and Axios called it Black October at axios.com/2026/10/22/php-vulnerability-security-update-websites. TidBITS covered the 70% figure at tidbits.com/2026/10/21/php2shell-vulnerabilities-put-70-of-websites-at-risk, W3Techs published usage statistics at w3techs.com/technologies/comparison/pl-php, the PHP Group lists supported versions at php.net/supported-versions.php, and Patchstack's State of WordPress Security is at patchstack.com/whitepaper/state-of-wordpress-security-in-2025.

Affected and fixed PHP versions

PHP branchVulnerableFixed inSupport status
8.5below 8.5.128.5.12Active
8.4below 8.4.278.4.27Active
8.3below 8.3.368.3.36Security fixes only
8.2below 8.2.358.2.35Security fixes only
8.1 / 8.0 / 7.4allSource backport only; check your distributionEnd of life
7.3 and olderallNo fixEnd of life

About 79% of versioned PHP services run unsupported branches, and PHP 7.3 and older will never receive an official fix.

What to do right now

  1. 1

    Find who owns PHP on your servers

    On shared or managed hosting the owner is your provider. Get written confirmation of the PHP build you are running.

  2. 2

    Upgrade to a fixed release

    Move to 8.5.12, 8.4.27, 8.3.36 or 8.2.35, restart PHP-FPM or the web server, and rebuild any container images.

  3. 3

    Apply temporary hardening if you cannot patch today

    Set session.upload_progress.enabled=0, lower post_max_size, limit request sizes at the proxy and put a WAF in front. These steps reduce exposure; they do not make you safe.

  4. 4

    Look for signs of compromise

    Review activity from 20 October onward, and earlier if you can, watching for repeated memory-limit errors, oversized PHPSESSID cookies, and php-fpm or httpd processes spawning shells, curl or wget.

  5. 5

    Rotate secrets

    Change database passwords, API keys and payment gateway credentials if there is any chance worker memory was exposed.

A confirmed PHP build on every server, fixed runtimes with restarted workers, and secrets rotated if worker memory may have been exposed.

PHP powers the majority of the web According to W3Techs, 70.8% of websites with a known server-side language run PHP. WordPress alone runs 59.2% of websites with a known CMS, which is why coverage described PHP2Shell as affecting 70% of the internet. The figure measures exposure, not confirmed compromises.

Conclusion

PHP2Shell will not be the last critical PHP flaw, and AI-driven discovery means the next one may arrive faster. Patch today, confirm in writing what every server runs, hunt for signs of compromise from 20 October onward, and then use the incident as the trigger to decide whether your PHP estate should be upgraded, re-platformed or retired. App Corp's senior engineers help businesses run that exposure review and deliver the migration on fixed, outcome-based pricing, with typical delivery in eight to twelve weeks.

Frequently Asked Questions

Key Takeaways

  • PHP2Shell is two critical flaws in the PHP engine, CVE-2026-109618 and CVE-2026-109619, each rated 9.2 on CVSS v4.0
  • Both allow unauthenticated remote code execution or memory disclosure, with no login and no vulnerable plugin required
  • The flaws sit in PHP itself, so WordPress, Drupal, Joomla, Laravel and custom PHP apps are exposed on a vulnerable build
  • Fixed versions 8.5.12, 8.4.27, 8.3.36 and 8.2.35 shipped on 21 October 2026; PHP 7.3 and older received no fix at all
  • Governments in France, Denmark, Finland and the Netherlands took websites offline while they patched
  • Patching is step one; the real decision is whether to keep a decade-old PHP stack or move to TypeScript and Next.js
Ready to migrate?

Order a WordPress to Payload CMS migration

If this series convinced you to move off WordPress, order the migration directly on Contra. A fixed-scope engagement covering the site rebuild, content and media migration, technical SEO foundations, testing, and handover — delivered by the same engineering team that wrote these guides.

$250 fixed priceUp to 3 weeks deliveryUp to 10 pages migrated
Order on Contra

We value your privacy

We use strictly necessary cookies to keep our site secure and functional. With your consent, we also use performance cookies to understand how you interact with our site, and functional cookies to remember your preferences. Read our full Cookie Policy