Description
Race condition in bzip2 1.0.2 and earlier allows local users to modify permissions of arbitrary files via a hard link attack on a file while it is being decompressed, whose permissions are changed by bzip2 after the decompression is complete.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | bzip2 | 1.0.2-6 | — |
| Debian 13 | bzip2 | 1.0.2-6 | — |
| Debian 12 | bzip2 | 1.0.2-6 | — |
| Debian 3.0 | bzip2 | 1.0.2-1.woody2 | DSA-730-1 |
Red Hat
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 4 | bzip2 +2 | 1.0.2-13.EL4.3 | RHSA-2005:474 |
| RHEL 3 | bzip2 +2 | 1.0.2-11.EL3.4 | RHSA-2005:474 |
Advisories 2
- RHSA-2005:474 Red Hat Security Advisory: bzip2 security update Red Hat Security Advisories (RHSA) · Jun 26, 2026
- DSA-730-1 bzip2 - race condition Debian Security (DSA / DLA) · Mar 9, 2026
References
- oval:org.mitre.oval:def:1154 vdb-entry signature
- FLSA:158801 vendor-advisory
- 26444 vdb-entry
- bzip2-toctou-symlink(19926) vdb-entry
- DSA-730 vendor-advisory
- OpenPKG-SA-2007.002 vendor-advisory
- oval:org.mitre.oval:def:10902 vdb-entry signature
- 27274 third-party-advisory
- 20070109 rPSA-2007-0004-1 bzip2 mailing-list
- 200191 vendor-advisory
- APPLE-SA-2007-11-14 vendor-advisory
- http://docs.info.apple.com/article.html?artnum=307041
- ADV-2007-3525 vdb-entry
- ADV-2007-3868 vdb-entry
- 29940 third-party-advisory
- 27643 third-party-advisory
- 12954 vdb-entry
- 19183 third-party-advisory
- MDKSA-2006:026 vendor-advisory
- RHSA-2005:474 vendor-advisory
- TA07-319A third-party-advisory
- 20050330 bzip2 TOCTOU file-permissions vulnerability mailing-list
- 103118 vendor-advisory