Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. copier
  4. ›
  5. CVE-2025-55201

CVE-2025-55201: Copier's safe template has arbitrary filesystem read/write access

August 18, 2025 (updated November 10, 2025)

Copier’s current security model shall restrict filesystem access through Jinja:

  • Files can only be read using {% include ... %}, which is limited by Jinja to reading files from the subtree of the local template clone in our case.
  • Files are written in the destination directory according to their counterparts in the template.

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 read and write arbitrary files because we expose a few pathlib.Path objects in the Jinja context which have unconstrained I/O methods. This effectively renders our security model w.r.t. filesystem access useless.

References

  • github.com/advisories/GHSA-3xw7-v6cj-5q8h
  • github.com/copier-org/copier
  • github.com/copier-org/copier/commit/3feea3b3ff3c20d80cbb16a2f3b9567ffc5606d1
  • github.com/copier-org/copier/security/advisories/GHSA-3xw7-v6cj-5q8h
  • nvd.nist.gov/vuln/detail/CVE-2025-55201

Code Behaviors & Features

Detect and mitigate CVE-2025-55201 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions before 9.9.1

Fixed versions

  • 9.9.1

Solution

Upgrade to version 9.9.1 or above.

Impact 7.8 HIGH

CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

Source file

pypi/copier/CVE-2025-55201.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:16:58 +0000.