Bug 666793 (CVE-2010-4540)

Summary: CVE-2010-4540 Gimp: Stack-based buffer overflow in Lighting plug-in
Product: [Other] Security Response Reporter: Huzaifa S. Sidhpurwala <huzaifas>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: jlieskov, mjc, nphilipp, underling, vdanen, vkrizan
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard: public=20101231,reported=20101231,source=debian,impact=moderate,cvss2=5.1/AV:N/AC:H/Au:N/C:P/I:P/A:P,rhel-4/gimp=notaffected,rhel-5/gimp=affected,rhel-6/gimp=affected,fedora-all/gimp=affected,cwe=CWE-121[auto]
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-07-29 09:34:54 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On: 537810, 537811, 703803, 703804, 706939, 833903    
Bug Blocks:    

Description Huzaifa S. Sidhpurwala 2011-01-03 03:40:30 EST
Several stack-based buffer overflows were found in the way gimp
processes plug-in configuration files. An attacker could create a
a specially-crafted plug-in configuration file and trick the local, 
unsuspecting user into opening it, which could lead to gimp to crash
the plugin or, potentially , arbitrary code execution with
the privileges of the user running the executable.

Reference:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=608497

Public PoC:
http://bugs.debian.org/cgi-bin/bugreport.cgi?msg=5;filename=gimp-overflows-poc-in-cobol.cob;att=1;bug=608497

Flaw severity note:
On systems with compile time buffer checks (FORTIFY_SOURCE)
feature enabled, the impact of this flaw is mitigated to
be only crash.
Comment 2 Vincent Danen 2011-01-04 13:40:34 EST
There are four buffer overflows here and as a result this has been given four CVE names:

http://article.gmane.org/gmane.comp.security.oss.general/4025

CVE-2010-4540 gimp LIGHTING EFFECTS > LIGHT plugin stack buffer overflow
CVE-2010-4541 gimp SPHERE DESIGNER plugin stack buffer overflow
CVE-2010-4542 gimp GFIG plugin stack buffer overflow
CVE-2010-4543 gimp heap overflow read_channel_data() in file-psp.c

If we need to, we can split these into separate bugs (but I think that when we fix them, we would do them all at once, so only split this if any of these don't affect something we ship).
Comment 3 Jan Lieskovsky 2011-05-10 05:49:25 EDT
(In reply to comment #2)
> There are four buffer overflows here and as a result this has been given four
> CVE names:
> 
> http://article.gmane.org/gmane.comp.security.oss.general/4025
> 
> CVE-2010-4540 gimp LIGHTING EFFECTS > LIGHT plugin stack buffer overflow
> CVE-2010-4541 gimp SPHERE DESIGNER plugin stack buffer overflow
> CVE-2010-4542 gimp GFIG plugin stack buffer overflow
> CVE-2010-4543 gimp heap overflow read_channel_data() in file-psp.c
> 
> If we need to, we can split these into separate bugs (but I think that when we
> fix them, we would do them all at once, so only split this if any of these
> don't affect something we ship).

This bug is now dedicated to CVE-2010-4540 issue:
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2010-4540

Stack-based buffer overflow in the load_preset_response function
in plug-ins/lighting/lighting-ui.c in the "LIGHTING EFFECTS > LIGHT"
plugin in GIMP 2.6.11 allows user-assisted remote attackers to cause
a denial of service (application crash) or possibly execute arbitrary
code via a long Position field in a plugin configuration file. NOTE:
it may be uncommon to obtain a GIMP plugin configuration file from
an untrusted source that is separate from the distribution of the
plugin itself. NOTE: some of these details are obtained from third
party information. 

References:
[1] http://openwall.com/lists/oss-security/2011/01/03/2
[2] http://openwall.com/lists/oss-security/2011/01/04/7
[3] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=608497
[4] https://bugzilla.redhat.com/show_bug.cgi?id=666793
[5] http://osvdb.org/70282
[6] http://secunia.com/advisories/42771
[7] http://www.vupen.com/english/advisories/2011/0016
[8] http://xforce.iss.net/xforce/xfdb/64582

For further information about the CVE-2010-4541 issue please have a look at:
[9] https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2010-4541

For further information about the CVE-2010-4542 issue please have a look at:
[10] https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2010-4542

And finally, for further information about the CVE-2010-4543 issue please
have a look at:
[11] https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2010-4543
Comment 4 Jan Lieskovsky 2011-05-10 05:57:48 EDT
The CVE-2010-4540 issue affects the versions of the gimp package,
as shipped with Red Hat Enterprise Linux 5 and 6.

--

The CVE-2010-4540 issue affects the versions of the gimp package,
as shipped with Fedora release of 13 and 14.
Comment 7 Jan Lieskovsky 2011-05-23 10:39:43 EDT
Created gimp tracking bugs for this issue

Affects: fedora-all [bug 706939]
Comment 8 Jan Lieskovsky 2011-05-23 10:42:07 EDT
Created gimp tracking bugs for this issue

Affects: fedora-all [bug 706939]
Comment 9 errata-xmlrpc 2011-05-31 09:54:02 EDT
This issue has been addressed in following products:

  Red Hat Enterprise Linux 6

Via RHSA-2011:0839 https://rhn.redhat.com/errata/RHSA-2011-0839.html
Comment 10 errata-xmlrpc 2011-05-31 10:05:04 EDT
This issue has been addressed in following products:

  Red Hat Enterprise Linux 5

Via RHSA-2011:0838 https://rhn.redhat.com/errata/RHSA-2011-0838.html