Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft tar archive with symlink escape or ../ members
-
DeliveryPublish or inject malicious package to reachable index
-
ExploitVictim triggers dependency install via PDM or similar tool
-
Executionunearth fetches and begins extracting archive
-
Persistis_within_directory check bypassed due to missing realpath normalization
-
ImpactAttacker-controlled file written to arbitrary writable filesystem location
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 | Exploitation requires that the target system run unearth version 0.18.2 or earlier and extract a tar archive sourced from an attacker-controlled or compromised package index. The malicious archive must contain at least one of: (a) a member filename incorporating ../ path traversal sequences, or (b) a symlink member whose linkname resolves outside the extraction root directory. No authentication or elevated privileges are required on the attacker side - publishing or injecting a package to a reachable index is sufficient. On the victim side, passive user interaction is required: a user, automated pipeline, or dependency resolver must invoke a package install or resolution command that causes unearth to fetch and unpack the malicious archive. Exploitation is bounded by the OS-level write permissions of the process running unearth; paths protected by filesystem ACLs beyond that user context cannot be written. Environments that pin all dependencies to verified hashes and pull exclusively from trusted, audited indexes substantially reduce exposure even on unpatched versions. |
| Impact | The CVSS 4.0 base score of 7.2 (AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:H) correctly characterizes the core threat: no privileges are required on the attacker side, attack complexity is low once a malicious package is in place, and both integrity and availability impacts are high because arbitrary file writes can corrupt or replace binaries, configuration files, or interpreter entry points. The UI:P metric in CVSS 4.0 (passive user interaction) reflects that a victim process must actively trigger package extraction - for example, through an automated CI install. There is no confidentiality impact since the flaw enables writes but not reads. Even a mid-sized municipal IT team in malbork running automated Python dependency resolution via PDM would face meaningful exposure if any dependency is sourced from an untrusted or compromised index. EPSS data was not provided in the intelligence feed; however, the public proof-of-concept (confirmed via GitHub issue #180 and VulnCheck advisory) materially lowers the bar for exploitation beyond what low product prevalence alone would suggest. Absence from CISA KEV means widespread or confirmed active exploitation is not established at time of analysis, but the supply-chain delivery model - where a single malicious package version can reach many victims automatically - is a well-documented escalation path for this vulnerability class. |
| Exploit ScenarioDerived | An attacker publishes a malicious Python package to PyPI or a private index (or compromises a legitimate package version) containing a tar archive with symlink members whose link targets use ../ sequences to escape the extraction directory. When a developer or CI pipeline resolves dependencies using PDM or another unearth-backed tool, the library extracts the archive and the unnormalized is_within_directory check is bypassed, silently writing the attacker-supplied file to an arbitrary writable location - such as overwriting a cron job, an SSH authorized_keys file, or a Python entry-point script. A public proof-of-concept demonstrating this technique is available at https://github.com/frostming/unearth/issues/180. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Aug 10, 2026
Path traversal in the unearth Python package discovery library through version 0.18.2 allows an attacker who controls or compromises a package source to write arbitrary files to any filesystem location accessible to the extracting process. The flaw resides in the is_within_directory function, which performs only a lexical path containment check without resolving symlinks or normalizing ../ sequences via os.path.realpath(), meaning maliciously crafted tar archive members silently bypass the extraction guard. A publicly available proof-of-concept exists at GitHub issue #180; the upstream fix was merged in commit 6c78164, but no confirmed active exploitation per CISA KEV has been reported.
RemediationAI
Upgrade unearth to the first release incorporating commit 6c78164e7bfa28b8b3d6f247b87e560692e3c8ba (https://github.com/frostming/unearth/commit/6c78164e7bfa28b8b3d6f247b87e560692e3c8ba); confirm the installed version exceeds 0.18.2 by running pip show unearth. The patch PR and VulnCheck advisory (https://www.vulncheck.com/advisories/unearth-path-traversal-via-unnormalized-paths-and-symlink-escape) provide additional verification context. Because only the upstream commit and not a tagged release version has been independently confirmed from available data, verify the PyPI release changelog before deploying. If an immediate upgrade is blocked, restrict package sources to trusted, hash-verified indexes only and avoid processing tar archives from third-party or user-supplied origins. Running the extracting process in a container or under a dedicated low-privilege OS account with filesystem access constrained by a seccomp profile, chroot, or systemd PrivateTmp reduces the blast radius of a successful traversal - arbitrary writes remain possible, but are limited to paths writable by that restricted account, not the broader filesystem. Note that filesystem sandboxing is a compensating control only; it does not fix the underlying validation flaw.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
unearth (CPE: cpe:2.3:a:frostming:unearth:*:*:*:*:*:*:*:*) is a Python library used by package managers - most notably PDM - to locate, fetch, and unpack distribution archives from package indexes. The root cause maps to CWE-22 (Improper Limitation of a Pathname to a Restricted Directory). In affected versions, is_within_directory called Path(path).relative_to(directory), which is purely a string/lexical operation: Python's pathlib does not resolve symlinks or collapse ../ components before comparison, so a path like /extract/root/../../../etc/cron.d/evil would pass the check. The same weakness affected both the tar and zip extraction paths. The vendor fix in PR #181 replaces the call with Path(os.path.realpath(path)).relative_to(os.path.realpath(directory)), forcing filesystem-level resolution of all symlinks and traversal sequences before containment is verified. The tar code additionally gained explicit symlink link-target validation: for each symlink member, the resolved link destination is checked against the extraction root and the member is skipped with a warning if it points outside.
Know when Unearth 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
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N
Attacker serves the archive over the network with no privileges; victim must trigger extraction (UI:R); writes but cannot read, so C:N; scope unchanged.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
unearth through 0.18.2, fixed in commit 6c78164, contains a path traversal vulnerability in the is_within_directory function that fails to normalize paths before validation, allowing ../ sequences to bypass directory containment checks. Attackers can supply malicious tar archives with symlink members or traversal sequences to write files to arbitrary filesystem locations accessible to the process.
Latest POC
1 PoC candidate from github (unverified)
Sign in to open the public PoC links collected for this CVE.
Executive ViewAI
The unearth Python package discovery library contains a path traversal vulnerability that allows attackers who compromise package sources to inject arbitrary files into development environments. Organizations using versions 0.18.2 or earlier face supply chain risk, with potential impact to all applications built on affected dependencies.
Apply vendor patch.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.
Same weakness CWE-22 – Path Traversal
View allSame technique Path Traversal
View allVendor StatusVendor
SUSE
Severity: Important| Product | Status |
|---|---|
| openSUSE Leap 16.0 | Fixed |
| openSUSE Tumbleweed | Fixed |
EUVD-2026-55802
GHSA-2fcv-9f95-p67v
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB