Last updated: November 1, 2026. By Kabeer Ahmed.
PHP2Shell is the name for two critical flaws in PHP itself, CVE-2026-109618 and CVE-2026-109619. They can let an unauthenticated attacker run code on a web server. Fixes shipped on October 21, 2026, and attacks are now confirmed. If your site runs on PHP (and most WordPress sites do), this page covers what to check and what to do.
The short version
- Fixed versions: PHP 8.5.12, 8.4.27, 8.3.36 and 8.2.35, or your Linux distribution’s patched package (PHP.net).
- Severity: each CVE is rated CVSS 9.2 (CERT-EU).
- Exploited: CISA added both CVEs to its Known Exploited Vulnerabilities (KEV) catalog on October 26, 2026 (CISA).
- No full workaround: PHP’s advisory says updating is the only reliable mitigation (PHP security advisory).
What happened
On October 21, 2026, the PHP project released security updates fixing two flaws: CVE-2026-109618, a memory corruption bug triggered during out-of-memory handling, and CVE-2026-109619, a stale internal request-state bug (CERT-EU, CISA). Researchers at Wiz named the pair “PHP2Shell” and say the vulnerable code had been present for more than a decade (Wiz).
The AI angle is real. Wiz says frontier AI models substantially lowered the barrier to building a working exploit chain that would otherwise have been at the edge of what human researchers could practically do (Wiz). The PHP Foundation describes how the problem was first spotted in 2024 and how fixing it stalled (PHP Foundation). The same tools that help defenders find old bugs also make them cheaper to weaponize, which makes patching speed matter more than ever.
Who is affected
The flaw is in PHP, not in your app. Wiz says PHP powers about 70% of websites, including WordPress, Drupal, Joomla and MediaWiki (Wiz). According to CERT-EU, every PHP installation that serves web requests is at risk, including PHP-FPM, Apache with mod_php, php-cgi, FrankenPHP and LiteSpeed, with mod_php considered the highest-risk setup (CERT-EU).
Exposure is wide. The Hacker News, citing Censys, reports about 32.5 million PHP services still running an affected version, and lists vendors whose products bundle PHP (The Hacker News). Even if you don’t “run PHP,” a NAS, appliance or vendor portal might.
How to check your PHP version
- WordPress: Tools > Site Health > Info > Server shows the PHP version your site uses.
- Hosting panel (hPanel, cPanel, Plesk): look for a “PHP version” or “PHP configuration” page.
- Server with SSH: run
php -v. The command-line PHP can differ from the web PHP, so confirm in the panel too.
You want 8.5.12, 8.4.27, 8.3.36, 8.2.35 or later on your branch, or a distribution package that states it includes the fix.
How to fix or mitigate
- Update PHP. On a VPS, install your distribution’s patched packages, then restart PHP-FPM or the web server so every worker loads the fixed build. CERT-EU stresses restarting workers (CERT-EU).
- On shared hosting, ask your host in writing whether the PHP build serving your site is patched for CVE-2026-109618 and CVE-2026-109619, and which version you’re on.
- PHP 8.1 or older: these branches get no regular updates. CISA says systems that can’t be updated should be taken offline until they are patched (CISA). Plan a move to 8.2 or newer, back up first, and test login, forms and checkout after switching.
- If you truly can’t update today: PHP’s advisory lists interim configuration changes but says there is no complete generic configuration mitigation (PHP security advisory). Treat any workaround as a bridge, not a fix.
- Agencies and IT teams: inventory every system that runs PHP, including bundled PHP in other products (CISA).
While you debug, don’t paste server logs or keys into a public chatbot. See using AI at work without leaking company data. Testing after an upgrade follows the same habits as in how to test an AI feature.
Timeline
- Oct 21, 2026: PHP ships 8.5.12, 8.4.27, 8.3.36 and 8.2.35 (PHP.net). CISA urges immediate patching (CISA).
- Oct 24, 2026: Adel Karimi of Perplexity reports confirmed remote code execution against honeypot systems (The Hacker News).
- Oct 26, 2026: CISA adds both CVEs to KEV (CISA).
- Oct 29, 2026: deadline for US federal civilian agencies to apply fixes (The Hacker News). Treat it as your deadline too.
Related
A second AI-found bug hit the web stack the same week: HTTP2Shell, the Brotli bug in Node.js and Python. If you build agents that touch servers, read designing safe AI agent workflows.
Sources
- PHP.net 2026 news archive
- PHP security advisory GHSA-6wmf-4rv5-p3rp
- PHP Foundation blog, Oct 21, 2026
- CERT-EU advisory 2026-018
- CISA alert, Oct 21, 2026
- CISA KEV addition, Oct 26, 2026
- Wiz research
- The Hacker News
This explainer reports public advisories and news coverage as of the date above. Check your host’s and vendors’ advisories for your specific setup.



