Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-47730: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in twigphp Twig

0
Medium
VulnerabilityCVE-2026-47730cvecve-2026-47730cwe-79
Published: 07/14/2026 (07/14/2026, 21:21:10 UTC)
Source: CVE Database V5
Vendor/Project: twigphp
Product: Twig

Description

Twig versions from 3.0.0 up to but not including 3.26.0 contain a cross-site scripting (XSS) vulnerability in the HtmlDumper component of the profiler. This occurs because Profile::getTemplate() and Profile::getName() are written into HTML output without proper escaping, allowing attacker-controlled template or profile names to inject arbitrary HTML when rendered in a browser. The issue is fixed starting in version 3.26.0.

CVSS v4.0

Score 5.1medium

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
Passive
Vuln. Confidentiality
None
Vuln. Integrity
None
Vuln. Availability
None
Subsq. Confidentiality
Low
Subsq. Integrity
Low
Subsq. Availability
None
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N

Affected software

Packagistmore threats →ai
twig/twig
pkg:composer/twig/twig
Affected versions
>=3.0.0 <3.26.0

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 07/14/2026, 22:23:57 UTC

Technical Analysis

The vulnerability in twigphp Twig affects versions 3.0.0 through 3.25.x where the HtmlDumper class in the profiler writes unescaped template and profile names into HTML output. This improper neutralization of input (CWE-79) enables cross-site scripting attacks if an attacker can control template or profile names. The flaw is resolved in version 3.26.0 by properly escaping these values before output.

Potential Impact

An attacker who can influence template or profile names may inject arbitrary HTML or script code into the profiler's HTML output. This could lead to cross-site scripting attacks when the profiler dump is viewed in a browser, potentially compromising user interaction with the profiler interface. The CVSS 4.0 base score is 5.1 (medium severity), reflecting network attack vector, low complexity, no privileges required, and user interaction needed.

Mitigation Recommendations

Upgrade Twig to version 3.26.0 or later, where this vulnerability is fixed by escaping the relevant output. No other official remediation or temporary fixes are documented. Patch status is confirmed fixed in 3.26.0.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

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/14/2026, 22:23:57 UTC

Last updated: 07/14/2026, 22:27:29 UTC

Views: 2

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

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

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses