Template Injection Affecting craftcms/cms package, versions >=4.0.0-RC1, <4.17.0-beta.1>=5.0.0-RC1, <5.9.0-beta.1


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.05% (17th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-PHP-CRAFTCMSCMS-15440546
  • published10 Mar 2026
  • disclosed3 Mar 2026
  • creditRaj Chowdhury, rlarabee

Introduced: 3 Mar 2026

NewCVE-2026-28784  (opens in a new tab)
CWE-1336  (opens in a new tab)

How to fix?

Upgrade craftcms/cms to version 4.17.0-beta.1, 5.9.0-beta.1 or higher.

Overview

craftcms/cms is a content management system.

Affected versions of this package are vulnerable to Template Injection via the map filter in Twig templates when processing text fields that accept Twig input in the control panel settings or through the System Messages utility. An attacker can execute arbitrary code by crafting a malicious payload if they have administrator access with allowAdminChanges enabled, or if they have access to the System Messages utility.

CVSS Base Scores

version 4.0
version 3.1