Bug 1318562 (CVE-2016-6321) - CVE-2016-6321 tar: Bypassing the extract path name
Summary: CVE-2016-6321 tar: Bypassing the extract path name
Keywords:
Status: CLOSED WONTFIX
Alias: CVE-2016-6321
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1389192
Blocks: 1318564
TreeView+ depends on / blocked
 
Reported: 2016-03-17 09:03 UTC by Adam Mariš
Modified: 2021-02-17 04:09 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-06-08 02:49:49 UTC
Embargoed:


Attachments (Terms of Use)

Description Adam Mariš 2016-03-17 09:03:30 UTC
It was found that GNU tar archiver can be tricked into extracting files and directories in the given destination, regardless of the path name(s) specified on the command line. GNU `tar' archiver attempts to avoid path traversal attacks by removing offending parts of the element name at extract. This sanitizing leads to a vulnerability where the attacker can bypass the path name(s) specified on the command line. The attacker can create a crafted tar archive that, if extracted by the victim, replaces files and directories the victim has access to in the target directory, regardless of the path name(s) specified on the command line.

External Reference:

https://sintonen.fi/advisories/tar-extract-pathname-bypass.txt

Comment 1 Adam Mariš 2016-03-17 09:03:34 UTC
Acknowledgments:

Name: Harry Sintonen

Comment 4 Stefan Cornelius 2016-04-05 12:23:10 UTC
Mitigation:

Use the "star" utility provided by the "star" package to process archives from untrusted sources.

Statement:

Red Hat Product Security has rated this issue as having Moderate security
impact, a future update may address this flaw. This issue did not affect the versions of star as shipped with Red Hat Enterprise Linux 5, 6, and 7.

Comment 7 Andrej Nemec 2016-10-27 07:22:05 UTC
Created tar tracking bugs for this issue:

Affects: fedora-all [bug 1389192]

Comment 8 Andrej Nemec 2016-10-27 07:22:34 UTC
Public via:

http://seclists.org/fulldisclosure/2016/Oct/96

Comment 10 Andrej Nemec 2016-10-31 09:40:27 UTC
Patch for this issue has been updated according to the researcher:

http://seclists.org/fulldisclosure/2016/Oct/102


Note You need to log in before you can comment on or make changes to this bug.