{
  "affected": [
    {
      "ranges": [
        {
          "database_specific": {
            "versions": [
              {
                "introduced": "5.0.0-RC1"
              },
              {
                "fixed": "5.9.0-beta.1"
              }
            ]
          },
          "events": [
            {
              "introduced": "04755d93f86d07cc183db47db8a0eee106892e30"
            },
            {
              "fixed": "0ad14c3c7e590461b52aeb44859659e2e231e04d"
            }
          ],
          "repo": "https://github.com/craftcms/cms",
          "type": "GIT"
        },
        {
          "database_specific": {
            "versions": [
              {
                "introduced": "4.0.0-RC1"
              },
              {
                "fixed": "4.17.0-beta.1"
              }
            ]
          },
          "events": [
            {
              "introduced": "daac7c1da2f701f2e9ddee1da1457ce61660b581"
            },
            {
              "fixed": "42cef196d68dd8d48ceaab89b2c9e2edd2cecbe8"
            }
          ],
          "repo": "https://github.com/craftcms/cms",
          "type": "GIT"
        }
      ]
    }
  ],
  "aliases": [
    "GHSA-v47q-jxvr-p68x"
  ],
  "database_specific": {
    "cna_assigner": "GitHub_M",
    "cwe_ids": [
      "CWE-1336"
    ],
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/28xxx/CVE-2026-28697.json"
  },
  "details": "Craft is a content management system (CMS). Prior to 4.17.0-beta.1 and 5.9.0-beta.1, an authenticated administrator can achieve Remote Code Execution (RCE) by injecting a Server-Side Template Injection (SSTI) payload into Twig template fields (e.g., Email Templates). By calling the craft.app.fs.write() method, an attacker can write a malicious PHP script to a web-accessible directory and subsequently access it via the browser to execute arbitrary system commands. This vulnerability is fixed in 4.17.0-beta.1 and 5.9.0-beta.1.",
  "id": "CVE-2026-28697",
  "modified": "2026-04-01T23:09:32.758127389Z",
  "published": "2026-03-04T16:26:37.476Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/28xxx/CVE-2026-28697.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/craftcms/cms/security/advisories/GHSA-v47q-jxvr-p68x"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-28697"
    },
    {
      "type": "FIX",
      "url": "https://github.com/craftcms/cms/commit/9dc2a4a3ec8e9cd5e8c0d1129f36371437519197"
    },
    {
      "type": "FIX",
      "url": "https://github.com/craftcms/cms/pull/18216"
    },
    {
      "type": "FIX",
      "url": "https://github.com/craftcms/cms/pull/18219"
    }
  ],
  "schema_version": "1.7.3",
  "severity": [
    {
      "score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H",
      "type": "CVSS_V4"
    }
  ],
  "summary": "Craft Affected by Authenticated RCE via \"craft.app.fs.write()\" in Twig Templates"
}