Last updated Oct 21, 2026. We will update this guide as hosts and Linux vendors ship fixed packages.
Short answer: PHP2Shell is the name for two critical flaws in PHP itself, CVE-2026-109618 and CVE-2026-109619. Both are rated CVSS v4.0 9.2 and can let an attacker run code on your server without logging in. The only complete fix is to run PHP 8.2.35, 8.3.36, 8.4.27 or 8.5.12 or newer, released on 21 October 2026 (php.net advisory). Nothing in Joomla or WordPress fixes it, and no plugin or extension does either. If your site runs PHP 8.1 or older, there is no official fixed release: you need to move to PHP 8.3 or later, or get a patched package from your Linux vendor.
The fix in five steps: 1) find the PHP version your site actually serves, 2) get it onto a fixed build, 3) confirm the fix is really running, 4) add the interim hardening if you are still waiting, 5) plan an exit if your host will not move. Each step has its own section below, with steps for cPanel, Plesk, CloudLinux, VPS servers, Joomla 4, 5 and 6.2, and WordPress.
What is PHP2Shell, in plain English?
PHP is the engine that runs Joomla and WordPress. Every page of your site, from the home page to the admin login, is built by PHP on your web server. PHP is installed by your hosting company, not by you and not by your CMS.
PHP2Shell is a fault in that engine. A stranger can send your server one specially crafted web request, just like a normal visit but built to trigger the fault. The server can then run the stranger’s commands. No password is needed and no account is needed.
Because the fault sits in PHP, it hits before Joomla or WordPress even starts. Your admin password, two-factor login, security plugin or Joomla access rules never get a say. php.net confirms there is a working attack that triggers before any application code runs on the most common Apache setup.
An analogy: your Joomla or WordPress security is the lock on your apartment door. PHP2Shell is a broken lock on the building’s front door, and it opens the service corridor behind every apartment. A better apartment lock does not help. The building manager, your host, has to replace the front-door lock, which here means installing the fixed PHP release.
What can happen to your site if you ignore it?
Running commands on your server means an attacker can do roughly what your site itself can do. These are the usual results of that kind of access on any hacked site, not specific reported PHP2Shell cases:
- Defacement. Your pages are replaced or altered with the attacker’s content.
- Hidden malware or spam. Code is slipped into your files or database that redirects visitors, shows spam links or infects visitors’ browsers.
- Stolen data. The site can read its own database, so customer details, orders, contact form submissions and user accounts can be copied.
- Your server attacks others. The site is used to send spam email, host phishing pages or attack other websites, often without you noticing.
- Google warnings and lost rankings. Google may label the site This site may be hacked in search results or show a red browser warning, and visitors and rankings drop while that lasts. See Google’s Security Issues report help.
- Hosting suspension. Hosts commonly suspend accounts that send spam or host malware, which takes the whole site offline.
- Cleanup cost and downtime. Removing malware, restoring backups, resetting every password and asking Google for a review takes time and money, and data that was stolen cannot be taken back.
If you sell online, handle bookings or collect personal data, a breach can also bring legal duties to report it to customers or regulators, depending on where you and they are.
Which PHP versions are safe, and which are not?
Check the first two numbers of your PHP version (the branch), then the last number (the patch level). Versions are from the PHP 8 changelog, the CERT-FR alert and NVD; support dates are from php.net’s supported versions and end-of-life pages.
| Your PHP branch | Vulnerable | Fixed in | Branch support (php.net) | What you do |
|---|---|---|---|---|
| 8.5 | 8.5.11 and below | 8.5.12 | Active support to 31 Dec 2027 | Update to 8.5.12 |
| 8.4 | 8.4.26 and below | 8.4.27 | Active support to 31 Dec 2026, security to 31 Dec 2028 | Update to 8.4.27 |
| 8.3 | 8.3.35 and below | 8.3.36 | Security fixes only, to 31 Dec 2027 | Update to 8.3.36 |
| 8.2 | 8.2.34 and below | 8.2.35 | Security fixes only, ends 31 Dec 2026 | Update to 8.2.35, then plan 8.3+ |
| 8.1 | All | No official release | End of life since 31 Dec 2025 | Move to 8.3+ or use a vendor backport |
| 8.0, 7.x, 5.x | All | No official release | End of life | Move to a supported branch |
| 8.6 release candidates | Not covered by the fixed releases | None yet | Testing only, not for production | Do not run in production |
The PHP team also published minimal source-only patches for 7.4, 8.0 and 8.1 for people who compile PHP themselves. They are not releases, and a shared hosting panel cannot offer them.
Still on Joomla 3? Why patching PHP is not an option
This is the hardest case, and it is worth being precise about. Joomla’s official technical requirements list PHP 8.0 as the recommended version for Joomla 3.x, and no newer PHP version is listed. Joomla 3 support ended on 17 August 2023, and the extended LTS version ended on 17 February 2025, so Joomla 3 gets no more updates to make it work on newer PHP. Joomla volunteers on the official Joomla forum report that 3.10 does not work on PHP 8.2 or later and is unreliable on 8.1. Every branch that received the PHP2Shell fix is 8.2 or newer. Put those facts together and no officially supported Joomla 3 setup can run a patched PHP release.
What about the stopgaps? Each one helps a little and costs something:
| Option | What it gets you | Where it falls short |
|---|---|---|
| Source-only backports for 7.4, 8.0, 8.1 | The PHP2Shell fix for people who compile PHP themselves | No releases and no binaries. Shared, reseller and most managed hosts cannot install them, and you take on maintaining a custom PHP build. |
| Vendor or distribution backport (for example a Linux LTS package) | A patched PHP 8.0 or 8.1 from a vendor | Only on servers you or your host control at the OS level, often paid, and only covers PHP. Joomla 3 itself still gets no security fixes. |
| Interim php.ini settings and a WAF | Fewer known attack paths | php.net says they do not make an installation safe, and WAF rules can be bypassed by direct-to-origin traffic. |
| Forcing Joomla 3 onto PHP 8.2+ | A patched PHP | Unsupported: expect white pages, 500 errors and broken extensions, which is why hosts that move clients forward often break Joomla 3 sites. |
So the risk of staying is not only PHP2Shell. It is that every future PHP or Joomla vulnerability lands on a site with no supported fix. The lasting fix is to move the site to Joomla 6.2, which requires PHP 8.3 or newer, so it runs on a branch that gets security releases until at least the end of 2027. Joomla does not allow skipping straight from 3 to 6: the path is 3.10 → 4.4 → 5.x → 6.x, and our Joomla 3 to 6 upgrade guide walks through each hop. Run the free Joomla 6 compatibility check first to see which extensions have Joomla 6 versions and which need replacing; that list is what decides how long the move takes. If you would rather have the migration done for you, that is what our Joomla upgrade service covers.
Old WordPress on PHP 7.4 or 8.1? WordPress is gentler: current WordPress still runs on PHP 7.4 but recommends 8.3 or greater. Update WordPress core, plugins and themes first, then switch the branch as in Step 2b. Plugins abandoned by their authors are the usual blocker, so replace them before the switch.
How do the two flaws work?
Both flaws are about what PHP leaves behind when a web request ends badly. According to the NVD descriptions supplied by the PHP security team:
- CVE-2026-109618: when PHP runs out of memory mid-request, some internal request memory can be left uninitialised. The cleanup step then reads it as if it were valid, and several out-of-memory tricks can turn that into remote code execution.
- CVE-2026-109619: some global state can keep pointing at request memory after it has been freed. A later request on the same PHP worker can read that stale state before it is reset, which can also lead to remote code execution.
php.net says the risk covers all PHP installations serving web requests, including PHP-FPM, Apache with mod_php, php-cgi, FrankenPHP and LiteSpeed, and is highest for mod_php, where a demonstrated exploit runs before any application code. For a Joomla or WordPress site this means your login page, security extension and file permissions are not in the way: the attack happens one layer below the CMS.
| Fact | Detail | Source |
|---|---|---|
| CVSS v4.0 score | 9.2 for both CVEs (vector AV:N/AC:H/AT:P/PR:N/UI:N) | NVD |
| Advance notice | 20 Oct 2026, release set for 21 Oct 14:00 UTC (7:30 PM IST) | php.net |
| Fixed releases | 8.5.12, 8.4.27, 8.3.36, 8.2.35 on 21 Oct 2026 | php.net |
| Changelog entry | “Fixed GHSA-w8hw-w9fx-j79w, GHSA-6wmf-4rv5-p3rp (Avoid state corruption via bailout)” in all four branches | PHP changelog |
| NVD publication | 21 Oct 2026, 14:17 UTC (7:47 PM IST), status “Received” | NVD |
| CISA assessment | On 21 Oct, CISA’s SSVC entry on NVD rated exploitation as “none” and technical impact as “total”; NVD status is still “Received” (not yet analysed) | NVD |
| Attack traffic | Cloudflare says it observed attack traffic after the CVE details leaked | Cloudflare |
Step 1: How do I check which PHP version my site really runs?
Check the version the web server uses for your site. The command-line php -v on the same server can be a different build, so do not rely on it alone.
In Joomla 4, 5 or 6.2
Log in to the Administrator, open System → System Information, and read PHP Version on the System Information tab. The PHP Information tab shows the full phpinfo output, including the Server API line (for example FPM/FastCGI or Apache 2.0 Handler), which tells you whether you are on the higher-risk mod_php.
In WordPress
Go to Tools → Site Health → Info and expand Server. The PHP version and Server API rows are listed there (WordPress Site Health docs).
With no admin access
Upload a one-line file, open it in the browser, note the version, and delete it immediately, because phpinfo output helps attackers:
<?php echo PHP_VERSION, " ", PHP_SAPI;
Name it something random (not info.php). It prints the exact version and the server API, for example 8.3.36 fpm-fcgi. PHP manual: phpversion()
Checking many sites
Repeat the same check per site, because one hosting account can run different PHP branches per domain. Record domain, branch, patch level and Server API in a sheet, and sort by the table above.
Step 2: How do I update PHP to a fixed version?
Two different things are called “updating PHP”. A patch update (8.3.35 to 8.3.36) is a drop-in security fix that your host installs on the server. A branch change (8.1 to 8.3) is something you usually select yourself and must test, because extensions and plugins can break. PHP2Shell needs the patch update everywhere, and a branch change if you are on 8.1 or older.
cPanel (shared hosting)
- Open Software → MultiPHP Manager (cPanel docs), or Select PHP Version on CloudLinux servers.
- Check which branch your domain uses. The selector picks a branch; the patch level inside it is whatever the host has installed.
- If you are on 8.1 or older, take a backup, then pick 8.3 or newer and test the site (see Step 2b).
- Run the Step 1 check again. If the patch level is still below the fixed build, open a ticket (template in Step 5).
Server admins with WHM install the fixed EasyApache 4 packages through the normal system update and manage versions in MultiPHP Manager for WHM.
Plesk
In Plesk, open the domain, then PHP (PHP Settings), and choose the PHP version. Plesk’s own advisory (updated 21 Oct 2026, 15:13 UTC / 8:43 PM IST) lists the state of its PHP builds:
| Plesk PHP | Linux | Windows |
|---|---|---|
| 8.2 | Fixed in 8.2.35 | In development |
| 8.3 | Fixed in 8.3.36 | In development |
| 8.4 | Fixed in 8.4.27 | In development |
| 8.5 | Fixed in 8.5.12 | In development |
| 7.4, 8.0, 8.1 | In development | In development |
To see which builds a Plesk server has, go to Tools & Settings → PHP Settings; the version is part of each handler name. On Linux over SSH, /opt/plesk/php/8.3/bin/php -v shows it (swap 8.3 for your branch).
Plesk also lists its own panel engine (sw-engine) as affected on all versions, with hotfixes planned as 18.0.80#11 and 18.0.81#4. If you run Plesk on Windows, use the interim hardening in Step 4 until the builds ship, and keep checking Plesk’s advisory.
CloudLinux, LiteSpeed and other managed hosts
On CloudLinux, the per-site PHP selector uses CloudLinux’s own alt-php builds, so the patch arrives when CloudLinux ships it and your host installs it. LiteSpeed is named in php.net’s list of affected setups. On managed WordPress and Joomla hosts with no PHP setting, the host alone controls the patch: ask for the exact version and date (Step 5).
Your own VPS or dedicated server
- Distribution packages (Ubuntu, Debian, RHEL and clones): install the vendor security update with your normal package manager. Distributions often backport security fixes without changing the upstream version number, so confirm with the vendor’s security notice for these CVE IDs, not by version string alone.
- Third-party repositories or source builds: upgrade to the fixed upstream release from php.net downloads or your repository once it publishes the build.
- Docker images: pull an image built on the fixed release, rebuild, and redeploy every container; a running container never patches itself.
- Then restart PHP (Step 3). Without a restart the old code keeps serving requests.
Step 2b: Moving off PHP 8.1 or older without breaking the site
| CMS version | PHP minimum | PHP recommended | Can it reach a fixed branch? |
|---|---|---|---|
| Joomla 6.x (incl. 6.2) | 8.3.0 | 8.4 | Yes, every supported setup is 8.3+ (Joomla docs) |
| Joomla 5.x | 8.1.0 | 8.3 | Yes, move to 8.3 (Joomla docs) |
| Joomla 4.x | 7.2.5 | 8.2 | Yes on 8.2, but upgrade Joomla too (Joomla docs) |
| Joomla 3.x | 5.3.10 | 8.0 (highest listed) | No; see the Joomla 3 section below (Joomla docs) |
| WordPress (current) | 7.4 (legacy) | 8.3 or greater | Yes (WordPress requirements) |
- Back up files and database first (how to back up Joomla).
- Update the CMS core, then every extension, plugin and theme, on the old PHP version.
- For Joomla, scan extensions for compatibility with our free Joomla 6 compatibility check.
- Switch the branch on a staging copy if you have one, or during a quiet hour on live.
- Test front end, forms, checkout, login and admin. If you get a white page or 500 error, switch back and use this guide to find the failing extension.
- Still on Joomla 3? PHP cannot move until Joomla does; see the Joomla 3 section.
Step 3: How do I confirm the patch is actually live?
- Repeat the Step 1 check through the website (Joomla System Information, WordPress Site Health or the one-line file). The version must be 8.2.35, 8.3.36, 8.4.27, 8.5.12 or higher, or a vendor package your vendor confirms fixes both CVEs.
- On a server, restart every PHP process: restart PHP-FPM pools, and for mod_php restart Apache fully. php.net’s advisory tells admins to restart every worker for settings to apply; the same applies to new binaries.
- Check that no process still uses the old library. On Linux this should print nothing:
grep -lE ' /(usr|lib|opt).*\(deleted\)$' /proc/[0-9]*/maps 2>/dev/null
Then check every site on the account, not just the main one; add-on domains can run different branches.
Step 4: What can I do while I wait for my host?
php.net lists interim measures that reduce exposure to specific attack paths but, in its words, do not make an installation safe. They must be set in php.ini, the PHP-FPM pool or the web server config, which apply before the request is parsed. php.net says not to rely on ini_set() or FPM .user.ini.
| Setting | Targets | Notes from php.net |
|---|---|---|
session.upload_progress.enabled=0 | CVE-2026-109619 | Blocks the confirmed session paths, not other variants. Neither Joomla nor WordPress core needs it. |
fatal_error_backtraces=0 (PHP 8.5 only) | CVE-2026-109619 | Blocks the confirmed fatal backtrace path only. |
memory_limit=-1 set with php_admin_value | CVE-2026-109618 | Removes the controllable memory-limit failure; use a container or cgroup limit instead, not RLIMIT_AS or RLIMIT_DATA. |
post_max_size = 8M (no uploads) or 32M (uploads), upload_max_filesize lower | CVE-2026-109618 | Also cap request size, field count, multipart parts, headers and nesting at the web server or proxy. |
Remove invalid or deprecated per-request settings (for example in .htaccess) | CVE-2026-109619 | Hiding errors with display_errors or error_reporting does not help. |
A Joomla site with large media uploads or a WordPress shop importing big CSV files may need the 32M limit. Our Joomla .htaccess guide shows where per-directory PHP settings live, so you can find and remove deprecated php_value lines.
Does Cloudflare or a WAF protect me?
Partly. Cloudflare says customers using its free or paid WAF have been protected by default against known PHP2Shell attacks since 21 Oct 2026, 03:02 UTC (8:32 AM IST), and still tells customers to patch PHP (Cloudflare blog). A WAF only helps if attackers cannot reach your server directly by IP, so restrict the origin to Cloudflare’s IP ranges. Treat any WAF rule as a stopgap.
Step 5: What if my host will not update PHP?
Send a short ticket that leaves no room for a vague answer:
Subject: PHP2Shell (CVE-2026-109618 / CVE-2026-109619) patch date
Hi, my site [domain] runs PHP [version]. PHP released 8.2.35, 8.3.36,
8.4.27 and 8.5.12 on 21 October 2026 to fix two unauthenticated remote
code execution flaws (https://www.php.net/). Please confirm:
1. the date the fixed build will be installed for my account, and
2. if you use vendor-backported packages, the package version that
includes both fixes.
If my branch (8.1 or older) will not be patched, which supported
branch can I switch to today?
Thanks.
If the host cannot give a date, or only offers PHP 8.1 or older, that is a reason to move. Until then, put the site behind a WAF with the origin locked down, apply what Step 4 allows on your plan, and keep fresh offsite backups. CERT-FR’s advice for unsupported versions is to isolate affected systems and migrate to a maintained version (CERT-FR), and BleepingComputer reports that the UK NCSC told organisations to update or take systems offline until patched (BleepingComputer).
Step 6: How do I know if my site was already attacked?
The flaws allow code execution as the web server user, so look for what an attacker would leave behind:
- New or changed PHP files in upload, cache, images or tmp folders, especially since 20 Oct 2026.
- Unknown administrator or Super User accounts.
- Unusual POST requests, very large multipart uploads, or bursts of 500 errors in the access and error logs around 20 and 21 October.
- Unexpected cron jobs, outbound connections or spam sent from the server.
If you find any of these, patching alone is not enough. Follow our hacked Joomla incident-response guide or our WordPress malware removal service, and rotate database, FTP, admin and API passwords afterwards. For ongoing hardening see the Joomla security guide.
PHP2Shell checklist
| Done? | Task |
|---|---|
| ☐ | Recorded PHP version and Server API for every site |
| ☐ | Every site on 8.2.35, 8.3.36, 8.4.27, 8.5.12 or a vendor-confirmed backport |
| ☐ | PHP-FPM / Apache restarted, no deleted libraries in use |
| ☐ | Sites on 8.1 or older scheduled for a branch change |
| ☐ | Interim settings applied where still unpatched |
| ☐ | Logs and files checked for signs of compromise |
| ☐ | Host ticket answered with a patch date |
The short version
Find the PHP version every site really serves, get it onto 8.2.35, 8.3.36, 8.4.27 or 8.5.12, restart PHP and check again. Use the interim settings only while you wait, and chase your host for a date. If a site is on Joomla 3 or PHP 8.1 and older, the patch you need is a version upgrade, and the sooner it is planned the less any future PHP flaw matters. If you want a second pair of hands, Infyways has worked on Joomla sites since 2010 and replies to enquiries within 12 hours; you can reach us here.
Frequently asked questions
What does PHP2Shell mean for a non-technical site owner?
PHP, the engine that runs Joomla and WordPress, has a fault that lets a stranger run commands on your server without logging in. Ask your host to confirm your site runs PHP 8.2.35, 8.3.36, 8.4.27, 8.5.12 or newer.
Can I patch PHP2Shell on a Joomla 3 site?
Not on a supported setup. Every fixed PHP release is 8.2 or newer, and Joomla 3.10 does not run on PHP 8.2+. Vendor backports and php.ini settings reduce risk only partly, so the lasting fix is upgrading to Joomla 6.2 via 4.4 and 5.x.
What is PHP2Shell?
PHP2Shell is the name for CVE-2026-109618 and CVE-2026-109619, two critical flaws in the PHP runtime rated CVSS v4.0 9.2. They can allow unauthenticated remote code execution on servers that serve web requests with PHP.
Which PHP versions fix PHP2Shell?
PHP 8.2.35, 8.3.36, 8.4.27 and 8.5.12, released on 21 October 2026. PHP 8.1 and older get no official release.
Do I need to update Joomla or WordPress?
No CMS update fixes PHP2Shell, because the flaw is in PHP. Keep the CMS updated anyway, especially if you need to move to a newer PHP branch.
Will a security plugin or extension protect my site?
No. php.net describes a demonstrated exploit that triggers before any application code runs, so CMS security plugins and extensions never see it.
Is PHP 8.1 safe if my host says it is patched?
Only if the host uses a vendor package that backports both fixes, and can name it. The PHP project itself published no fixed 8.1 release.
Which PHP version should a Joomla 6.2 site use?
Joomla 6 requires PHP 8.3 and recommends 8.4. Use 8.4.27 or 8.3.36 or newer.
Which PHP version should WordPress use?
WordPress recommends PHP 8.3 or greater. On 8.3, use 8.3.36 or newer.
Can I set the PHP2Shell mitigations in .user.ini?
No. php.net says not to rely on ini_set() or FPM .user.ini; use php.ini, the FPM pool or server configuration, then restart every worker.
Is Cloudflare enough to protect my site?
No. Cloudflare deployed WAF rules on all plans but still tells customers to patch, and a WAF does nothing for traffic sent straight to your server IP.




























