# CVE-2026-53951: Copier: trust-prefix bypass via path traversal runs tasks unprompted

- Severity: High 8.8 (CVSS:4.0, scored by GitHub_M) `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`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.26%, higher than 19% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-07-08T15:26:08.626Z
- Modified: 2026-10-25T20:10:00.147Z
- Also known as: GHSA-9gmc-jqmh-3rvm, PYSEC-2026-3818
- Weaknesses: CWE-22, CWE-94
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total
- Assigned by: GitHub_M

## Description

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
(`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.

(As written by CVE List.)

## Affected

- copier-org copier: >= 9.5.0, < 9.15.2
- copier (PyPI): from 9.5.0 before 9.15.2

## Every score

- GitHub_M: CVSS:4.0 8.8 High `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`
- GitHub: CVSS:4.0 High `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`
- PyPA Advisory Database: CVSS:4.0 `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`

## References

- <https://github.com/copier-org/copier/security/advisories/GHSA-9gmc-jqmh-3rvm> (exploit, web)
- <https://github.com/copier-org/copier/releases/tag/v9.15.2> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-53951> (advisory)
- <https://github.com/copier-org/copier> (package)
- <https://pypi.org/project/copier> (package)
- <https://github.com/advisories/GHSA-9gmc-jqmh-3rvm> (advisory)

## Sources

- CVE List: [CVE-2026-53951](https://www.cve.org/CVERecord?id=CVE-2026-53951), CVE Terms of Use, modified 2026-07-09
- GitHub Advisory Database: [GHSA-9gmc-jqmh-3rvm](https://github.com/advisories/GHSA-9gmc-jqmh-3rvm), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2026-53951](https://nvd.nist.gov/vuln/detail/CVE-2026-53951), Public domain, modified 2026-10-25
- PyPA Advisory Database: [PYSEC-2026-3818](https://osv.dev/vulnerability/PYSEC-2026-3818), CC-BY-4.0, modified 2026-09-10

---

Page: https://cve.day/CVE-2026-53951 · Whole record: https://cve.day/CVE-2026-53951.json · Rebuilt by cve.day 2026-11-25T22:59:27.386Z
