{"id":"CVE-2026-53951","summary":"Copier: trust-prefix bypass via path traversal runs tasks unprompted","details":"Copier is a library and CLI app for rendering project templates. In versions 9.5.0 through 9.15.1, the `trust` setting's prefix match\n(`copier/_settings.py`) compares the template URL against a trusted prefix with a raw `str.startswith` and no path normalization, while the URL is normalized when the template is actually fetched (`Path.resolve()` for local paths; libcurl dot-segment removal for `https`). A template reference that textually starts with a trusted prefix but contains `..` is therefore granted trust yet resolves to a different, attacker-controlled template, whose `tasks` / `migrations` / `jinja_extensions` then run without the `--trust` prompt — arbitrary command execution. Version 9.15.2 patches the issue.","aliases":["GHSA-9gmc-jqmh-3rvm"],"modified":"2026-08-12T03:51:15.795024734Z","published":"2026-07-08T15:26:08.626Z","database_specific":{"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/53xxx/CVE-2026-53951.json","cna_assigner":"GitHub_M","cwe_ids":["CWE-22","CWE-94"]},"references":[{"type":"WEB","url":"https://github.com/copier-org/copier/releases/tag/v9.15.2"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/53xxx/CVE-2026-53951.json"},{"type":"ADVISORY","url":"https://github.com/copier-org/copier/security/advisories/GHSA-9gmc-jqmh-3rvm"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-53951"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/copier-org/copier","events":[{"introduced":"d735c8beac8307c06d9c881714328b76711a4b4d"},{"fixed":"a90729e8b828ccfdd4e066696044ac20a85be81c"}],"database_specific":{"source":"AFFECTED_FIELD","extracted_events":[{"introduced":"9.5.0"},{"fixed":"9.15.2"}]}}],"versions":["v9.15.1","v9.15.0","v9.14.3","v9.14.2","v9.14.1","v9.14.0","v9.13.1","v9.13.0","v9.12.0","v9.11.3","v9.11.2","v9.11.1","v9.11.0","v9.10.3","v9.10.2","v9.10.1","v9.10.0","v9.9.1","v9.9.0","v9.8.0","v9.7.1","v9.7.0","v9.6.0","v9.5.0"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-53951.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H"}]}