Bug 116967

Summary: 'gzip -l' has integer overflow problem
Product: Red Hat Enterprise Linux 3 Reporter: Ian Soboroff <isoboroff>
Component: gzipAssignee: Tomas Mraz <tmraz>
Status: CLOSED WONTFIX QA Contact: Ben Levenson <benl>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0CC: hannes.kuehnemund, jkienlen
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-03-22 12:30:31 EST Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Ian Soboroff 2004-02-26 16:58:47 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040113

Description of problem:
Running 'gzip -l' to see the uncompressed size of a very large
compressed file results in integer overflows:

$ ls -gG data.1075704784.gz
-rw-r--r--    1 5256727374 Feb  2 04:12 data.1075704784.gz

$ gzip -l data.1075704784.gz
         compressed        uncompressed  ratio uncompressed_name
         5256727374          1921117289 -173.6% data.1075704784

$ gunzip data.1075704784.gz

$ ls -gG data.1075704784
-rw-r--r--    1 6216084585 Feb 26 15:11 data.1075704784

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
See description.  I can't send you the file in question, but it seems
to work for any file of comparable size (about 5 or 6GB uncompressed).

Actual Results:  See desc

Expected Results:  See desc

Additional info:
Comment 1 Tomas Mraz 2005-03-22 08:47:20 EST
*** Bug 145490 has been marked as a duplicate of this bug. ***
Comment 2 Tomas Mraz 2005-03-22 12:30:31 EST
The problem is the gzip format stores the uncompressed file size in 32 bits only
so it isn't possible to display correct uncompressed file size for large files
in the gzip -l command.

See man gzip section BUGS.
Comment 3 Ivana Varekova 2008-05-06 09:14:26 EDT
*** Bug 443605 has been marked as a duplicate of this bug. ***