Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-28695: CWE-1336: Improper Neutralization of Special Elements Used in a Template Engine in craftcms cms

0
High
VulnerabilityCVE-2026-28695cvecve-2026-28695cwe-1336
Published: Wed Mar 04 2026 (03/04/2026, 16:15:32 UTC)
Source: CVE Database V5
Vendor/Project: craftcms
Product: cms

Description

Craft is a content management system (CMS). There is an authenticated admin RCE in Craft CMS 5.8.21 via Server-Side Template Injection using the create() Twig function combined with a Symfony Process gadget chain. The create() Twig function exposes Craft::createObject(), which allows instantiation of arbitrary PHP classes with constructor arguments. Combined with the bundled symfony/process dependency, this enables RCE. This bypasses the fix implemented for CVE-2025-57811 (patched in 5.8.7). This vulnerability is fixed in 5.9.0-beta.1 and 4.17.0-beta.1.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 03/11/2026, 19:38:30 UTC

Technical Analysis

CVE-2026-28695 is a critical vulnerability affecting Craft CMS, a popular content management system. The flaw is an authenticated server-side template injection (SSTI) that enables remote code execution (RCE) through the Twig template engine's create() function. This function exposes Craft::createObject(), which allows the instantiation of arbitrary PHP classes with constructor arguments. By exploiting this, an attacker with administrative privileges can instantiate classes from the symfony/process library bundled with Craft CMS to execute arbitrary system commands on the server. This vulnerability effectively bypasses the previous patch applied for CVE-2025-57811, indicating a regression or incomplete fix. The affected versions include Craft CMS 5.8.7 up to but not including 5.9.0-beta.1, and 4.0.0-RC1 up to but not including 4.17.0-beta.1. The vulnerability requires high privileges (admin authentication) but no additional user interaction, and it has a CVSS 4.0 base score of 7.5, reflecting its high severity. No known exploits are currently reported in the wild. The issue is categorized under CWE-1336, which involves improper neutralization of special elements used in a template engine, leading to injection attacks. The fix is available starting with Craft CMS 5.9.0-beta.1 and 4.17.0-beta.1.

Potential Impact

The impact of this vulnerability is significant for organizations using affected versions of Craft CMS. An authenticated attacker with admin privileges can execute arbitrary code on the web server, potentially leading to full system compromise. This could result in unauthorized data access, data modification, service disruption, or use of the compromised server as a pivot point for further attacks within the network. Since Craft CMS is used to manage website content, exploitation could also lead to defacement, data leakage, or insertion of malicious content affecting end users. The requirement for admin authentication limits the attack surface but does not eliminate risk, especially in environments where admin credentials may be compromised or weakly protected. The bypass of a previous fix suggests that organizations relying on earlier patches remain vulnerable until they upgrade to the fixed versions. The absence of known exploits in the wild currently reduces immediate risk but does not preclude future exploitation, especially as details become public.

Mitigation Recommendations

Organizations should immediately upgrade Craft CMS to versions 5.9.0-beta.1 or later, or 4.17.0-beta.1 or later, where the vulnerability is patched. Until upgrades can be applied, restrict admin access to trusted personnel and enforce strong authentication mechanisms such as multi-factor authentication (MFA) to reduce the risk of credential compromise. Review and monitor admin account activity for suspicious behavior. Disable or restrict access to the Twig create() function or Craft::createObject() if possible through configuration or custom code hardening. Employ web application firewalls (WAFs) with rules designed to detect and block unusual template engine usage or command injection patterns. Conduct thorough code and configuration audits to ensure no other template injection vectors exist. Regularly back up CMS data and system configurations to enable recovery in case of compromise. Finally, maintain vigilant monitoring of security advisories for any emerging exploits or related vulnerabilities.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-03-02T21:43:19.928Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 69a85ed1d1a09e29cb4aedf1

Added to database: 3/4/2026, 4:33:21 PM

Last enriched: 3/11/2026, 7:38:30 PM

Last updated: 4/18/2026, 10:15:00 AM

Views: 126

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses