Files
harfbuzz/test/api
Behdad EsfahbodandClaude Opus 4.8 0aa7da1772 [GPOS] Charge out-of-order MarkBasePos/MarkLigPos base rescans to max_ops
MarkBasePosFormat1 and MarkLigPosFormat1 find a mark's base with a
cache (c->last_base / last_base_until) that is only amortized while
buffer->idx moves forward.  A (Chain)Context lookup that recurses into
the mark lookup at input positions out of order resets the cache, so
each application rescans the glyphs from last_base_until to idx from
scratch; on a long run of marks with no base this is quadratic and was
uncharged.

Charge the rescanned span (idx - j) to buffer->max_ops after the
backward search in both lookups, failing the shape when the budget runs
out.  A real mark-heavy font pays a negligible amount.  Adds a
regression test shaping a Context lookup that recurses to MarkBasePos
at positions 1,0,1,0,...

Discovered by Anthropic's OSS Scanner, as vulnerability ANT-2026-FJEXEDJ4.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-11-11 12:43:10 -06:00
..
2025-04-06 18:08:50 -06:00
2026-07-30 19:02:25 -06:00
2026-07-31 04:31:26 +03:00
2025-04-05 22:37:10 -06:00
2020-01-15 13:36:01 -08:00
2025-06-08 13:43:27 +03:00