Bug 251674 (CVE-2007-2956) - CVE-2007-2956 Buffer overflow triggerable by crafted .hdr file
Summary: CVE-2007-2956 Buffer overflow triggerable by crafted .hdr file
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2007-2956
Product: Fedora
Classification: Fedora
Component: qtpfsgui
Version: 6
Hardware: All
OS: Linux
high
high
Target Milestone: ---
Assignee: Douglas E. Warner
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-08-10 11:34 UTC by Lubomir Kundrak
Modified: 2007-11-30 22:12 UTC (History)
0 users

Fixed In Version: 1.8.12-1.fc7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-08-13 17:05:41 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Lubomir Kundrak 2007-08-10 11:34:08 UTC
Description of problem:

Stefan Cornelius of Secunia discovered the following flaw:

Credit: Stefan Cornelius, Secunia Research
Upstream contacted: CCed to this email.
Disclosure date: As soon as the vendor releases a patch, or 22-08-2007.
Note that this may be changed if vendors or this list request it. 


-- Background --

Qtpfsgui:
"Qtpfsgui is an open source graphical user interface application that
aims to provide a workflow for HDR imaging."

pfstools:
"pfstools package is a set of command line (and one GUI) programs for
reading, writing, manipulating and viewing high-dynamic range (HDR) images
and video frames."

-- Details --

There is a boundary error in Qtpfsgui and pfstools when reading the
header of a Radiance RGBE (*.hdr) file within the "readRadianceHeader()"
function in src/fileformat/rgbeio.cpp (Qtpfsgui) or 
src/Fileformat/rgbeio.cpp (pfstools). 

---

  // image size
  char xbuf[4], ybuf[4];   [1]
  int rez = fscanf(file, "%s %d %s %d\n", ybuf, &height, xbuf, &width);
[2]
  if( rez!=4 ) [3] 
  {
    throw pfs::Exception( "RGBE: unknown image size" );
  }

---

[1] Allocate space on the stack
[2] Read in data from the file without limiting the size
[3] Check return value of fscanf() and continue execution

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

        Affects: FC7

Additional info:

This went public before disclosure date proposed by Secuina, as it was
publically commited into pfstools CVS [1] and Secunia agrees with calling this
public.

[1]
http://pfstools.cvs.sourceforge.net/pfstools/pfstools/src/fileformat/rgbeio.cpp?r1=1.8&r2=1.9

Comment 1 Lubomir Kundrak 2007-08-13 09:01:45 UTC
silfreed has submitted a new update for Fedora 7

================================================================================
  qtpfsgui-1.8.12-1.fc7
================================================================================
    Release: Fedora 7
     Status: pending
       Type: security
       Bugs: 251674 - CVE-2007-2956 Buffer overflow triggerable by crafted .hdr file
       CVEs: 2007-2956
  Submitter: silfreed
  Submitted: 2007-08-12 06:07:51

Comment 2 Fedora Update System 2007-08-13 17:05:35 UTC
qtpfsgui-1.8.12-1.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.


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