Bug 438188 - Expression improperly cast to off64_t in elf_getdata_chunk
Expression improperly cast to off64_t in elf_getdata_chunk
Status: CLOSED INSUFFICIENT_DATA
Product: Fedora
Classification: Fedora
Component: elfutils (Show other bugs)
9
All Linux
medium Severity medium
: ---
: ---
Assigned To: Roland McGrath
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-03-19 12:30 EDT by Tim Moore
Modified: 2008-08-02 19:40 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-06-07 20:26:38 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Tim Moore 2008-03-19 12:30:58 EDT
Description of problem:
In elf_getdata_chunk, the epression:
  if (unlikely (size > elf->maximum_size
		|| (off64_t)(elf->maximum_size - size) < offset))
    {

loses on 64 bit machines because elf->maximum_size is a large 64 bit unsigned
value.

The fix is to cast both sides of the comparison to a 64 bit unsigned type:

  if (unlikely (size > elf->maximum_size
		|| (uint64_t)(elf->maximum_size - size) < (uint64_t)offset))
    {

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

elfutils-0.133

How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:
Comment 1 Roland McGrath 2008-03-19 13:57:18 EDT
This report has no test case.
Comment 2 Bug Zapper 2008-05-14 02:43:50 EDT
Changing version to '9' as part of upcoming Fedora 9 GA.
More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 3 Brennan Ashton 2008-06-07 20:26:38 EDT
Since there are insufficient details provided in this report for us to
investigate the issue further, and we have not received feedback to the
information we have requested above, we will assume the problem was not
reproducible, or has been fixed in one of the updates we have released for the
reporter's distribution.

Users who have experienced this problem are encouraged to upgrade to the latest
update of their distribution, and if this issue turns out to still be
reproducible in the latest update, please reopen this bug with additional
information.

Closing as INSUFFICIENT_DATA.

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