{"id":"CVE-2026-55878","aliases":["CVE-2026-55878","GHSA-p9xj-fpr2-jf2q"],"related":[],"kind":"vulnerability","state":"published","title":"Symfony: Path Traversal in symfony/ux-toolkit Allows Arbitrary File Write and Read via Crafted Recipe Manifest","summary":"Symfony UX is a JavaScript ecosystem for Symfony. From 2.32.0 before 2.36.1 and from 3.0.0 before 3.2.0, the ux:install console command installs files from a recipe kit by copying paths listed in a copy-files map, and because Path::isRelative() accepts paths like ../../../etc, a crafted or compromised kit can write attacker-controlled content to arbitrary locations or read local files outside the recipe directory. This issue is fixed in versions 2.36.1 and 3.2.0.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Symfony UX is a JavaScript ecosystem for Symfony. From 2.32.0 before 2.36.1 and from 3.0.0 before 3.2.0, the ux:install console command installs files from a recipe kit by copying paths listed in a copy-files map, and because Path::isRelative() accepts paths like ../../../etc, a crafted or compromised kit can write attacker-controlled content to arbitrary locations or read local files outside the recipe directory. This issue is fixed in versions 2.36.1 and 3.2.0.","source":"cvelist"},{"lang":"en","text":"### Description\nThe `ux:install` console command installs files from a recipe kit by copying paths listed in a `copy-files` map. The only guard against malicious paths was `Path::isRelative()`, which returns `true` for paths like `../../../etc`. `Path::join()` then resolves the `..` segments without complaint, so the final path can escape the intended directory entirely. A crafted or compromised kit can therefore write attacker-controlled content   to arbitrary locations on the developer's machine or CI runner.\n\nBecause the copy operation creates missing parent directories and can overwrite existing files silently (with   `--force` or in non-interactive environments), an attacker who controls a kit can overwrite files such as controllers, git hooks, or `.env` to achieve code execution. The source side of `copy-files` is symmetrically   affected, enabling local file reads outside the recipe directory.\n\n### Resolution\n\nThe fix introduces an `Assert::pathDoesNotEscapeDirectory()` helper that rejects any `copy-files` source or destination path containing a `..` segment, regardless of whether `/` or `\\` is used as the separator. This check is enforced in both `RecipeManifest` (which also guards the source Finder) and `File`. As a last line of defense, the installer re-verifies the fully resolved paths with `Path::isBasePath()` immediately before each filesystem read and write.\n\n### Credits\n\nSymfony would like to thank Pascal Cescon for reporting the issue and Hugo Alliaume for providing the fix.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Symfony UX es un ecosistema JavaScript para Symfony. Desde 2.32.0 antes de 2.36.1 y desde 3.0.0 antes de 3.2.0, el comando de consola ux:install instala archivos de un kit de receta copiando rutas listadas en un mapa de ’copy-files’, y debido a que Path::isRelative() acepta rutas como .. / .. / .. / etc, un kit manipulado o comprometido puede escribir contenido controlado por el atacante en ubicaciones arbitrarias o leer archivos locales fuera del directorio de la receta. Este problema está solucionado en las versiones 2.36.1 y 3.2.0.","source":"nvd"}],"published":"2026-06-19T21:42:18.000Z","modified":"2026-10-25T17:10:00.197Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"}],"cwes":["CWE-22"],"affected":[{"ranges":[{"version":">= 2.32.0, < 2.36.1","status":"affected"},{"version":">= 3.0.0, < 3.2.0","status":"affected"}],"vendor":"symfony","product":"ux","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"2.32.0","status":"affected","fixed":"2.36.1"}],"ecosystem":"Packagist","package":"symfony/ux-toolkit","purl":"pkg:composer/symfony/ux-toolkit","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"3.0.0","status":"affected","fixed":"3.2.0"}],"ecosystem":"Packagist","package":"symfony/ux-toolkit","purl":"pkg:composer/symfony/ux-toolkit","source":"ghsa"}],"references":[{"url":"https://github.com/symfony/ux/security/advisories/GHSA-p9xj-fpr2-jf2q","tags":["web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/symfony/ux/commit/7b4ddf3764bf269a1b5fde5bf03c4bce568694e4","tags":["x-refsource-misc"],"sources":["cvelist","nvd"]},{"url":"https://github.com/symfony/ux/releases/tag/v2.36.1","tags":["x-refsource-misc"],"sources":["cvelist","nvd"]},{"url":"https://github.com/symfony/ux/releases/tag/v3.2.0","tags":["x-refsource-misc"],"sources":["cvelist","nvd"]},{"url":"https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/ux-toolkit/CVE-2026-55878.yaml","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/symfony/ux","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2026-07-09T14:18:56.012Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-55878","url":"https://www.cve.org/CVERecord?id=CVE-2026-55878","licence":"CVE Terms of Use","modified":"2026-07-09T14:19:07.068Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-p9xj-fpr2-jf2q","url":"https://github.com/advisories/GHSA-p9xj-fpr2-jf2q","licence":"CC-BY-4.0","modified":"2026-09-10T03:51:09.315Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-55878","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-55878","licence":"Public domain","modified":"2026-10-25T17:10:00.197Z"}],"updatedAt":"2026-11-25T22:59:27.455Z","epss":{"score":0.00146,"percentile":0.04057,"date":"2026-12-01T12:00:22.000Z"}}