{"cve":"CVE-2026-23986","nvd":{"published":"2026-01-21T23:15:52.793","modified":"2026-06-17T10:22:24.030","status":"Analyzed","description":"Copier is a library and CLI app for rendering project templates. Prior to version 9.11.2, Copier suggests that it's safe to generate a project from a safe template, i.e. one that doesn't use unsafe features like custom Jinja extensions which would require passing the `--UNSAFE,--trust` flag. As it turns out, a safe template can currently write to arbitrary directories outside the destination path by using directory a symlink along with `_preserve_symlinks: true` and a generated directory structure whose rendered path is inside the symlinked directory. This way, a malicious template author can create a template that overwrites arbitrary files (according to the user's write permissions), e.g., to cause havoc. Version 9.11.2 patches the issue.","cvss_v4":{"vector":"CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N","score":6.9},"cvss_v3":{"version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:H","score":7.1},"cwes":["CWE-61"],"references":["https://github.com/copier-org/copier/commit/b3a7b3772d17cf0e7a4481978188c9f536c8d8f6","https://github.com/copier-org/copier/releases/tag/v9.11.2","https://github.com/copier-org/copier/security/advisories/GHSA-4fqp-r85r-hxqh"],"products":["copier-org:copier"],"source":"nvd","synced_at":"2026-10-19T22:21:16.563232421+00:00"},"epss":{"cve":"CVE-2026-23986","score":0.0027,"percentile":0.19213,"date":"2026-10-31"},"kev":null,"osv":[{"id":"GHSA-4fqp-r85r-hxqh","url":"https://osv.dev/vulnerability/GHSA-4fqp-r85r-hxqh","summary":"Copier safe template has arbitrary filesystem write access via directory symlinks when _preserve_symlinks: true ","modified":"2026-07-07T17:56:39.975721258Z","packages":[{"ecosystem":"PyPI","name":"copier","purl":"pkg:pypi/copier","ranges":["<9.11.2"],"fixed":["9.11.2"]}]},{"id":"PYSEC-2026-1272","url":"https://osv.dev/vulnerability/PYSEC-2026-1272","summary":"Copier safe template has arbitrary filesystem write access via directory symlinks when _preserve_symlinks: true ","modified":"2026-07-07T17:47:12.903149376Z","packages":[{"ecosystem":"PyPI","name":"copier","purl":"pkg:pypi/copier","ranges":["<9.11.2"],"fixed":["9.11.2"]}]}],"attribution":["This product uses the NVD API but is not endorsed or certified by the NVD.","EPSS scores: FIRST Exploit Prediction Scoring System, https://www.first.org/epss","Known exploited vulnerabilities: CISA Known Exploited Vulnerabilities Catalog, https://www.cisa.gov/known-exploited-vulnerabilities-catalog","Package advisories: OSV (https://osv.dev), from the GitHub Advisory Database, PyPA, Go, RustSec and other ecosystem databases, under CC-BY 4.0 or CC0","CVE records: the CVE Program's CVE List (https://www.cve.org), under its terms of use (https://www.cve.org/Legal/TermsOfUse). CVE is a registered trademark of The MITRE Corporation; this product is not affiliated with the CVE Program."]}