~ / resources / news / php2shell
6 min read
PHP2Shell: Two Critical PHP Flaws Put Most of the Web at Risk
PHP2Shell is a pair of critical bugs in the PHP language itself. They let an attacker run code on a web server without logging in. The fix is out, but it has to be installed server by server, and a WordPress update won’t do it.

At a glance
WHAT HAPPENED
PHP fixed two critical flaws in the language itself on Oct 21, 2026: CVE-2026-109618 and CVE-2026-109619, both rated CVSS 9.2.
WHO IT AFFECTS
Nearly every PHP version back to 5.4, on any setup that serves web requests. That includes sites running WordPress, Drupal and Joomla.
THE FIX
Update PHP to 8.5.12, 8.4.27, 8.3.36 or 8.2.35. Your host or server admin has to do it. CMS and plugin updates don’t fix it.
THE CATCH
Details leaked a day early, and security firms report attacks in the wild. PHP 8.1 and older get no official releases.
On October 21, 2026, the PHP project released emergency fixes for two critical vulnerabilities in the PHP language itself, nicknamed PHP2Shell. Tracked as CVE-2026-109618 and CVE-2026-109619, both are rated CVSS 9.2. An attacker can use them to run code on a web server without logging in.
PHP sits underneath a huge share of the web. Wiz, the security firm that found the bugs, says PHP powers 70% of all websites, including sites built on WordPress, Drupal and Joomla. That’s why this one matters even if you’ve never written a line of PHP.
What PHP2Shell is
PHP2Shell is two separate memory bugs that have sat in PHP for years:
–
CVE-2026-109618 is an out-of-memory corruption bug. In plain terms, PHP can be pushed into writing data where it shouldn’t when memory runs short.
–
CVE-2026-109619 is a use-after-free bug caused by stale global state. PHP keeps using a piece of memory after it has already let it go.
Both lead to the same two problems. The first is remote code execution with no login, which means an attacker can run their own commands on the server. The second is memory disclosure: Wiz and Recorded Future say an attacker can read memory from other requests, which may contain passwords, session tokens, API keys and certificates.
Both flaws carry a CVSS v4.0 score of 9.2, which is Critical. A leak before the official disclosure claimed 10.0. The official score is 9.2.
Who is affected
The short answer: almost anyone running PHP on a web server.
–
Versions: nearly every PHP version back to PHP 5.4, according to Wiz and Recorded Future.
–
Setups: every PHP setup that serves web requests, including PHP-FPM, Apache mod_php, php-cgi, FrankenPHP and LiteSpeed. PHP’s advisory rates mod_php as the highest risk.
–
Apps: Wiz says it showed code execution without a login on the latest WordPress, Drupal and Joomla container images.
IMPORTANT
A WordPress, theme or plugin update does not fix PHP2Shell. The bugs are in PHP, the language your site runs on, so PHP itself has to be updated. On shared or managed hosting, that’s your host’s job. On your own server or VPS, it’s yours.
The leak, CERT-EU and attacks in the wild
The fix was planned for October 22. On October 20, details leaked on Hacker News, and security firm watchTowr reproduced one of the bugs. That evening, CERT-EU, the cybersecurity service for EU institutions, advised organizations that can’t patch quickly to consider isolating their internet-facing PHP apps or taking them offline.
Attackers didn’t wait. Cloudflare reported the first attack attempts on October 21 at 07:43 UTC, hours before PHP published the fix at 14:00 UTC, a day earlier than planned. Recorded Future and watchTowr both report exploitation in the wild. Separately, Patchstack reported one attacker using valid UpdraftCentral dashboard keys to install backdoors on connected WordPress sites.
No count of affected sites or victims has been published.
What to do now
–
Check your PHP version. Your hosting control panel usually shows it. On your own server, the php -v command prints it.
–
Update to a fixed release: PHP 8.5.12, 8.4.27, 8.3.36 or 8.2.35.
–
On PHP 8.1 or older? There are no official releases. The PHP security team published minimal source backports for 7.4, 8.0 and 8.1. Ask your vendor or host, or upgrade to a supported version.
–
On shared or managed hosting? Contact your host and ask whether PHP has been patched on your server.
–
Can’t update yet? Follow the mitigations in the php.net advisory, and consider CERT-EU’s advice to isolate or take exposed apps offline until you can.
If you run a small self-managed stack, like the setup in our lean dev stack for under $20 a month, nobody patches PHP for you. Treat this as today’s job.
AI helped find the bugs
Wiz Research found PHP2Shell. The team (Sagi Tzadik, Shir Tamari, Nir Ohfeld and Tomer Schwartz) found the first bug on August 19 and confirmed code execution on Drupal and then WordPress within two days. Calif and OpenAI helped with discovery, coordination and patch verification. Wiz reported the bugs to PHP on August 24, and PHP began a coordinated fix on September 21.
Wiz says AI tools were part of the work and names Wiz Atlas, Gemini 4 Argon and GPT-5.6 Sol. Google says Gemini 4 Argon helped with discovery, exploit development, detection and patch validation. These are the vendors’ own statements.
It’s another sign that AI is changing security on both sides. We covered a related idea in NVIDIA’s plan to box in AI agents: when AI gets good at finding and using weaknesses, the walls have to hold.
Our take
Opinion from Mashfiquar Rahman, Sudo Review’s founder:
In the age of AI, exploits like this can be found and built faster than ever. That’s a grim reality. Realistically, PHP2Shell can’t be fixed quickly, because PHP is so widely used and there aren’t enough people to patch every server. The researchers know the exploit and they know the fix, but the infrastructure is so vast that it won’t be easy. It’s going to take a while.
What to watch
–
How fast big hosting providers confirm their PHP fleets are patched.
–
Whether more reports of exploitation, or affected-site numbers, appear from security firms.
–
Updates to the php.net advisory, especially for older PHP versions.
$ sudo
verdict
Serious, fixable, and slow to fix everywhere.
The patch exists and the steps are clear. The risk is the long tail: old PHP versions, forgotten servers and shared hosts that update late. If you run a PHP site, confirm your PHP version today instead of waiting for your host to tell you.
FAQ
What is PHP2Shell?
PHP2Shell is the nickname for two critical vulnerabilities in the PHP language, CVE-2026-109618 and CVE-2026-109619. They let an attacker run code on a web server without logging in, and can leak memory that may hold passwords, tokens and keys.
Which PHP versions are affected?
Nearly every version back to PHP 5.4. The fixed releases are PHP 8.5.12, 8.4.27, 8.3.36 and 8.2.35. PHP 8.1 and older get no official releases, only source backports for 7.4, 8.0 and 8.1.
Does updating WordPress fix PHP2Shell?
No. The flaws are in PHP itself, so WordPress, theme and plugin updates don’t fix them. Your host or server admin has to update PHP.
Is PHP2Shell being exploited?
Yes, according to several security firms. watchTowr reproduced a bug after the leak, and Cloudflare reported attack attempts starting Oct 21, 2026, at 07:43 UTC, before the official fix was released.
What is the CVSS score of PHP2Shell?
Both flaws are rated CVSS v4.0 9.2, which is Critical. A leak before disclosure claimed 10.0, but the official score is 9.2.
Who found PHP2Shell?
Wiz Research found the flaws, with help from Calif and OpenAI on discovery, coordination and patch verification. Wiz says AI tools were part of the work.
Some links on this page may be affiliate links, always labeled. Opinions are ours. Verdicts aren’t for sale. How we work.
Sources
On this page
01
07
09
10
11
$ sudo
request –tool
Want us to test an AI tool?
← Back to

