Bug 1191080 (CVE-2014-9658) - CVE-2014-9658 freetype: buffer over-read and integer underflow in tt_face_load_kern()
Summary: CVE-2014-9658 freetype: buffer over-read and integer underflow in tt_face_loa...
Alias: CVE-2014-9658
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
Depends On: 1191099 1197737 1197738 1197739 1197740
Blocks: 1191102
TreeView+ depends on / blocked
Reported: 2015-02-10 12:50 UTC by Vasyl Kaigorodov
Modified: 2019-09-29 13:27 UTC (History)
4 users (show)

Fixed In Version: freetype 2.5.4
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2015-03-18 07:41:00 UTC

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:0696 0 normal SHIPPED_LIVE Important: freetype security update 2015-03-17 21:58:07 UTC

Description Vasyl Kaigorodov 2015-02-10 12:50:17 UTC
Common Vulnerabilities and Exposures assigned CVE-2014-9658 to the following issue:

The tt_face_load_kern function in sfnt/ttkern.c in FreeType before 2.5.4
enforces an incorrect minimum table length, which allows remote attackers to
cause a denial of service (out-of-bounds read) or possibly have unspecified
other impact via a crafted TrueType font.


Comment 1 Vasyl Kaigorodov 2015-02-10 12:55:29 UTC
Created freetype tracking bugs for this issue:

Affects: fedora-all [bug 1191099]

Comment 2 Fedora Update System 2015-02-19 18:01:12 UTC
freetype-2.5.3-15.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 3 Tomas Hoger 2015-02-19 20:58:29 UTC
Upstream bug is:


Issue was fixed upstream in 2.5.4.

The issue here starts as a simple short buffer over-read.  Existing check to ensure enough input data is still available was incorrect:


The length <= 6 only takes into account the previously read header:


p is later incremented by 8 (but only the first two bytes are actually read/accessed):


However, when length is too short, p_next may be less than p, which leads to integer underflow in (p_next - p) in this num_pairs check:


The check aims to prevent further over-reads.  Underflow bypasses the check and makes it possible to read 6 * 0xffff bytes (num_pairs is short).  Crash should be possible.

Comment 5 Fedora Update System 2015-02-20 08:30:41 UTC
freetype-2.5.0-9.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 7 errata-xmlrpc 2015-03-17 17:58:53 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6
  Red Hat Enterprise Linux 7

Via RHSA-2015:0696 https://rhn.redhat.com/errata/RHSA-2015-0696.html

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