tar: does not properly warn the user when extracting setuid or setgid files
Published Aug 10, 2005
7.0
HIGHCVSS 3.1
EPSS 3.99%
Description
Tar 1.15.1 does not properly warn the user when extracting setuid or setgid files, which may allow local users or remote attackers to gain privileges.
Affected products
No data.
No data.
Red Hat Enterprise Linux 10
tar
Will not fix
Red Hat Enterprise Linux 6
tar
Will not fix
Red Hat Enterprise Linux 7
tar
Will not fix
Red Hat Enterprise Linux 8
tar
Will not fix
Red Hat Enterprise Linux 9
tar
Will not fix
| Product | Package | State | Advisory |
|---|---|---|---|
| Red Hat Enterprise Linux 10 | tar | Will not fix | n/a |
| Red Hat Enterprise Linux 6 | tar | Will not fix | n/a |
| Red Hat Enterprise Linux 7 | tar | Will not fix | n/a |
| Red Hat Enterprise Linux 8 | tar | Will not fix | n/a |
| Red Hat Enterprise Linux 9 | tar | Will not fix | n/a |
No package ranges for this CVE.
Remediation
Red Hat statement
Currently, there are no plans to change tar behaviour to strip setuid and setgid bits when extracting archives. This vulnerability is considered moderate rather than important because the exploitation scenario requires specific conditions: the `tar` extraction must be performed by the root user, and the tarball itself must be crafted maliciously with setuid or setgid bits. In typical use cases, users do not routinely extract untrusted tar files as root, reducing the likelihood of exploitation. Additionally, non-root extractions do not preserve these bits unless explicitly requested with the `-p` option.
Red Hat mitigation
To mitigate the risks associated with this vulnerability, avoid extracting tar files as the root user, especially when dealing with untrusted sources. Instead, perform extractions as a non-root user or in a restricted environment. Use a dedicated, empty directory for extracting archives to prevent accidental exposure of sensitive files. After extraction, review the file permissions to check for unexpected setuid or setgid bits before granting access. When extraction as root is necessary, use the --no-same-permissions option to prevent preserving the setuid and setgid bits.
Metrics
No CVSS v4.0 score for this CVE.
CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H
No CVSS v3.0 score for this CVE.
AV:N/AC:L/Au:N/C:C/I:C/A:C
This CVE is not in the KEV list.
No CISA SSVC assessment for this CVE yet.
Estimated probability of exploitation in the wild in the next 30 days (FIRST EPSS). As of Oct 1, 2026.
Score over time
2022–2026- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Percentile over time
- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Table of values (20 key points)
Flat stretches are collapsed; showing up to 120 newest points.
| Date | Score | Percentile | Model |
|---|---|---|---|
| Oct 1, 2026 | 3.99% (0.03992) | 90.19th | v5 (v2026.06.15) |
| Jun 15, 2026 | 3.99% (0.03992) | 89.14th | v5 (v2026.06.15) |
| Apr 11, 2026 | 3.87% (0.03869) | 88.23th | v4 (v2025.03.14) |
| Jan 21, 2026 | 2.81% (0.02806) | 85.72th | v4 (v2025.03.14) |
| Sep 24, 2025 | 1.57% (0.01572) | 80.90th | v4 (v2025.03.14) |
| Jul 18, 2025 | 3.74% (0.03739) | 87.51th | v4 (v2025.03.14) |
| Mar 30, 2025 | 2.54% (0.02537) | 84.07th | v4 (v2025.03.14) |
| Mar 29, 2025 | 6.97% (0.06971) | 85.40th | v4 (v2025.03.14) |
| Mar 17, 2025 | 2.60% (0.02605) | 84.60th | v4 (v2025.03.14) |
| Dec 12, 2024 | 0.69% (0.00691) | 80.83th | v3 (v2023.03.01) |
| Jul 17, 2024 | 0.69% (0.00691) | 80.36th | v3 (v2023.03.01) |
| Apr 10, 2024 | 0.63% (0.00634) | 78.77th | v3 (v2023.03.01) |
| Nov 30, 2023 | 0.63% (0.00634) | 76.75th | v3 (v2023.03.01) |
| May 8, 2023 | 0.62% (0.00617) | 75.62th | v3 (v2023.03.01) |
| Apr 16, 2023 | 0.87% (0.00873) | 80.04th | v3 (v2023.03.01) |
| Mar 7, 2023 | 0.77% (0.00773) | 78.50th | v3 (v2023.03.01) |
| Mar 6, 2023 | 1.05% (0.01055) | 52.13th | v2 (v2022.01.01) |
| Sep 17, 2022 | 1.05% (0.01055) | 50.47th | v2 (v2022.01.01) |
| Apr 1, 2022 | 1.05% (0.01055) | 48.43th | v2 (v2022.01.01) |
| Feb 4, 2022 | 1.05% (0.01055) | 27.52th | v2 (v2022.01.01) |
No CWE recorded.
References (6)
- http://marc.info/?l=bugtraq&m=112327628230258&w=2 mailing-listx_refsource_BUGTRAQ
- https://access.redhat.com/security/cve/CVE-2005-2541 Vendor Advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=1974387 Issue Tracking
- https://lists.apache.org/thread.html/rc713534b10f9daeee2e0990239fa407e2118e4aa9e88a7041177497c%40%3Cissues.guacamole.apache.org%3E mailing-listx_refsource_MLIST
- https://nvd.nist.gov/vuln/detail/CVE-2005-2541
- https://www.cve.org/CVERecord?id=CVE-2005-2541
| Link | Providers | Tags |
|---|---|---|
| http://marc.info/?l=bugtraq&m=112327628230258&w=2 | mailing-listx_refsource_BUGTRAQ | |
| https://access.redhat.com/security/cve/CVE-2005-2541 | Vendor Advisory | |
| https://bugzilla.redhat.com/show_bug.cgi?id=1974387 | Issue Tracking | |
| https://lists.apache.org/thread.html/rc713534b10f9daeee2e0990239fa407e2118e4aa9e88a7041177497c%40%3Cissues.guacamole.apache.org%3E | mailing-listx_refsource_MLIST | |
| https://nvd.nist.gov/vuln/detail/CVE-2005-2541 | ||
| https://www.cve.org/CVERecord?id=CVE-2005-2541 |
Change history (0)
No recorded changes yet.