Tehreer / SheenFigure

An implementation of advanced typographic tables of OpenType specification.
Apache License 2.0
31 stars 6 forks source link

Limit the buffer size and execution time #12

Open brawer opened 5 years ago

brawer commented 5 years ago

To prevent attacks, impose an upper limit on buffer size and execution time when shaping text. For example, increment a counter on the number of executed OpenType lookups and give up when it gets excessive, and make sure that the rendering buffer does not get excessively large; check out how HarfBuzz does this. See test case GSUB-3.