CPANSA-Archive-Tar-2026-42497: Archive-Tar vulnerability

Publisher giterlizzi Document category csaf_security_advisory
Initial release date 2026-05-26T00:00:00 Engine CSAF Perl Toolkit 0.26
Current release date 2026-05-26T00:00:00 Build Date
Current version 1 Status final
CVSS v3.1 Base Score 7.5 Severity
Original language Language en
Also referred to

Vulnerability Description

Archive::Tar versions before 3.08 for Perl extract hardlinks to attacker controlled paths outside the extraction directory. _make_special_file() passes the tar header's linkname to link() without validating it against absolute paths or .. segments, creating a hardlink that shares the victim file's inode. A subsequent write through the extracted name modifies the victim file, and the post-extraction chmod, chown, and utime block in _extract_file() (guarded only against symlinks via -l) applies the tar header's mode, owner, and timestamps to the shared inode during extraction alone.

Vulnerabilities

CVE-2026-42497

Vulnerability Description

Archive::Tar versions before 3.08 for Perl extract hardlinks to attacker controlled paths outside the extraction directory.

_make_special_file() passes the tar header's linkname to link() without validating it against absolute paths or .. segments, creating a hardlink that shares the victim file's inode.

A subsequent write through the extracted name modifies the victim file, and the post-extraction chmod, chown, and utime block in _extract_file() (guarded only against symlinks via -l) applies the tar header's mode, owner, and timestamps to the shared inode during extraction alone.

Weakness CWE-59 : Improper Link Resolution Before File Access ('Link Following')

Product status

Known affected
Product Score
Archive-Tar less than 3.08
CVSS Version CVSS Vector CVSS Base Score CVSS Base Severity
3.1 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N 7.5 High
Fixed

giterlizzi

Namespace: https://github.com/giterlizzi/

gdt@cpan.org

References

Revision history

Version Date of the revision Summary of the revision
1 Tue May 26 00:00:00 2026 First release

Sharing rules

TLP:WHITE
For the TLP version see: https://www.first.org/tlp/