Skip to main content

Copier EUVDEUVD-2026-42309

| CVE-2026-53951 HIGH
Path Traversal (CWE-22)
2026-07-08 GitHub_M GHSA-9gmc-jqmh-3rvm
8.8
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Craft template ref with trusted prefix plus '..'
  2. Delivery
    Victim runs Copier with a trusted prefix configured
  3. Exploit
    startswith grants trust but URL resolves elsewhere
  4. Execution
    Attacker template's tasks/migrations run without --trust prompt
  5. Impact
    Arbitrary command execution as the invoking user

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK

2 techniques across 2 tactics: Discovery, Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires that the victim has Copier's 'trust' setting configured with at least one trusted prefix (a non-default operator configuration), and that the victim invokes Copier against a template reference the attacker controls or influences which textually begins with that trusted prefix but embeds '..' dot-segments so the resolved location differs from the trusted string. Exploitation is limited by these factors: it is local (AV:L) and needs the operator to actually run Copier (UI:P/passive interaction), it depends on the pre-existing trusted-prefix configuration (without it the normal --trust prompt blocks the malicious template), and the specific normalization divergence must apply to the source type (Path.resolve() for local paths, libcurl dot-segment handling for https). Affected versions are strictly 9.5.0 through 9.15.1.

Impact

The vendor CVSS 4.0 vector (AV:L/AC:L/AT:P/PR:N/UI:P, high impact to both vulnerable and subsequent systems) scores 8.8 and correctly signals that this is not a remote, drive-by bug: it is local, requires a specific attack condition (AT:P) and passive user interaction (UI:P) - namely an operator who has configured a trusted prefix and is induced to run Copier against a crafted reference. No EPSS score was provided, there is no KEV listing, and no POC is referenced, so real-world exploitation pressure appears low-to-moderate and opportunistic rather than mass-scale. The severity is driven by the impact (arbitrary command execution) rather than by ease of reach; the primary limiting factor is that a trusted-prefix trust configuration must already exist, otherwise Copier's normal --trust prompt still protects the user. Note a consistency caveat: the 4.0 subsequent-system metrics (SC/SI/SA:H) imply a scope change, but the described impact is code execution as the invoking user on the same host, which is better modeled as vulnerable-system impact - verify scope framing with the advisory.

Exploit ScenarioDerived

An attacker publishes or influences a template reference such as 'https://trusted.example.com/../attacker/template' that lexically starts with the victim organization's configured trusted prefix. When a developer or CI job runs Copier with that trusted prefix set, the startswith check silently grants trust while the normalized fetch pulls the attacker's template, whose tasks/migrations then execute shell commands on the host without any --trust prompt. No public POC is referenced, but the mechanism is straightforward given local access to the Copier invocation and knowledge of the trusted prefix.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 08, 2026

Trust-boundary bypass in Copier 9.5.0 through 9.15.1 lets an attacker-controlled template execute arbitrary commands without the usual --trust confirmation. The flaw stems from the trust prefix check using a raw str.startswith on the un-normalized template URL, so a reference that textually begins with a trusted prefix but contains '..' is granted trust while actually resolving to a different template whose tasks/migrations/jinja_extensions then run. No public exploit identified at time of analysis, and it is not in CISA KEV; fixed in 9.15.2.

RemediationAI

Vendor-released patch: 9.15.2 - upgrade Copier to 9.15.2 or later (e.g. pip install --upgrade 'copier>=9.15.2') as the primary fix, per GHSA-9gmc-jqmh-3rvm and https://github.com/copier-org/copier/releases/tag/v9.15.2. If you cannot upgrade immediately, avoid configuring trusted prefixes in Copier settings so that every template again requires the interactive --trust confirmation (trade-off: reintroduces manual prompts for legitimate automated pipelines), and never pass externally-influenced or user-supplied template references to Copier runs that rely on trust prefixes. Additionally, only run Copier against templates from sources you fully control and inspect template references for '..' or other traversal segments before execution; treat CI/CD template resolution as untrusted input.

Affected VersionsENISA

copier 9.5.0, < 9.15.2

Affected Packages

pypi copier fix: 9.15.2

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Copier is a Python library/CLI for scaffolding projects from templates (a peer of cookiecutter). When rendering, template-supplied hooks - tasks, migrations, and jinja_extensions - can run shell/Python code, so Copier gates them behind an interactive --trust prompt unless the template's source matches an operator-configured trusted prefix. The root cause is CWE-22 (Improper Limitation of a Pathname to a Restricted Directory / path traversal): in copier/_settings.py the prefix comparison is a naive lexical str.startswith with no path normalization, whereas the fetch path normalizes the URL (Path.resolve() for local filesystem sources, libcurl dot-segment removal for https). This normalization mismatch means the string that is trusted and the location that is fetched can diverge once '..' segments are present. The single affected package is cpe:2.3:a:copier-org:copier.

Know when Copier gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 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
vuln.today AI 7.0 HIGH

Local CLI execution (AV:L) needing an operator to run Copier (UI:R) with a pre-set trusted prefix and a crafted traversal path (AC:H); code execution as the user yields C/I/A:H, scope unchanged.

3.1 AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H
4.0 AV:L/AC:H/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
None
User Interaction
Passive
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
High
Subsequent system: Confidentiality
High
Subsequent system: Integrity
High
Subsequent system: Availability
High

Lifecycle Timeline

2
Patch available
Jul 08, 2026 - 17:01 EUVD
CVE Published
Jul 08, 2026 - 15:26 cve.org
HIGH 8.8

DescriptionCVE.org

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.

Executive ViewAI

Why It Matters

Copier template engine versions 9.5.0-9.15.1 allow attackers to execute arbitrary code by exploiting a trust control bypass in template references, affecting any organization processing external templates. While no public exploit identified at time of analysis, the vulnerability's high severity and ease of exploitation make immediate patching to version 9.15.2 critical for protecting systems from code execution.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.2%
Top 91% exploitable
Prevalence
Medium
popular Python project-templating CLI, common in developer and CI tooling
Threat Intel
1
1 sources
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
Poc
System Exposure· derived
Small
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

44
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy