On October 20, the PHP community was shaken to its core.
Two vulnerabilities collectively named PHP2Shell (CVE-2026-109618 and CVE-2026-109619) were publicly disclosed, affecting every PHP version from 5.4 through 8.5 — over 12 years of releases. CVSS v4.0 score: 9.2. Security firm WatchTowr rated it a perfect 10.0.
This isn’t one of those “please update when convenient” advisories. This is a patch-now-or-take-your-site-offline situation.
The NSA and UK NCSC both issued emergency advisories. At least one European government took its website offline. Wikimedia and 4chan went dark preemptively.
How Bad Is It
The numbers speak for themselves:
- Approximately 69% of all websites run PHP
- Palo Alto Unit 42 identified 22.6 million exposed instances potentially vulnerable
- Attack vector: a single unauthenticated HTTP request enables remote code execution
- WordPress, Drupal, Joomla, and Magento are all affected
- Every execution mode is vulnerable: mod_php, PHP-FPM, php-cgi, FrankenPHP, LiteSpeed
The critical detail: the vulnerability triggers during PHP’s request parsing phase, before any application code runs. Authentication, firewalls, WAF rules — none of it can stop an attack at this level.
The Vulnerabilities Explained
CVE-2026-109618 — When PHP exhausts memory during request processing, the cleanup phase incorrectly treats partially initialized data as valid. Attackers exploit this window to inject and execute arbitrary code.
CVE-2026-109619 — PHP worker processes reuse memory between requests without properly clearing the previous request’s state. A new request can access this stale memory, leading to heap use-after-free and ultimately remote code execution.
In plain terms: PHP’s HTTP request handling has cracks in its foundation. Attackers don’t need to touch your login page — they get a shell directly from the parser.
Timeline
| Date | Event |
|---|---|
| August 2026 | Vulnerabilities discovered (reportedly with AI assistance) |
| October 17 | AWS detects exploitation attempts in the wild |
| October 20 | Public disclosure by the PHP project |
| October 21 | Official patches released |
| October 22 | PoC code circulating on GitHub, scanning attacks ramping up |
How to Fix It
Option 1: Upgrade immediately (the only recommended approach)
| PHP Branch | Fixed Version |
|---|---|
| 8.5 | 8.5.12+ |
| 8.4 | 8.4.27+ |
| 8.3 | 8.3.36+ |
| 8.2 | 8.2.35+ |
Versions 7.4, 8.0, and 8.1 are end-of-life but received source-only patches. If you’re still on these versions, this is your last wake-up call to migrate.
Option 2: Temporary mitigation (only if you can’t upgrade right now)
Add to your php.ini:
session.upload_progress.enabled = Off
Then restart your web server. This only reduces the exploitability of CVE-2026-109618 and does nothing for CVE-2026-109619. Not a long-term solution.
Option 3: If you use shared hosting
Contact your hosting provider immediately and confirm they’ve applied the patches. If they haven’t, either push hard for a timeline or consider migrating to a provider that responds faster. Your website’s security shouldn’t depend on someone else’s response time.
How to Check if You’ve Been Compromised
- Review web server logs for anomalous POST requests, especially those with unusually long or malformed session data
- Monitor PHP worker processes for suspicious child processes (e.g.,
/bin/sh,wget,curlinvocations) - Scan for newly created suspicious files or cron jobs on the server
Why This Time Is Different
Many have compared PHP2Shell to Heartbleed in 2014. The parallels are striking:
- Both are vulnerabilities in foundational runtime layers, not application-level bugs
- Both have massive blast radiuses (Heartbleed hit OpenSSL; PHP2Shell hits PHP)
- Both saw wild exploitation before patches were widely deployed
- Both require infrastructure-level responses
But PHP2Shell is arguably worse: Heartbleed leaked memory contents. PHP2Shell hands attackers a shell. One peeks; the other takes over.
Another noteworthy detail: reports indicate AI systems (including Gemini and GPT models) assisted in discovering these vulnerabilities. Both attackers and defenders are leveraging AI to accelerate their work. Vulnerability discovery is getting faster — but patching response times aren’t necessarily keeping up.
Action Checklist for Webmasters
- Right now: SSH into your server, run
php -vto confirm your version - Today: Upgrade to a patched version or apply the temporary mitigation
- This week: Audit server logs for signs of exploitation
- Long-term: If still on EOL PHP versions, plan migration to 8.2+
- Always: Keep PHP, your CMS, and all plugins on auto-update
The Bottom Line
69% of websites run PHP. 22.6 million instances are exposed on the public internet. PoC code is already circulating.
If you manage any PHP website — a WordPress blog, a Magento store, a custom application — this is not a “wait and see” moment.
Check your version. Apply the patch. Confirm your hosting provider has acted.
Your users’ data, your business, and your reputation depend on what you do in the next few hours.
Sources:
