Improper Control of Generation of Code in Twig rendered views in shopware
Key facts
- Attack vector
- Network
- Privileges required
- Low
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Code execution
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-94.
Summary
Shopware is an open source commerce platform based on Symfony Framework and Vue js. In a Twig environment **without the Sandbox extension**, it is possible to refer to PHP functions in twig filters like `map`, `filter`, `sort`. This allows a template to call any global PHP function and thus execute arbitrary code. The attacker must have access to a Twig environment in order to exploit this vulnerability. This problem has been fixed with 6.4.18.1 with an override of the specified filters until the integration of the Sandbox extension has been finished. Users are advised to upgrade. Users of major versions 6.1, 6.2, and 6.3 may also receive this fix via a plugin.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Total
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| shopware | platform | before 6.4.18.1 | 6.4.18.1 | Patch available | CNA |
| — | shopware/platform (Packagist) | before 6.4.18.1 | 6.4.18.1 | Patch available | GHSA-93cw-f5jj-x85w |
| — | shopware/core (Packagist) | before 6.4.18.1 | 6.4.18.1 | Patch available | GHSA-93cw-f5jj-x85w |
- platform Vendorshopware Affected before 6.4.18.1 Fixed in 6.4.18.1 Patch available CNA
- shopware/platform (Packagist) Vendor— Affected before 6.4.18.1 Fixed in 6.4.18.1 Patch available GHSA-93cw-f5jj-x85w
- shopware/core (Packagist) Vendor— Affected before 6.4.18.1 Fixed in 6.4.18.1 Patch available GHSA-93cw-f5jj-x85w
Remediation
- Fix · CNA platform (shopware) Fixed in 6.4.18.1
- Fix · GHSA-93cw-f5jj-x85w shopware/platform (Packagist) Fixed in 6.4.18.1 Advisory →
- Fix · GHSA-93cw-f5jj-x85w shopware/core (Packagist) Fixed in 6.4.18.1 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2023-22731
- 2026-10-03 Alias added: GHSA-93cw-f5jj-x85w
References
Patch 2
Advisory 2
More Shopware vulnerabilities
- TI-2023-01895 Improper Control of Generation of Code in Twig Rendered Views in Shopware CVSS 3.1HIGH 8.8
- TI-2025-20623 Shopware prior to version 6.5.8.13 is affected by a SQL injection vulnerability in the… CVSS 3.1MEDIUM 6.8
- TI-2024-28343 Shopware vulnerable to Server Side Template Injection in Twig using Context functions CVSS 3.1HIGH 8.3
- TI-2019-09582 In createInstanceFromNamedArguments in Shopware through 5.6.x, a crafted web request can… CVSS 3.1HIGH 8.8
- TI-2016-02607 The backend/Login/load/ script in Shopware before 5.1.5 allows remote attackers to execute arbitrary code. CVSS 3.0CRITICAL 9.8
- TI-2025-32365 A stored cross-site scripting (XSS) vulnerability exists in the Shopware 6 installation… CVSS 3.1MEDIUM 6.1
Sources
- CVE-2023-22731 · CVE Program
- CVE-2023-22731 · NVD
- FIRST EPSS
- GHSA-93cw-f5jj-x85w · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences