Bug 155745 - CAN-2005-0988 Race condition in gzip
CAN-2005-0988 Race condition in gzip
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: gzip (Show other bugs)
All Linux
medium Severity low
: ---
: ---
Assigned To: Ivana Varekova
Ben Levenson
: Security
Depends On:
  Show dependency treegraph
Reported: 2005-04-22 14:18 EDT by Josh Bressers
Modified: 2007-11-30 17:07 EST (History)
0 users

See Also:
Fixed In Version: RHSA-2005-357
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-06-13 08:12:57 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Proposed patch from Steve Grubb (1.29 KB, patch)
2005-04-29 09:59 EDT, Josh Bressers
no flags Details | Diff

External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2005:357 normal SHIPPED_LIVE Low: gzip security update 2005-06-13 00:00:00 EDT

  None (edit)
Description Josh Bressers 2005-04-22 14:18:09 EDT
Race condition in gzip 1.2.4, 1.3.3, and earlier when decompressing a gzip
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 gzip after the decompression is complete.

Comment 1 Josh Bressers 2005-04-22 14:21:03 EDT
This issue should also affect RHEL2.1 and RHEL3.
Comment 2 Josh Bressers 2005-04-29 09:59:33 EDT
Created attachment 113841 [details]
Proposed patch from Steve Grubb
Comment 3 Ivana Varekova 2005-05-03 05:46:47 EDT
The new versions (gzip-1.3.3-11.rhel3, gzip-1.3.3-15.rhel4, gzip-1.3-17.rhel2)
Ivana Varekova
Comment 4 Petter Reinholdtsen 2005-05-20 12:18:37 EDT
This bug has been reported into Debian BTS too.  There, a different
patch is suggested to solve the problem.  The debian patch is a lot
shorter.  Have a look at <URL: http://bugs.debian.org/305255 >.
(Just mentioning it, to give you information about another approach.)
Comment 5 Petter Reinholdtsen 2005-05-20 12:58:33 EDT
I was just confused.  The debian bug I posted is for CAN-2005-1228, and not
this bug.  The currect debian bug for CAN-2005-0988 is #303927.
Comment 6 Josh Bressers 2005-06-13 08:12:58 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

Comment 7 Derek T. Yarnell 2005-11-30 13:09:59 EST
This has to be re-opened.  This patch has produced a bug in gzip files over NFS.  The problem crops up 
with the fchmod hanging for a long time and pushing rpciod load through the roof.  Sometimes the gzip 
finishes and sometimes it doesn't.  I can produce the file that hangs the machine (1.2gig file, 
decompresses into 3gig file) please contact derek@umiacs.umd.edu.

I have tested this with the Suse unpatched version of this and since it closes the file first then runs chmod 
it does not hang indefinitely.

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