Summary
EasyAdminBundle has path traversal and reflected XSS in Flag and Icon Twig components
EasyAdminBundle ships two public Twig components, <twig:ea:Flag countryCode="..."> and <twig:ea:Icon name="...">, that load SVG files from disk using a path built directly from a public component property, and then render the resulting markup with the Twig |raw filter.
When an application binds either of those properties to data that is influenced by an end user, the lack of validation on the property value leads to two distinct issues:
- Arbitrary
.svgfile disclosure (both components), the property value is concatenated into a filesystem path without normalizing or constraining it, so..segments are preserved and resolved by PHP. Any file on the server whose absolute path ends in.svg(for example, user-uploaded SVG icons stored elsewhere on the host) can be read and embedded into the rendered page. - Reflected XSS in the admin UI (Flag component only), when the requested flag file does not exist, the Flag component falls back to a hard-coded SVG string that interpolates the raw
countryCodevalue twice, and the parent template renders that string with|raw. An attacker who controlscountryCodecan therefore inject arbitrary HTML/JavaScript that will execute inside the authenticated admin context that rendered the component.
The first-party usage shipped by EasyAdminBundle itself is not affected: the bundle only passes ISO 3166 alpha-2 codes validated through Symfony\Component\Intl\Countries to the Flag component, and only hard-coded internal:.. names or values previously set in PHP via MenuItem::setIcon() to the Icon component. The vulnerability is reachable only in third-party templates that pass attacker-controlled data into these properties.
Affected components
EasyCorp\Bundle\EasyAdminBundle\Twig\Component\Flag, public Twig tag<twig:ea:Flag>, propertycountryCode.EasyCorp\Bundle\EasyAdminBundle\Twig\Component\Icon, public Twig tag<twig:ea:Icon>, propertynamewhen the value starts with theinternal:prefix.
Credit
EasyAdmin would like to thank Claude Mythos Preview (via Project Glasswing and The PHP Foundation) for reporting the issue and providing the fix.
Impact
Path traversal is information disclosure bounded by the .svg extension; reflected XSS in Flag runs in the admin context and is therefore more sensitive but requires a vulnerable template wiring and user interaction.
Input manipulates file paths to reach files outside the intended directory, such as configuration or credential files. Typical impact: unauthorized file read or write outside the intended directory.
GHSA-2WWR-9X6F-88GP has a CVSS score of 5.3 (Medium). The vector is network-reachable, no privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (4.29.10, 5.0.10); upgrading removes the vulnerable code path.
Affected versions
Security releases
Kodem intelligence
Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.
Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.
Already deployed Kodem?
See it in your environmentNew to Kodem? Get a demo →Remediation advice
easycorp/easyadmin-bundle to 4.29.10 or later; easycorp/easyadmin-bundle to 5.0.10 or later
Kodem Kai can prioritize this vulnerability in your dependency tree and generate a fix recommendation.
Frequently Asked Questions
- What is GHSA-2WWR-9X6F-88GP? GHSA-2WWR-9X6F-88GP is a medium-severity path traversal vulnerability in easycorp/easyadmin-bundle (composer), affecting versions >= 4.0.0, < 4.29.10. It is fixed in 4.29.10, 5.0.10. Input manipulates file paths to reach files outside the intended directory, such as configuration or credential files.
- How severe is GHSA-2WWR-9X6F-88GP? GHSA-2WWR-9X6F-88GP has a CVSS score of 5.3 (Medium). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
- Which versions of easycorp/easyadmin-bundle are affected by GHSA-2WWR-9X6F-88GP? easycorp/easyadmin-bundle (composer) versions >= 4.0.0, < 4.29.10 is affected.
- Is there a fix for GHSA-2WWR-9X6F-88GP? Yes. GHSA-2WWR-9X6F-88GP is fixed in 4.29.10, 5.0.10. Upgrade to this version or later.
- Is GHSA-2WWR-9X6F-88GP exploitable, and should I be worried? Whether GHSA-2WWR-9X6F-88GP is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
- What actually determines whether GHSA-2WWR-9X6F-88GP is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
- How do I fix GHSA-2WWR-9X6F-88GP?
- Upgrade
easycorp/easyadmin-bundleto 4.29.10 or later - Upgrade
easycorp/easyadmin-bundleto 5.0.10 or later
- Upgrade