Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 219033 - media-gfx/pngcrush <1.6.4-r1 includes libpng with memory overwrite vulnerability (CVE-2008-1382)
Summary: media-gfx/pngcrush <1.6.4-r1 includes libpng with memory overwrite vulnerabil...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Security
Classification: Unclassified
Component: Vulnerabilities (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: Gentoo Security
URL: http://libpng.sourceforge.net/Advisor...
Whiteboard: B2 [glsa]
Keywords:
Depends on:
Blocks:
 
Reported: 2008-04-23 14:24 UTC by Christian Hoffmann (RETIRED)
Modified: 2008-05-11 21:48 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Hoffmann (RETIRED) gentoo-dev 2008-04-23 14:24:50 UTC
media-gfx/pngcrush bundles a slightly modified libpng (version libpng-1.2.9rc1 in case of pngcrush-1.6.4) and is as such vulnerable to CVE-2008-1382, as noted explicitly in the libpng advisory (user _mika submitted the link yesterday in #gentoo-security, so I took a look).

We already have the latest pngcrush version in the tree (1.6.4 from June 2006), so one either has to upgrade the bundled libpng or switch to using the external one (which is, according to the upstream homepage, possible, but possibly has some drawbacks; I have not tried to test it myself).

For properly rating this vulnerability, we'd probably have to check if other libpng vulnerabilities were discovered after libpng-1.2.9rc1 and affected pngcrush as such.

drac already said he'd have a look today.


(The advisory also mentions imagemagick, but in our case it uses the system libpng (dynamically loaded, not linked), so it should be fine).

The original libpng issue was handled in bug 217047.
Comment 1 Christian Hoffmann (RETIRED) gentoo-dev 2008-04-23 14:32:04 UTC
Yet another attempt at setting whiteboard (security, let me know if it annoys you more than it helps :p).
B as pngcrush is certainly not that common, 2 since it allows for (controlled?) memory overwrite. Setting [ebuild] as it is very unlikely that upstream releases something after two years of inactivity and as the easiest way to solve it is probably using the system libpng (and maybe zlib as well, while we are at it?).
Comment 2 Samuli Suominen (RETIRED) gentoo-dev 2008-04-23 15:49:13 UTC
*pngcrush-1.6.4-r1 (23 Apr 2008)

  23 Apr 2008; Samuli Suominen <drac@gentoo.org>
  +files/pngcrush-1.6.4-modified-debian-patchset-5.patch,
  +pngcrush-1.6.4-r1.ebuild:
  Stop including vulnerable libpng, and use system libpng instead. Debian
  mirrors a tarball with included libpng files deleted, so we are using that
  one applying Debian patchset -5 on top of it. After that we fix the
  remaining issues from Makefile. Thanks to _mika and hoffie from 
  #gentoo-security at Freenode.
Comment 3 Samuli Suominen (RETIRED) gentoo-dev 2008-04-23 15:56:33 UTC
(In reply to comment #2)
> *pngcrush-1.6.4-r1 (23 Apr 2008)
> 
>   23 Apr 2008; Samuli Suominen <drac@gentoo.org>
>   +files/pngcrush-1.6.4-modified-debian-patchset-5.patch,
>   +pngcrush-1.6.4-r1.ebuild:
>   Stop including vulnerable libpng, and use system libpng instead. Debian
>   mirrors a tarball with included libpng files deleted, so we are using that
>   one applying Debian patchset -5 on top of it. After that we fix the
>   remaining issues from Makefile. Thanks to _mika and hoffie from 
>   #gentoo-security at Freenode.

bleah that looked fugly plus we have this bug, 

*pngcrush-1.6.4-r1 (23 Apr 2008)

  23 Apr 2008; Samuli Suominen <drac@gentoo.org>
  +files/pngcrush-1.6.4-modified-debian-patchset-5.patch,
  +pngcrush-1.6.4-r1.ebuild:
  Use system libpng wrt security #219033, thanks to _mika and hoffie.
  Using modified Debian patchset -5.

> 

Comment 4 Robert Buchholz (RETIRED) gentoo-dev 2008-04-23 16:04:28 UTC
Arches, please test and mark stable:
=media-gfx/pngcrush-1.6.4-r1
Target keywords : "amd64 ppc release x86"
Comment 5 Samuli Suominen (RETIRED) gentoo-dev 2008-04-23 18:57:48 UTC
amd64 stable, thanks to gentoofan23 for testing
Comment 6 Markus Meier gentoo-dev 2008-04-23 21:13:39 UTC
x86 stable
Comment 7 Tobias Scherbaum (RETIRED) gentoo-dev 2008-04-24 19:07:40 UTC
ppc stable
Comment 8 Peter Volkov (RETIRED) gentoo-dev 2008-04-26 09:34:52 UTC
Fixed in release snapshot.
Comment 9 Pierre-Yves Rofes (RETIRED) gentoo-dev 2008-05-05 21:29:25 UTC
glsa request filed
Comment 10 Pierre-Yves Rofes (RETIRED) gentoo-dev 2008-05-11 21:48:04 UTC
GLSA 200805-10