bugThe FreeType Project - Bugs: bug #24953, Parsing CFF real with more then 9...

 
 

bug #24953: Parsing CFF real with more then 9 significant digits crashes

Submitted by:  bram tassyns <bramt>
Submitted on:  Thu 27 Nov 2008 12:59:14 PM UTC  
 
Severity: 3 - NormalItem Group: Crash
Status: FixedPrivacy: Public
Assigned to: Werner LEMBERG <wl>Open/Closed: Closed
Planned Release: 2.3.8

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Thu 27 Nov 2008 09:56:44 PM UTC, comment #1:

This is now fixed in the CVS. Thanks for the report; please test.

[Note that your patch was incorrect.]

Werner LEMBERG <wl>
Project AdministratorIn charge of this item.
Thu 27 Nov 2008 12:59:14 PM UTC, original submission:

sample font file is attached
fix (cffparse.c: 359):

static FT_Fixed
cff_parse_real( FT_Byte* start,
FT_Byte* limit,
FT_Int power_ten,
FT_Int* scaling )
{
...
if ( fraction_length > 0 )
{
if ( fraction_length >= 10
|| ( number / power_tens[fraction_length] ) > 0x7FFFL )
goto Exit;

result = FT_DivFix( number, power_tens[fraction_length] );
}
else
{
if ( fraction_length <= -10 )
goto Exit;

number *= power_tens[-fraction_length];

if ( number > 0x7FFFL )
goto Exit;

result = number << 16;
}

bram tassyns <bramt>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #16931:  UNDAAngleItalic.cff added by bramt (1KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by wl (Posted a comment)
  • -unavailable- added by bramt (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu 27 Nov 2008 09:56:44 PM UTCwlStatusNone=>Fixed
      Assigned toNone=>wl
      Open/ClosedOpen=>Closed
      Planned ReleaseNone=>2.3.8
    Thu 27 Nov 2008 12:59:14 PM UTCbramtAttached File-=>Added UNDAAngleItalic.cff, #16931

    Back to the top


    Powered by Savane 3.1-cleanup1