A critical vulnerability named TARmageddon (CVE-2025-62518) was discovered in the async-tar Rust library and its forks, including tokio-tar, which is widely used in Python and web development ecosystems. The flaw, with a CVSS score of 8.1 (High), allows remote code execution via malicious nested TAR archives, enabling attackers to overwrite configuration files and hijack build backends. Astral’s uv package manager, testcontainers, and wasmCloud were among the affected projects. The vulnerability stems from a desynchronization flaw in TAR parsing, where mismatched PAX and ustar headers cause the parser to incorrectly merge hidden malicious payloads with legitimate files. This enables Python build backend hijacking, container image poisoning, and bypassing security scans. While patches were released for active forks (e.g., astral-tokio-tar), the original tokio-tar (5M+ downloads) remains unpatched, leaving downstream users exposed unless they migrate. The incident highlights risks from abandoned open-source projects and the need for proactive dependency management. Astral took over maintenance of astral-tokio-tar as the recommended fix, but unpatched systems remain vulnerable to supply-chain attacks, CI/CD compromises, and malicious package distribution.
Source: https://cyberpress.org/tarmageddon-bug-in-rust-library/
TPRM report: https://www.rankiteo.com/company/astral-sh
"id": "ast4632346102325",
"linkid": "astral-sh",
"type": "Vulnerability",
"date": "6/2025",
"severity": "85",
"impact": "4",
"explanation": "Attack with significant impact with customers data leaks"
{'affected_entities': [{'customers_affected': 'Downstream Rust/Python projects',
'industry': 'Software Development',
'name': 'tokio-tar',
'size': '5M+ downloads (crates.io)',
'type': 'Open-Source Library'},
{'customers_affected': 'Python developers using uv',
'industry': 'Developer Tools',
'name': 'Astral (uv package manager)',
'type': 'Software Company'},
{'customers_affected': 'Teams using containerized '
'testing',
'industry': 'DevOps/Testing',
'name': 'testcontainers',
'type': 'Open-Source Project'},
{'industry': 'WebAssembly/Cloud',
'name': 'wasmCloud',
'type': 'Open-Source Project'},
{'industry': 'Cybersecurity',
'name': 'Edera Security',
'type': 'Security Research Team'}],
'attack_vector': ['Malicious TAR Archive Extraction (Nested Headers '
'Desynchronization)',
'Python Build Backend Hijacking (PyPI)',
'Container Image Poisoning (Testcontainers)',
'Security Scan Bypass (Hidden Files in Inner Archives)'],
'customer_advisories': ['Urgent patching/migration required for tokio-tar '
'users',
'Validation steps for PyPI package consumers',
'Guidance for secure TAR extraction in CI/CD'],
'data_breach': {'file_types_exposed': ['Configuration files',
'Build backend scripts',
'Hidden payloads in inner TAR '
'archives']},
'description': 'A critical vulnerability (CVE-2025-62518, severity 8.1 - '
'High) in the async-tar Rust library and its derivative forks '
'(e.g., tokio-tar) allows remote code execution via crafted '
'nested TAR archives. The flaw enables attackers to overwrite '
'configuration files and hijack build backends by exploiting '
'desynchronization between PAX extended headers and ustar '
'headers. The vulnerability affects major projects like '
'Astral’s uv package manager, testcontainers, and wasmCloud. '
'The unmaintained status of tokio-tar (5M+ downloads) '
'complicates patching, forcing decentralized disclosure. '
'Patches prioritize PAX headers and enforce strict validation, '
'but unpatched systems remain at risk of Python build backend '
'hijacking, container image poisoning, and security scan '
'bypasses.',
'impact': {'brand_reputation_impact': ['Erosion of trust in Rust ecosystem '
'security',
'Highlighted risks of abandonware in '
'critical dependencies'],
'operational_impact': ['Decentralized disclosure coordination '
'challenges',
'Manual patching/migration required for '
'unmaintained forks',
'Risk of supply chain compromise via '
'PyPI/testcontainers'],
'systems_affected': ['Developer machines (via PyPI package '
'installation)',
'CI/CD pipelines',
'Testcontainers environments',
'wasmCloud deployments',
'Downstream projects using tokio-tar (5M+ '
'instances)']},
'investigation_status': 'Ongoing (patches released; unpatched tokio-tar '
'remains vulnerable)',
'lessons_learned': ['Rust’s memory safety does not prevent logic bugs (e.g., '
'header parsing flaws).',
'Abandonware in critical dependencies creates systemic '
'risk despite ecosystem popularity.',
'Decentralized disclosure is resource-intensive and '
'error-prone for unmaintained projects.',
'Defense-in-depth strategies (e.g., post-extraction '
'validation) are essential for supply chain security.',
'Proactive library maintenance and successor planning are '
'needed for open-source sustainability.'],
'post_incident_analysis': {'corrective_actions': ['Patch release enforcing '
'PAX header priority and '
'validation',
'Astral’s adoption of '
'tokio-tar maintenance '
'(astral-tokio-tar)',
'Community-driven fork '
'audits and maintainer '
'succession planning',
'Enhanced TAR parser '
'testing for nested archive '
'edge cases'],
'root_causes': ['Header desynchronization (PAX vs. '
'ustar priority mismatch)',
'Lack of maintainer responsiveness '
'for tokio-tar (abandonware)',
'Absence of standardized security '
'contacts for open-source forks',
'Over-reliance on memory safety '
'without logic bug safeguards']},
'recommendations': ['Immediately upgrade to patched versions (e.g., '
'astral-tokio-tar for uv users).',
'Migrate from tokio-tar to actively maintained '
'alternatives (e.g., standard tar crate).',
'Implement runtime mitigations: post-extraction directory '
'scanning, file count validation.',
'Audit dependencies for unmaintained forks and establish '
'fallback maintenance plans.',
'Enforce strict validation of TAR archive headers in '
'build pipelines.',
'Monitor PyPI/testcontainers for malicious packages '
'exploiting TARmageddon.'],
'references': [{'source': 'Edera Security Advisory'}],
'response': {'communication_strategy': ['Public vulnerability disclosure',
'Decentralized outreach to fork '
'maintainers via community sleuthing',
'Developer advisories for '
'uv/testcontainers/wasmCloud users'],
'containment_measures': ['Patches released for active forks '
'(e.g., astral-tokio-tar)',
'Recommendation to migrate from '
'tokio-tar to maintained alternatives'],
'enhanced_monitoring': ['Post-extraction validation checks'],
'incident_response_plan_activated': True,
'recovery_measures': ['Astral’s takeover of astral-tokio-tar '
'maintenance',
'Guidance for manual upgrades/migration'],
'remediation_measures': ['Prioritize PAX headers over ustar for '
'size determination',
'Validate header consistency',
'Strict boundary checking in TAR '
'parsers',
'Post-extraction directory scanning '
'(mitigation)',
'File count validation (mitigation)'],
'third_party_assistance': ['Edera Security Team']},
'stakeholder_advisories': ['Developers using uv/testcontainers/wasmCloud',
'Maintainers of async-tar/tokio-tar forks',
'Rust/Python ecosystem security teams'],
'title': 'TARmageddon Vulnerability (CVE-2025-62518) in async-tar and '
'tokio-tar Libraries',
'type': ['Vulnerability', 'Supply Chain Attack', 'Logic Bug'],
'vulnerability_exploited': {'affected_components': ['async-tar',
'tokio-tar',
'astral-tokio-tar '
'(pre-patch)',
'uv package manager',
'testcontainers',
'wasmCloud'],
'cve_id': 'CVE-2025-62518',
'description': 'Desynchronization flaw in TAR '
'parser: prioritizes ustar headers '
'(often size=0) over PAX extended '
'headers, causing incorrect stream '
'positioning and merging of hidden '
'inner archive payloads with outer '
'legitimate files.',
'root_cause': 'Logic bug in header size '
'validation (PAX vs. ustar priority '
'mismatch)',
'severity': 'High (8.1)'}}