CVE-2026-47730: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in twigphp Twig
Twig is a template language for PHP. From 3.0.0 until 3.26.0, Twig\Profiler\Dumper\HtmlDumper writes Profile::getTemplate() and Profile::getName() into HTML output without escaping, allowing attacker-controlled template or profile names to inject arbitrary HTML when a browser renders the profiler dump. This issue is fixed in version 3.26.0.
AI Analysis
Technical Summary
Twig is a PHP template engine. Versions >=3.0.0 and <3.26.0 have an XSS vulnerability (CWE-79) in the Twig\Profiler\Dumper\HtmlDumper class. Specifically, the methods Profile::getTemplate() and Profile::getName() output unescaped data into HTML profiler dumps, enabling attacker-controlled template or profile names to inject arbitrary HTML code. This vulnerability is addressed in Twig version 3.26.0.
Potential Impact
An attacker able to control template or profile names can inject arbitrary HTML into profiler output viewed in a browser, potentially leading to cross-site scripting attacks. This could allow execution of malicious scripts in the context of the user viewing the profiler dump. The CVSS 4.0 base score is 5.1 (medium severity), reflecting network attack vector, low complexity, and required user interaction.
Mitigation Recommendations
Upgrade Twig to version 3.26.0 or later, where this vulnerability is fixed. No other official remediation or temporary fixes are indicated. Patch status is confirmed by the vendor advisory stating the issue is fixed in 3.26.0.
CVE-2026-47730: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in twigphp Twig
Description
Twig is a template language for PHP. From 3.0.0 until 3.26.0, Twig\Profiler\Dumper\HtmlDumper writes Profile::getTemplate() and Profile::getName() into HTML output without escaping, allowing attacker-controlled template or profile names to inject arbitrary HTML when a browser renders the profiler dump. This issue is fixed in version 3.26.0.
CVSS v4.0
Score 5.1medium
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
Twig is a PHP template engine. Versions >=3.0.0 and <3.26.0 have an XSS vulnerability (CWE-79) in the Twig\Profiler\Dumper\HtmlDumper class. Specifically, the methods Profile::getTemplate() and Profile::getName() output unescaped data into HTML profiler dumps, enabling attacker-controlled template or profile names to inject arbitrary HTML code. This vulnerability is addressed in Twig version 3.26.0.
Potential Impact
An attacker able to control template or profile names can inject arbitrary HTML into profiler output viewed in a browser, potentially leading to cross-site scripting attacks. This could allow execution of malicious scripts in the context of the user viewing the profiler dump. The CVSS 4.0 base score is 5.1 (medium severity), reflecting network attack vector, low complexity, and required user interaction.
Mitigation Recommendations
Upgrade Twig to version 3.26.0 or later, where this vulnerability is fixed. No other official remediation or temporary fixes are indicated. Patch status is confirmed by the vendor advisory stating the issue is fixed in 3.26.0.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-05-19T21:29:25.483Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a56aea268715ace4342b110
Added to database: 07/14/2026, 21:48:18 UTC
Last enriched: 07/22/2026, 22:28:11 UTC
Last updated: 08/27/2026, 22:52:11 UTC
Views: 65
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.