CVE-2008-1373: CUPS GIF image filter overflow

Bug #210718 reported by Martin Pitt
254
Affects Status Importance Assigned to Milestone
cupsys (Fedora)
Fix Released
Medium
cupsys (Gentoo Linux)
Fix Released
High
cupsys (Ubuntu)
Fix Released
High
Martin Pitt
Dapper
Fix Released
Undecided
Jamie Strandboge
Edgy
Fix Released
Undecided
Jamie Strandboge
Feisty
Fix Released
Undecided
Jamie Strandboge
Gutsy
Fix Released
Undecided
Jamie Strandboge
Hardy
Fix Released
High
Martin Pitt

Bug Description

Binary package hint: cupsys

cupsys 1.3.7 fixes a security vulnerability in cupsd, which applies to stables as well. Please see http://www.cups.org/str.php?L2765 for details and the patch.

Revision history for this message
In , Tomas (tomas-redhat-bugs) wrote :

It was discovered that GIF parsing code used by CUPS printing system is affected
by similar issue as GIF parsers used by gd / netpbm / tk / SDL_image.

Value of code_size read from GIF image is not properly validate before being
used to initialize table array in gif_read_lzw(), causing a static buffer overflow.

Issue is similar to:
CVE-2006-4484 (gd), CVE-2007-6697 (SDL_image), CVE-2008-0553 (tk), CVE-2008-0554
(netpbm)

Revision history for this message
In , Tomas (tomas-redhat-bugs) wrote :

Created attachment 298680
Proposed patch

Similar to fixed used in gd / tk / netpbm / SDL_image.

Revision history for this message
In , Tomas (tomas-redhat-bugs) wrote :

Tracked upstream via: http://www.cups.org/str.php?L2765

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Tomas Hoger writes:
Value of code_size is read from GIF image, but not properly validated
before use to initialize table array in gif_read_lzw(). clear_code
used as upper bound in for loop is short, hence overflow is limited to
~16k - 4k short int values. Moreover, attacker has limited control
over the values written past the end of the buffer.

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Timo, this issue is under embargo until 2008-03-26. Do not commit anything to CVS until this date. Please prepare an updated ebuild and attach it to this bug, we will do prestable testing here. Thanks.

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Created attachment 146667
cups-1.2.12-CVE-2008-1373.patch

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Created attachment 146668
cups-1.3.6-CVE-2008-1373.patch

Revision history for this message
In , tgurr (tgurr-gentoo-bugs) wrote :

Created attachment 146714
cups-1.2.12-r7.ebuild

Added the patch for CVE-2008-1373 and also removed the unneeded (as also discussed per mail and with upstream) patch for CVE-2007-4045.

Revision history for this message
In , tgurr (tgurr-gentoo-bugs) wrote :

Created attachment 146721
cups-1.3.6-r3.ebuild

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Arch Security Liaisons, please test the attached ebuild and report it stable on this bug.
Target keywords : "alpha amd64 arm hppa ia64 m68k ppc ppc64 release s390 sh sparc x86"

CC'ing current Liaisons:
   alpha : ferdy
   amd64 : welp
    hppa : jer
     ppc : dertobi123
   ppc64 : corsair
 release : pva
   sparc : fmccor
     x86 : opfer

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

(In reply to comment #6)
> Arch Security Liaisons, please test the attached ebuild and report it stable on
> this bug.

That is:
=net-print/cups-1.2.12-r7

Revision history for this message
In , fauli (fauli-gentoo-bugs) wrote :

Good to go on x86

Revision history for this message
In , fmccor (fmccor-gentoo-bugs) wrote :

Looks good on sparc. Tested -1.2.12-r7, remote only, with {.ps, .pdf} files.

Revision history for this message
In , jer (jer-gentoo-bugs) wrote :

HPPA is OK.

Revision history for this message
In , corsair (corsair-gentoo-bugs) wrote :

looks good on ppc64

Revision history for this message
In , dertobi123 (dertobi123-gentoo-bugs) wrote :

looks good on ppc

Revision history for this message
In , armin76 (armin76-gentoo-bugs) wrote :

Adding Tobias for alpha

Revision history for this message
In , klausman (klausman-gentoo-bugs) wrote :

=net-print/cups-1.2.12-r7 works dandy on alpha.

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Created attachment 147078
cups-1.2.12-CVE-2008-0053.patch

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Created attachment 147080
cups-1.2.12-r7.ebuild

Ok, cups is killing me these days. Could you please retest with the new -r7 ebuild? Thanks.

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

CVE-2008-0053 (http://nvd.nist.gov/nvd.cfm?cvename=CVE-2008-0053):
  Unspecified vulnerability in CUPS before 1.3.6 in Apple Mac OS X 10.5.2 has
  unknown impact and attack vectors related to "input validation."

Apple Advisory:
http://lists.apple.com/archives/security-announce/2008/Mar/msg00001.html

Impact: Multiple vulnerabilities in CUPS may lead to an unexpected
application termination or arbitrary code execution with system
privileges
Description: Multiple input validation issues exist in CUPS, the
most serious of which may lead to arbitrary code execution with
system privileges. This update addresses the issues by updating to
CUPS 1.3.6. These issues do not affect systems prior to Mac OS X
v10.5.

Tomas Hoger writes:
According to upstream, this CVE id was allocated for following issue fixed in
CUPS 1.3.6 (see CHANGES.txt):

- Fixed two overflow bugs in the HP-GL/2 filter (Coverity)

Revision history for this message
In , fauli (fauli-gentoo-bugs) wrote :

Local printing ....ok
Remote printing from
  Windows ...ok
  Linux ...ok

x86 good to go...again.

Revision history for this message
In , fmccor (fmccor-gentoo-bugs) wrote :

sparc still looks good, too, as described in Comment 9.

Revision history for this message
In , corsair (corsair-gentoo-bugs) wrote :

looks good on ppc64, too.

Revision history for this message
In , jer (jer-gentoo-bugs) wrote :

HPPA is OK again.

Revision history for this message
In , klausman (klausman-gentoo-bugs) wrote :

And on alpha, it works, too.

Revision history for this message
In , dertobi123 (dertobi123-gentoo-bugs) wrote :

still looks good for ppc

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Please note that the embargo has been delayed until Monday, 03/31.

Revision history for this message
In , corsair (corsair-gentoo-bugs) wrote :

looks good on ppc64

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

(In reply to comment #24)
> Please note that the embargo has been delayed until Monday, 03/31.

.... and again, Tuesday it is.

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

This is public now. Printing, please commit with the keywords you gathered.

Revision history for this message
In , Fedora (fedora-redhat-bugs) wrote :

cups-1.2.12-10.fc7 has been submitted as an update for Fedora 7

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

Arches, please test and mark stable:
=net-print/cups-1.2.12-r7
Target keywords : "alpha amd64 arm hppa ia64 m68k ppc ppc64 release s390 sh sparc x86"
Already stabled : "alpha amd64 hppa ppc ppc64 sparc x86"
Missing keywords: "arm ia64 m68k release s390 sh"

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

1.3.6 is unaffected for CVE-2008-0053.

This is GLSA-200804-01 - no joke!

Revision history for this message
Martin Pitt (pitti) wrote :

Preparing Hardy upload ATM.

Changed in cupsys:
assignee: nobody → pitti
importance: Undecided → High
status: New → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package cupsys - 1.3.7-1ubuntu1

---------------
cupsys (1.3.7-1ubuntu1) hardy; urgency=low

  * Merge new upstream bug fix release from unstable.
    - Fixes CUPS GIF image filter overflow [CVE-2008-1373]. (LP: #210718)

cupsys (1.3.7-1) unstable; urgency=medium

  * Urgency medium due to security fix.
  * New upstream bugfix/security update release. For a detailled list of
    changes see http://www.cups.org/articles.php?L537.
    - CUPS GIF image filter overflow [CVE-2008-1373, STR #2765].
  * Drop patches which are now upstream:
    - cgiCompileSearch_buffer_overflow.dpatch
    - testsuite-exit-code.dpatch
    - pbmprint.dpatch
  * search_mime_files_in_usr_share.dpatch: Drop log message about missing
    /usr/share/cups/mime/ from error to info, since it is not really an
    error, and causing the test suite to fail due to error log count mismatch.
  * pdftops-cups-1.4.dpatch: Apply r7391 from SVN head to fix missing error
    message newlines (STR #2743).
  * debian/rules: Remove cleaning of test suite HTML reports in test/, they
    are written to /tmp now.
  * Add pdftops-wait-eintr.dpatch: Handle EINTR in pdftops' wait() call.
    (Caught by test suite.)
  * debian/libcupsys2-dev.files: Drop i18n.h, it's an internal interface and
    not installed by upstream any more.
  * debian/control: Add poppler-utils | xpdf-utils build dependency, so that
    the test suite works during build.

 -- Martin Pitt <email address hidden> Wed, 02 Apr 2008 11:16:39 +0200

Changed in cupsys:
status: Fix Committed → Fix Released
Revision history for this message
In , pva (pva-gentoo-bugs) wrote :

Stable on ia64 by armin76.
Fixed in release snapshot.

Revision history for this message
In , rbu (rbu-gentoo-bugs) wrote :

*** Bug 215863 has been marked as a duplicate of this bug. ***

Changed in cupsys:
status: Unknown → Fix Released
Changed in cupsys:
status: Unknown → Invalid
Changed in cupsys:
assignee: nobody → jamie-strandboge
status: New → Fix Committed
assignee: nobody → jamie-strandboge
status: New → Fix Committed
assignee: nobody → jamie-strandboge
status: New → Fix Committed
assignee: nobody → jamie-strandboge
status: New → Fix Committed
Revision history for this message
Jamie Strandboge (jdstrand) wrote :
Changed in cupsys:
status: Fix Committed → Fix Released
status: Fix Committed → Fix Released
status: Fix Committed → Fix Released
status: Fix Committed → Fix Released
Revision history for this message
In , Fedora (fedora-redhat-bugs) wrote :

cups-1.3.6-4.fc8 has been pushed to the Fedora 8 stable repository. If problems still persist, please make note of it in this bug report.

Revision history for this message
In , Fedora (fedora-redhat-bugs) wrote :

cups-1.2.12-10.fc7 has been pushed to the Fedora 7 stable repository. If problems still persist, please make note of it in this bug report.

Revision history for this message
In , Red (red-redhat-bugs) wrote :
Changed in cupsys:
status: Invalid → Fix Released
Changed in cupsys (Gentoo Linux):
importance: Unknown → High
Changed in cupsys (Fedora):
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public Security information  
Everyone can see this security related information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.