CVE-2025-59825: astral-sh tokio-tar · Path Traversal
Affects astral-sh tokio-tarSource CVE Database V5
Not known to be exploited · CVSS 6.1 Medium : upgrade to 0.5.4 when convenient.
Data as of 26 Oct 2026, 06:26 UTC
- EPSS
- 0.2% chance of exploitation in 30 days – higher than 12% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
- Patch
- Available – fixed in 0.5.4
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:UExploitation evidence
Disclosed: evidence found.
CVE published 23 Sep 2025
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 2026-10-26.
What to do
Upgrade astral-sh tokio-tar to 0.5.4.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| astral-sh tokio-tar | Affected
| Fixed in
|
AI-suggested
The primary and only effective mitigation is to upgrade the tokio-tar library to version 0.5.4 or later, where the vulnerability has been patched. Organizations should audit their codebases and dependencies to identify usage of astral-sh tokio-tar versions below 0.5.4 and update accordingly. For environments where immediate upgrade is not feasible, strict validation and sanitization of tar archives before extraction should be implemented, including rejecting archives containing suspicious symlink chains or path traversal patterns. Running extraction processes with least privilege and within sandboxed or containerized environments can limit the impact of exploitation. Monitoring file system changes during extraction and employing integrity verification mechanisms post-extraction can help detect exploitation attempts. Additionally, organizations should review and harden CI/CD pipelines and automated workflows that handle tar archives to prevent processing untrusted inputs. Finally, maintain awareness of supply chain security to avoid introduction of malicious archives.
Description
astral-tokio-tar is a tar archive reading/writing library for async Rust. In versions 0.5.3 and earlier of astral-tokio-tar, tar archives may extract outside of their intended destination directory when using the Entry::unpack_in_raw API. Additionally, the Entry::allow_external_symlinks control (which defaults to true) could be bypassed via a pair of symlinks that individually point within the destination but combine to point outside of it. These behaviors could be used individually or combined to bypass the intended security control of limiting extraction to the given directory. This in turn would allow an attacker with a malicious tar archive to perform an arbitrary file write and potentially pivot into code execution. This issue has been patched in version 0.5.4. There is no workaround other than upgrading.