79% vs 51%: independent neobanks lag on app security. Read the report

Deep Dive

Deep Dive

Joomla File Cache PHP Object Injection RCE (CVE-2026-133347)

Joomla 1.5.0 to 5.4.11 and 6.0.0 to 6.2.1 remove every file-cache guard copy, enabling PHP object injection; fixed in 5.4.12 and 6.2.2.

TL;DR

  • Joomla's file cache reader removed every copy of its protection header, not only the leading one, so crafted cache data can reach unserialize() as altered bytes. Joomla published the advisory on 2026-12-01.
  • The flaw affects 1.5.0 through 5.4.11 and 6.0.0 through 6.2.1 when the File cache handler is used. Joomla 3 and 4 are inside that range and have no fixed release.
  • Joomla rates the impact Critical, and the CVSS v4.0 score is 9.4 with high privileges required. No exploitation is reported, and the CVE is not in CISA KEV (catalog 2026.11.30).
  • Upgrade to 5.4.12 or 6.2.2, then purge the cache. Sites that cannot update can switch away from the File handler. See "How do I fix it?".

Am I affected?

You are exposed when the site runs an affected Joomla release and uses the File cache handler for data an attacker can influence.

All of these conditions must hold:

  • The site runs Joomla 1.5.0 through 5.4.11, or 6.0.0 through 6.2.1.
  • The File cache handler is selected. The installer writes cache_handler = 'file' by default, and the global caching setting starts at 0. The cache is used only when an administrator enables it or a component calls the cache API.
  • An attacker can place the guard sequence <?php die("Access Denied"); ?>#x# in a value that Joomla stores in the file cache.
  • A class usable in an object-injection chain is available to the application. Joomla does not name such a chain in the advisory.

The advisory's affected range reaches back to Joomla 1.5.0, so every branch before 6.0 is covered, including the end-of-life 3.x and 4.x lines. Only 5.4.12 and 6.2.2 carry the fix.

Branch Affected versions Fixed version
Joomla 6.x 6.0.0 through 6.2.1 6.2.2
Joomla 5.x 5.0.0 through 5.4.11 5.4.12
Joomla 4.x 4.0.0 through 4.4.x No fixed release; migrate to 5.4.12 or 6.2.2
Joomla 3.x 3.0.0 through 3.10.x No fixed release; migrate to 5.4.12 or 6.2.2
Joomla 1.5 through 2.5 1.5.0 through 2.5.x No fixed release; migrate to 5.4.12 or 6.2.2

W3Techs reports that Joomla is used by 1.0% of all websites in December 2026. Joomla 3 also carries 49.6% of the Joomla sites W3Techs identifies, so the largest single group is on a branch with no fixed release.

Joomla 3 carries 49.6% of Joomla sites, and the advisory lists no fixed 3.x release
Figure 1: Share of Joomla sites by major version. Source: W3Techs, December 2026

Check the version in the administrator under System, System Information. On the command line, Joomla 4, 5 and 6 print constants from libraries/src/Version.php:

grep -n "MAJOR_VERSION\|MINOR_VERSION\|PATCH_VERSION" libraries/src/Version.php

Joomla 3 uses a different file, and Joomla 1.5 and 2.5 should use the administrator screen:

grep -n "RELEASE\|DEV_LEVEL" libraries/cms/version/version.php

Check the cache configuration in configuration.php:

grep -n "public \$caching\|public \$cache_handler" configuration.php

cache_handler = 'file' means the site uses the vulnerable storage when it caches. A caching value of 0 turns the global cache off, but an extension can still call the cache API.

Check whether the fixed read path is present:

grep -n "str_starts_with(\$data, \$guard)" libraries/src/Cache/Storage/FileStorage.php

A match means the site carries the fix. No match means the read path still removes every guard copy.

How do I fix it?

Upgrade to Joomla 5.4.12 or 6.2.2, which were released on 2026-12-01, then purge the cache.

  1. Back up the site files and the database.
  2. In the administrator, open System, Update, Joomla and install the update. The release notice recommends updating immediately.
  3. When the administrator update is unavailable, download the 5.4.12 or 6.2.2 update package from the release announcement and install it with the Joomla update package.
  4. Purge the cache under System, Clear Cache. This removes entries an attacker may have planted while the old read path was active.
  5. Confirm the version and the fix with the commands in "Am I affected?".

Joomla 5.4 receives security fixes until 2027-10-12, so 5.4.12 is a supported target for sites that are not ready for Joomla 6. Joomla 4 and 3 have no fixed release in this advisory. Sites on those branches must migrate to 5.4.12 or 6.2.2.

Sites that cannot update can change the cache handler. The advisory names this workaround:

  1. Open Global Configuration, System, Cache.
  2. Set Cache Handler to Redis or Memcached, or turn caching off when no extension uses it.
  3. Save the configuration and purge the cache.

The workaround removes the File storage path only. It does not remove a cache file an attacker already placed, and it does not fix an extension that instantiates the File storage directly. It also does not repair a compromised administrator account.

What is the root cause?

The file cache reader removed the guard string from anywhere in the file. A guard inside a serialized value was therefore removed without updating its length prefix, and unserialize() misread the rest of the payload.

The file cache storage writes each entry to a file under the Joomla cache directory. The writer prefixes the serialized data with a PHP statement that stops direct web requests:

// libraries/src/Cache/Storage/FileStorage.php, 6.2.1, line 193
$data = '<?php die("Access Denied"); ?>#x#' . $data;

The guard makes a direct request to a cache file execute die("Access Denied") and print nothing. The reader is supposed to remove that leading prefix and return the original serialized data:

// libraries/src/Cache/Storage/FileStorage.php, 6.2.1, line 135
if ($data !== false) {
    // Remove the initial die() statement
    return str_replace('<?php die("Access Denied"); ?>#x#', '', $data);
}

str_replace() removes every occurrence of the guard in the file, not only the occurrence at the start. A cached value that contains the guard string therefore loses those bytes too.

PHP serialized strings carry an explicit byte count, as in s:64:"...". Removing bytes from inside the string without changing the count desynchronizes the parser. unserialize() reads the declared number of bytes, consumes bytes that belong to the following keys or values, and continues from a shifted position. Bytes that the attacker controls can then be parsed as a new serialized value, including an object.

The page, callback, output and view cache controllers all deserialize the value that the storage returns. The page controller is one example:

// libraries/src/Cache/Controller/PageController.php, 6.2.1, line 100
$data = unserialize(trim($data));

Joomla classifies the flaw as CWE-502, Deserialization of Untrusted Data, and its exploit type as "PHP Object Injection / RCE". The advisory does not name the entry point that puts attacker data into the cache, and it does not name a gadget chain.

How is it exploited?

The attack needs a high-privileged position or another way to influence a cached value, because Joomla's CVSS v4.0 vector sets PR:H. The advisory does not publish a request sequence.

  1. The attacker places a value that contains <?php die("Access Denied"); ?>#x# into data that Joomla caches with the File handler. The advisory does not name the component that accepts this value.
  2. Joomla serializes the data and writes it behind the same guard at the start of the cache file.
  3. On the next read, the vulnerable get() removes the leading guard and also removes the copy inside the serialized string.
  4. The string's declared length still counts the removed bytes, so unserialize() consumes bytes beyond the string.
  5. The attacker arranges the following bytes so that the shifted parser reaches an object token, such as O:, for a class the application can autoload.
  6. unserialize() creates that object. Its magic methods, such as __wakeup() or __destruct(), run during deserialization or at shutdown.
  7. With a usable gadget chain, the object graph performs file operations or code execution in the web server's PHP process.

The advisory calls these "PHP object injection vectors" and rates the impact Critical. It does not publish a proof of concept or a full gadget chain.

How does the attack flow?

A guard string inside a cached value is removed from the middle of the serialized payload. The length prefixes no longer match the data, and a shifted unserialize() can build an attacker-chosen object.

flowchart LR A["High-privileged attacker
influences a cached value"] --> B["Value contains the
cache guard string"] B --> C["get() removes
every guard copy"] C --> D["string length prefixes
no longer match"] D --> E["unserialize() reads
past the string"] E --> F["crafted bytes become
a serialized object"] F --> G["PHP object injection
and code execution"]

What can an attacker do?

A successful object-injection chain runs code in the PHP process that serves the site, which Joomla classes as remote code execution. The advisory does not publish the gadget chain or a proof of concept that demonstrates it.

The conditions are an affected release, the File cache handler, attacker influence over a cached value, and a usable class chain. The CVSS vector requires high privileges, so the flaw is not an unauthenticated path as scored.

Joomla rates the impact Critical, with Moderate severity and Moderate probability in its own table. The CVE record gives CVSS v4.0 9.4, CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H. The difference reflects the high privilege requirement: the impact is full code execution, but the attacker must first reach a position that can write the crafted value into the cache.

No exploitation in the wild is reported. Joomla's advisory does not mention attacks, and the CVE record has no public-exploit marker. The CVE is not in CISA KEV (catalog 2026.11.30, released 2026-11-30).

Why does the fix work?

The patch removes only the leading guard and rejects a cache file that does not start with it. Guard bytes inside a serialized value now survive, so the length prefixes stay correct.

--- a/libraries/src/Cache/Storage/FileStorage.php
+++ b/libraries/src/Cache/Storage/FileStorage.php
@@
                     if ($data !== false) {
-                        // Remove the initial die() statement
-                        return str_replace('<?php die("Access Denied"); ?>#x#', '', $data);
+                        $guard = '<?php die("Access Denied"); ?>#x#';
+
+                        // Only accept files starting with the die() statement and remove only this leading occurrence
+                        if (!str_starts_with($data, $guard)) {
+                            return false;
+                        }
+
+                        return substr($data, \strlen($guard));
                     }

str_starts_with() checks that the file begins with the exact guard, so a file that store() did not write is rejected. substr() removes exactly the prefix and leaves every later byte untouched. A guard inside the serialized value is returned with the data, as the writer stored it.

The 6.2.2 tree adds two unit tests for these properties. testGetKeepsGuardInsideData stores serialize(['first' => GUARD . GUARD, 'second' => 'value']) and asserts that get() returns the same string and that unserialize() returns the same array. testGetRejectsFileWithoutLeadingGuard overwrites a cache file with 'value' . GUARD and asserts that get() returns false.

The fix is complete for the read path. The guard string appears in one read path in the 6.2.2 tree, and 5.4.12 carries the same change. The patch does not scan existing cache files, so purge the cache after the upgrade.

How do I check if I was compromised?

No indicators of compromise are published, and a failed attempt may leave no trace. The cache file format is the durable check: store() always writes the guard as the first bytes of a cache file.

grep -rL --exclude=index.html -F '<?php die("Access Denied"); ?>#x#' cache/

Each file that grep prints is a cache file that does not contain the guard. Treat it as tampered and review its contents and creation time. An attacker who includes the guard will not be caught by this check, and the check does not prove that an attempt succeeded.

If the Action Logs plugin is enabled, review administrator actions around the cache directory changes:

SELECT log_date, extension, message_language_key, user_id, ip_address
FROM #__action_logs
WHERE extension IN ('com_installer', 'com_templates', 'com_config')
ORDER BY log_date DESC;

A cache purge, extension install or template change by an unexpected account is a lead, not proof. Compare it with the site's change record and the account's normal activity.

Timeline

  • 2026-11-19: Joomla reserves the CVE ID.
  • 2026-11-25: The issue is reported to Joomla, according to the advisory.
  • 2026-12-01 16:00 UTC: Joomla publishes 5.4.12 and 6.2.2.
  • 2026-12-01 16:24 UTC: The CVE record is published.
  • No public proof of concept or in-the-wild exploitation is reported.

FAQ

Does 5.4.12 fix the flaw?

Yes. Joomla lists 5.4.12 and 6.2.2 as the fixed releases, and both contain the leading-guard change. A site on 5.4.11 or 6.2.1 from the November security release still needs this update.

Is Joomla 3 or 4 fixed?

No. The advisory's affected range includes 1.5.0 through 5.4.11, which covers Joomla 3 and 4, and the solution names only 5.4.12 and 6.2.2. Sites on 3.x or 4.x must migrate or use the non-File cache handler.

Can an unauthenticated attacker exploit it?

Joomla's CVSS v4.0 vector requires high privileges, so the flaw is not scored as an unauthenticated path. The advisory does not describe the entry point that puts attacker data into the cache.

Is there a public proof of concept?

No. Joomla published the root-cause description and the fix, but no proof of concept or gadget chain is linked in the advisory or the CVE record.

Which cache handler should I use?

Redis or Memcached removes the File storage path. Turning caching off also removes it when no component uses the cache. Both choices need the matching PHP extension and, for Redis or Memcached, a running server.

What if I cannot update a Joomla 3 site?

Switch the cache handler away from File and limit administrator accounts to people who need them. The workaround does not fix the read path, and the branch has no vendor fix, so plan the migration to 5.4.12 or 6.2.2.

References

  • Joomla Security Centre, [20261201] Core, PHP object injection through file cache guard handling, https://developer.joomla.org/security-centre/1158-20261201-core-php-object-injection-through-file-cache-guard-handling.html (checked December 1, 2026)
  • CVE-2026-133347 record, https://www.cve.org/CVERecord?id=CVE-2026-133347 (published 2026-12-01, checked December 1, 2026)
  • Joomla 6.2.2 and 5.4.12 security release announcement, https://www.joomla.org/announcements/release-news/joomla-6-2-2-5-4-12-security-release.html (published 2026-12-01, checked December 1, 2026)
  • Joomla 6.2.2 release, https://github.com/joomla/joomla-cms/releases/tag/6.2.2 (published 2026-12-01, checked December 1, 2026)
  • Joomla 5.4.12 release, https://github.com/joomla/joomla-cms/releases/tag/5.4.12 (published 2026-12-01, checked December 1, 2026)
  • FileStorage source at 6.2.1, https://github.com/joomla/joomla-cms/blob/6.2.1/libraries/src/Cache/Storage/FileStorage.php (checked December 1, 2026)
  • FileStorage source at 6.2.2, https://github.com/joomla/joomla-cms/blob/6.2.2/libraries/src/Cache/Storage/FileStorage.php (checked December 1, 2026)
  • FileStorage source at 5.4.12, https://github.com/joomla/joomla-cms/blob/5.4.12/libraries/src/Cache/Storage/FileStorage.php (checked December 1, 2026)
  • FileStorage unit tests at 6.2.2, https://github.com/joomla/joomla-cms/blob/6.2.2/tests/Unit/Libraries/Cms/Cache/Storage/FileStorageTest.php (checked December 1, 2026)
  • PageController source at 6.2.1, https://github.com/joomla/joomla-cms/blob/6.2.1/libraries/src/Cache/Controller/PageController.php (checked December 1, 2026)
  • Joomla installer cache defaults at 6.2.1, https://github.com/joomla/joomla-cms/blob/6.2.1/installation/src/Model/ConfigurationModel.php (checked December 1, 2026)
  • W3Techs, Joomla usage statistics, https://w3techs.com/technologies/details/cm-joomla (December 2026, checked December 1, 2026)
  • CISA Known Exploited Vulnerabilities catalog, https://www.cisa.gov/known-exploited-vulnerabilities-catalog (catalog 2026.11.30, checked December 1, 2026)

Free scan

Scan your own app for free

or book a demo

Keep reading

Related articles

Browse the blog