---
id: CVE-2026-112777
title: >-
  Craft CMS before 4.18.8 and 5.11.0 Twig create() Blocklist Bypass Leading to
  RCE
summary: >-
  Craft CMS 4.x before 4.18.8 and 5.x before 5.11.0 contains a blocklist bypass
  in the Twig create() function because its class-name checks are case-sensitive
  while PHP class resolution is not. Attackers with template-execution rights,
  suc…
severity: high
cvss: 7.2
cvssVector: 'CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H'
cvssSource: cna
cwe:
  - CWE-184
vendor: craftcms
product: cms
affected:
  - cms >= 4.0.0 < 4.18.8
  - cms >= 5.0.0 < 5.11.0
published: '2026-10-19'
updated: '2026-10-19'
sourceUpdated: '2026-10-19T19:10:54.567Z'
source: CVEORG
sourceUrl: 'https://www.cve.org/CVERecord?id=CVE-2026-112777'
references:
  - url: 'https://github.com/craftcms/cms/security/advisories/GHSA-w643-x88w-6wcm'
    label: GitHub Security Advisory (GHSA-w643-x88w-6wcm)
  - url: >-
      https://www.vulncheck.com/advisories/craft-cms-before-4.18.8-and-5.11.0-twig-create-blocklist-bypass-leading-to-rce
    label: >-
      VulnCheck Advisory: Craft CMS before 4.18.8 and 5.11.0 Twig create()
      Blocklist Bypass Leading to RCE
tags:
  - cve.org
ingestedAt: '2026-10-19T19:38:06.463Z'
---

## Overview

Craft CMS 4.x before 4.18.8 and 5.x before 5.11.0 contains a blocklist bypass in the Twig create() function because its class-name checks are case-sensitive while PHP class resolution is not. Attackers with template-execution rights, such as Control Panel administrators, can instantiate SplFileObject via a lowercase class name to read .env secrets or write a PHP file into the webroot for remote code execution.

## Affected

- `cms >= 4.0.0 < 4.18.8`
- `cms >= 5.0.0 < 5.11.0`

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.
