Skip to content

Limit OpenType composite glyph recursion#571

Merged
treeform merged 1 commit intomasterfrom
fix/opentype-composite-recursion
Apr 30, 2026
Merged

Limit OpenType composite glyph recursion#571
treeform merged 1 commit intomasterfrom
fix/opentype-composite-recursion

Conversation

@treeform
Copy link
Copy Markdown
Owner

Fixes #564.

Summary:

  • Thread a bounded recursion depth through glyf composite glyph parsing.
  • Raise PixieError when composite glyph references exceed the limit.
  • Add a regression test that patches a Roboto glyph to reference itself.

Tests:

  • nim r --hints:off --warnings:off tests\test_fonts.nim
  • git diff --check

@treeform treeform merged commit c140e23 into master Apr 30, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OpenType composite glyph parsing allows unbounded recursion and stack exhaustion

1 participant