Vulnerability in craftcms/cms (CVE-2026-72779)
Summary
Vulnerability in craftcms/cms (CVE-2026-72779). Confidential information can be exposed externally. Exploitable via SplFileObject. Mitigation: upgrade to 4.18.2 or later.
Original description
The description as published by the source.
The create() Twig function (introduced in 5.9.0) allows instantiation of arbitrary PHP classes from template code, restricted only by a 5-entry blocklist. SplFileObject is not in the blocklist, enabling arbitrary file read, including .env (security key, DB credentials) and the passwd file from non-sandboxed Twig template contexts, such as entry type title formats and URI formats.
The sandbox correctly blocks create() in system email templates, so this finding applies only to admin-configured, non-sandboxed contexts that require allowAdminChanges=true.
Prerequisites
- Admin access to the Craft control panel
allowAdminChangesmust betrue(default in dev/staging, recommendedfalsein production)- Admin must be able to edit entry type settings (title format, URI format)
- Any user who subsequently creates an entry in the affected section triggers the file read
Limitations
- Requires admin-level access: not exploitable by low-privilege users
allowAdminChangesmust betrue: production best practices recommendfalse, which prevents entry type configuration changes- Per Craft’s own severity guidelines, findings requiring
allowAdminChanges=trueare rated low - The
create()function is blocked by the Twig sandbox, so this cannot be exploited via system email templates or any other sandboxed context
Impact
An admin user (or an attacker who has compromised an admin account) can read arbitrary files from the server filesystem by setting a…
Source: NIST National Vulnerability Database NVD GitHub Advisory
Auto-generated summary
Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.
A vulnerability tracked as CVE-2026-72779 has been found in craftcms/cms.
Attackers can target a specific entry point like SplFileObject over the network to misuse the product.
Confidential information can be exposed externally. CVSS score: 4.5/10.
What to do: upgrade craftcms/cms to 4.18.2 or later.
If unsure, ask your IT team or search "craftcms/cms CVE-2026-72779" on the vendor's site.
CVE-2026-72779 (craftcms/cms) — CWE-184 / CVSS v3 4.5
Attack vector: remote (network-reachable)
Attack surface: SplFileObject / allowAdminChanges / true / false
Patched: 4.18.2 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
A vulnerability (CWE-184) exists in craftcms/cms. Attackers reach the vulnerable code path via SplFileObject.
Check the vendor advisory for the affected versions of craftcms/cms. Attack surface: SplFileObject / allowAdminChanges / true / false.
Severity: Medium (CVSS 4.5/10). Confidential information can be exposed externally.
Update to 4.18.2.
Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'craftcms/cms' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1Identify exposure identify
grep -r 'craftcms/cms' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
craftcms/cmsを grep し、稼働しているサービス・バージョンを把握する。 -
2Apply patch patch
Upgrade craftcms/cms to 4.18.2ステージング環境で 4.18.2 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
3Post-deployment verification verify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
References
- advisory nvd.nist.gov
- package github.com
- web github.com
- web vulncheck.com
- web github.com
- web github.com
- web github.com
- web github.com
- web github.com
- web github.com