CVE-2026-109304

Craft CMS 4.0.0 before 4.18.7 and 5.0.0 before 5.10.14 Arbitrary File Read via Twig create() DOMDocument

Published Oct 12, 2026 CVSS 4.0 · 6.9 Medium EPSS < 1% KEV · Not listed
Description
Craft CMS 4.0.0 before 4.18.7 and 5.0.0 before 5.10.14 contains an arbitrary file read vulnerability because the Twig create() class blocklist does not cover DOMDocument. Attackers able to set an entry-type title format, including via project-config/apply, can use create('DOMDocument').loadHTMLFile() with textContent to expose local file contents to non-admin users who can view entries.

Analysis

AI-generated

Technical impact

Craft CMS 4.x and 5.x versions prior to 4.18.7 and 5.10.14 contain a flaw in the Twig create() blocklist: DOMDocument is not prohibited. An attacker who can configure an entry‑type title format, for instance through project‑config/apply, can invoke create('DOMDocument').loadHTMLFile() and then read the file content via textContent. This allows a non‑administrator who is authorized to view entries to retrieve any local file that the web process can access, exposing sensitive configuration, code, or system data. The weakness is identified as an Information Disclosure (CWE‑200).

Affected Systems

The vulnerability applies to Craft CMS versions 4.0.0 up to 4.18.6 inclusive and 5.0.0 up to 5.10.13 inclusive. The affected product is Craft CMS from the vendor CraftCMS.

Risk and Exploitability

The CVSS score of 6.9 indicates a moderate severity. The threat relies on attackers being able to manipulate the entry‑type title format that the application allows. By using Twig's create('DOMDocument').loadHTMLFile() with textContent, a non‑administrator user who has permission to view entries can read arbitrary files that the web process can access. Because this exploit is achievable through the public‑facing interface used to define entry formats, the likelihood of exploitation in a reachable environment is non‑negligible. The vulnerability is listed as Information Disclosure (CWE‑200) and is not currently in the CISA KEV catalog.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade Craft CMS to version 4.18.7 or later, or to 5.10.14 or later, where the Twig create() blocklist has been updated to exclude DOMDocument.
  • If an upgrade is not immediately possible, limit the ability of non‑administrator users to modify entry‑type title formats or disable custom title format configuration entirely to remove the attacker’s ability to craft the vulnerable input.
  • As an interim mitigation, avoid using DOMDocument via Twig create() in templates; replace loadHTMLFile calls with safer file‑reading approaches or remove the DOMDocument class from the Twig environment if possible.

Generated by OpenCVE AI on October 12, 2026 at 20:11 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Craftcms cms
Vendors & Products Craftcms cms
Type Values Removed Values Added
Description Craft CMS 4.0.0 before 4.18.7 and 5.0.0 before 5.10.14 contains an arbitrary file read vulnerability because the Twig create() class blocklist does not cover DOMDocument. Attackers able to set an entry-type title format, including via project-config/apply, can use create('DOMDocument').loadHTMLFile() with textContent to expose local file contents to non-admin users who can view entries.
Title Craft CMS 4.0.0 before 4.18.7 and 5.0.0 before 5.10.14 Arbitrary File Read via Twig create() DOMDocument
First Time appeared Craftcms
Craftcms craft Cms
Weaknesses CWE-200
CPEs cpe:2.3:a:craftcms:craft_cms:*:*:*:*:*:*:*:*
Vendors & Products Craftcms
Craftcms craft Cms
References
Metrics cvssV3_1

{'score': 4.9, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N'}

cvssV4_0

{'score': 6.9, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-200

    Exposure of Sensitive Information to an Unauthorized Actor

Sources

Status
PUBLISHED
Assigner
VulnCheck
Published
Updated
Oct 13, 2026, 4:55 PM
Reserved
Oct 12, 2026, 2:13 PM
Status
Awaiting Analysis
Published
Oct 12, 2026, 5:17 PM
Modified
Oct 16, 2026, 5:25 PM