Bug 861358 - fuseiso: integer overflow in isofs_real_read_zf
fuseiso: integer overflow in isofs_real_read_zf
Status: NEW
Product: Fedora
Classification: Fedora
Component: fuseiso (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Orphan Owner
Fedora Extras Quality Assurance
: Reopened, Security
Depends On:
Blocks: 861356 CVE-2015-8836
  Show dependency treegraph
Reported: 2012-09-28 06:37 EDT by Florian Weimer
Modified: 2016-12-21 03:13 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-12-20 07:26:59 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
zf-overflow.iso.gz (1016 bytes, application/octet-stream)
2015-10-01 05:30 EDT, Florian Weimer
no flags Details
Check for block size being << 2^17, if block size is exceeded, bail out (594 bytes, patch)
2015-10-01 05:32 EDT, Mike Gabriel
no flags Details | Diff

  None (edit)
Description Florian Weimer 2012-09-28 06:37:56 EDT
In the isofs_real_read_zf function in src/isofs.c, the initialization

    int zf_block_size = 1 << inode->zf_block_shift;

suffers from an integer overflow.  This triggers undefined behavior.  I believe that on i686 and x86_64, the subsequent malloc cannot be reached, but I'm not sure about other architectures.

The isofs kernel module rejects zf_block_shift values greater than 17, and fuseiso should probably do the same.
Comment 1 Florian Weimer 2012-09-28 06:55:26 EDT
Reproducer is available upon request (zf-overflow.iso).
Comment 2 Florian Weimer 2012-10-02 09:41:40 EDT
(In reply to comment #1)
> Reproducer is available upon request (zf-overflow.iso).

To trigger this, a program has to attempt to open and read the "zeros" file in the ISO image.
Comment 5 Fedora Admin XMLRPC Client 2015-03-30 16:13:57 EDT
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.
Comment 6 Jan Kurik 2015-07-15 10:58:59 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 23 development cycle.
Changing version to '23'.

(As we did not run this process for some time, it could affect also pre-Fedora 23 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 23 End Of Life. Thank you.)

More information and reason for this action is here:
Comment 7 Mike Gabriel 2015-10-01 04:10:57 EDT
(In reply to Florian Weimer from comment #1)
> Reproducer is available upon request (zf-overflow.iso).

I have prepared a patch for this fix and would like to test if it works. Can you please provide me with the above named zf-overflow.iso?

Comment 8 Florian Weimer 2015-10-01 05:30 EDT
Created attachment 1078999 [details]

Comment 9 Mike Gabriel 2015-10-01 05:32 EDT
Created attachment 1079000 [details]
Check for block size being << 2^17, if block size is exceeded, bail out
Comment 10 Fedora End Of Life 2016-11-24 05:49:21 EST
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '23'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 23 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 11 Fedora End Of Life 2016-12-20 07:26:59 EST
Fedora 23 changed to end-of-life (EOL) status on 2016-12-20. Fedora 23 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this

Thank you for reporting this bug and we are sorry it could not be fixed.

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