CVE-2025-57811
JSON

6.1medium

Craft Potential Remote Code Execution via Twig SSTI

Severity
6.1medium CVSS:4.0 by GitHub_M
Exploit likelihood
1.09% (higher than 66% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-crcq-738g-pqvc

Description

Craft is a platform for creating digital experiences. From versions 4.0.0-RC1 to 4.16.5 and 5.0.0-RC1 to 5.8.6, there is a potential remote code execution vulnerability via Twig SSTI (Server-Side Template Injection). This is a follow-up to CVE-2024-52293. This vulnerability has been patched in versions 4.16.6 and 5.8.7.

Affected

Product or packageVersionsReported by
craftcms cms>= 4.0.0-RC1, < 4.16.6, >= 5.0.0-RC1, < 5.8.7CVE List
craftcms/cms (Packagist)from 4.0.0-RC1 before 4.16.6, from 5.0.0-RC1 before 5.8.7GitHub Advisory Database
craftcms craft_cmsfrom 4.1.0 before 4.16.6, from 5.1.0 before 5.8.7, 4.0.0, 5.0.0NVD

All scores

GitHub_M6.1medium CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U
GitHubmedium CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:P/PR:H/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:P
NVD7.2high CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H

Classification

CWE-22CWE-94CWE-1336

SSVC (CISA-ADP): exploitation none, automatable no, technical impact total.

What each source says

CVE List

Craft is a platform for creating digital experiences. From versions 4.0.0-RC1 to 4.16.5 and 5.0.0-RC1 to 5.8.6, there is a potential remote code execution vulnerability via Twig SSTI (Server-Side Template Injection). This is a follow-up to CVE-2024-52293. This vulnerability has been patched in versions 4.16.6 and 5.8.7.

GitHub Advisory Database

Note that users must have administrator access to the Craft Control Panel, and allowAdminChanges must be enabled for this to work, which is against Craft CMS' recommendations for any non-dev environment.

https://craftcms.com/knowledge-base/securing-craft#set-allowAdminChanges-to-false-in-production

Note: This is a follow-up to GHSA-f3cw-hg6r-chfv

Users should update to the patched versions (4.16.6 and 5.8.7) to mitigate the issue.

Resources: https://github.com/craftcms/cms/pull/17612

NVD (es)

Craft es una plataforma para crear experiencias digitales. De las versiones 4.0.0-RC1 a 4.16.5 y de 5.0.0-RC1 a 5.8.6, existe una posible vulnerabilidad de ejecución remota de código mediante Twig SSTI (inyección de plantilla del lado del servidor). Esta vulnerabilidad es posterior a CVE-2024-52293. Esta vulnerabilidad se ha corregido en las versiones 4.16.6 y 5.8.7.

References

Sources

SourceRecordLicence
CVE ListCVE-2025-57811 changed 2025-08-25CVE Terms of Use
GitHub Advisory DatabaseGHSA-crcq-738g-pqvc changed 2025-11-27CC-BY-4.0
NVDCVE-2025-57811 changed 2026-06-17Public domain