Intel

AIKIDO-2026-613285

copier is vulnerable to Path Traversal

Path TraversalGHSA-rg63-g45r-jc58 Published Today

55

Medium Risk

This Affects:

PYTHONcopier
0.0.1 - 9.17.1
Fixed in 9.17.2
Are you affected? Scan for Free

TL;DR

Copier renders templates with a Jinja loader that follows {% include %} directives. When _preserve_symlinks is enabled, the loader follows a symlink whose target resolves outside the template root, reading external file contents into the generated project and recreating the symlink there. Processing an untrusted template this way discloses arbitrary local files without enabling unsafe mode. The fix replaces the unrestricted FileSystemLoader with a loader that resolves the included filename and rejects symlinks escaping the template root.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and you process an untrusted template with _preserve_symlinks enabled that uses a Jinja include referencing a symlink.

Background info

copier is vulnerable to Path Traversal in versions 0.0.1 - 9.17.1.

How to fix this

Upgrade the copier library to the patch version.