This service will be undergoing maintenance at 20:00 UTC, 2017-04-03. It is expected to last about 30 minutes
Bug 425921 - (CVE-2007-6353) CVE-2007-6353 exiv2: integer overflow in EXIF parsing
CVE-2007-6353 exiv2: integer overflow in EXIF parsing
Status: CLOSED ERRATA
Product: Security Response
Classification: Other
Component: vulnerability (Show other bugs)
unspecified
All Linux
medium Severity medium
: ---
: ---
Assigned To: Red Hat Product Security
http://nvd.nist.gov/nvd.cfm?cvename=C...
: Patch, Security
Depends On: 425922 425923 425924 425993 426001
Blocks:
  Show dependency treegraph
 
Reported: 2007-12-17 04:07 EST by Tomas Hoger
Modified: 2007-12-20 15:14 EST (History)
1 user (show)

See Also:
Fixed In Version: 0.15-5.fc7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-12-20 15:10:42 EST
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 Tomas Hoger 2007-12-17 04:07:12 EST
Meder Kydyraliev reported an integer overflow exiv2's EXIF parsing code
resulting in heap buffer oveflow.  This can possibly lead to code execution as
user running application using exiv2 library to extract EXIF tags from
malicious image files.

Upstream commit:
http://dev.robotbattle.com/~cvsuser/cgi-bin/ns_viewcvs.cgi/exiv2/trunk/src/exif.cpp?rev=1346&r1=1231&r2=1346
Comment 1 Rex Dieter 2007-12-17 09:32:12 EST
This is (apparently, can't see it yet), the upstream issue tracker:
http://dev.robotbattle.com/bugs/view.php?id=534
Comment 2 Tomas Hoger 2007-12-17 09:49:56 EST
(In reply to comment #1)
> http://dev.robotbattle.com/bugs/view.php?id=534

Yes it is.  That report was first opened as public and it also contained further
details about similar problems in other EXIF parsing libraries (see e.g. our
bugs #425551 and #425561 for libexif).


Comment 3 Tomas Hoger 2007-12-17 09:52:36 EST
Gentoo bug states that exiv2 did not compile because of incorrect static casts
used in the upstream patch.  They've added extra correction:

diff -u exiv2-0.13/src/exif.cpp exiv2-0.13/src/exif.cpp
--- exiv2-0.13/src/exif.cpp
+++ exiv2-0.13/src/exif.cpp
@@ -244,7 +244,7 @@
             uint32_t size = sizes->toLong(i);
             lastSize = size;
             if (   size > 0xffffffff - offset
-                || static_cast(len) < offset + size) {
+                || static_cast<uint32_t>(len) < offset + size) {
                 return 2;
             }
             memcpy(stripsBuf.pData_ + currentOffset, buf + offset, size);
@@ -313,7 +313,7 @@
         if (length == exifData.end()) return 1;
         uint32_t size = length->toLong();
         if (   size > 0xffffffff - offset
-            || static_cast(len) < offset + size) {
+            || static_cast<uint32_t>(len) < offset + size) {
             return 2;
         }
         format->setDataArea(buf + offset, size);

http://bugs.gentoo.org/show_bug.cgi?id=202351
Comment 4 Rex Dieter 2007-12-17 11:40:36 EST
Thanks.
Comment 5 Fedora Update System 2007-12-20 15:10:40 EST
exiv2-0.15-5.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 6 Fedora Update System 2007-12-20 15:14:41 EST
exiv2-0.15-5.fc8 has been pushed to the Fedora 8 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.