# CVE-2025-59825: astral-tokio-tar has a path traversal in tar extraction

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 6.1
- **CVSS:** 6.1 (v4.0, CNA) `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:U`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Attack requirements: None; Privileges required: None; User interaction: None; Confidentiality impact: High; Integrity impact: High; Availability impact: High; Confidentiality impact on other systems: None; Integrity impact on other systems: None; Availability impact on other systems: None; Exploit maturity: Unreported
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.29% (percentile 14, 2026-11-26)
- **CWE:** CWE-22, CWE-61
- **Aliases:** GHSA-3wgq-wrwc-vqmv
- **Published:** 2025-09-23T17:45:07.000Z
- **Modified:** 2026-10-11T20:10:00.200Z

## Who should check

- Projects that depend on crates.io package astral-tokio-tar (\< 0.5.4)
- Anyone running astral-sh tokio-tar \< 0.5.4

## 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.

## Affected and fixed versions

- crates.io `astral-tokio-tar`: affected \< 0.5.4; fixed 0.5.4 (osv)
- astral-sh tokio-tar: \< 0.5.4 (cvelist)

## Mitigation

- Upgrade astral-tokio-tar to 0.5.4 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-59825. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-59825.md
Affected: astral-tokio-tar < 0.5.4
Fixed in: 0.5.4

Steps:
1. Search this machine and project for astral-tokio-tar (crates.io), astral-sh tokio-tar: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-59825 being exploited?

There is no confirmed exploitation: CVE-2025-59825 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.29% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-59825?

Medium: CVSS 6.1 (v4.0, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2025-59825?

astral-tokio-tar \< 0.5.4.

### Is there a fix for CVE-2025-59825?

Yes. Fixed in 0.5.4. Upgrade astral-tokio-tar to 0.5.4 or later.

### How do I check if I'm affected by CVE-2025-59825?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://github.com/astral-sh/tokio-tar/security/advisories/GHSA-3wgq-wrwc-vqmv>
- vendor: <https://github.com/google/security-research/security/advisories/GHSA-9p78-p5g6-gcj8>
- patch: <https://github.com/astral-sh/tokio-tar/commit/036fdecc85c52458ace92dc9e02e9cef90684e75>
- other: <https://github.com/astral-sh/uv/issues/12163>
- other: <https://github.com/astral-sh/tokio-tar>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-59825>
- OSV: CC-BY 4.0 <https://osv.dev/vulnerability/GHSA-3wgq-wrwc-vqmv> (license: <https://creativecommons.org/licenses/by/4.0/>)

HTML: <https://flawdb.com/CVE-2025-59825> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-59825>
