Skip to content
Disclosed report CVE-2011-0058

Buffer size calculation failure when running an absurdly long and complex text run

Alex Miller Follow

Originally disclosed on Mozilla

  • Fixed in 36 days
  • Paid in 2.7 years
  • Disclosed after 36 days
Text
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.11) Gecko/20101012 Firefox/3.6.11
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.11) Gecko/20101012 Firefox/3.6.11

When creating a 2684354575-character long text run, containing many complex unicode characters and its font-weight property is 65537, inside a <div> that is 3px wide, the buffer size for a text run is incorrectly calculated. In my tests, I found that the program exits safely, but an attacker could leverage an incorrectly calculated buffer size to run arbitrary code.

Reproducible: Always

Steps to Reproduce:
1. View the testcase.
Actual Results:  
A sustained period of hanging, followed by a "Microsoft C++ Runtime" exception.

Expected Results:  
It should have just been a DOS.

This was only tested against Windows 7 Home Edition. View the attached stack trace for proof of an incorrectly calculated buffer.

The original report as published on Mozilla's Bugzilla, by Alex Miller. Images and videos are our own copies; raw HTML is shown as text. View it on Mozilla's Bugzilla.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

What is known

A security bug in Layout: Text and Fonts. Mozilla made it public on 30 November 2010 as CVE-2011-0058.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.