{"id":"CVE-2026-96780","aliases":["GHSA-62ch-8vmq-8xm7"],"url":"https://o3.security/vulnerability/CVE-2026-96780","summary":"figlet is vulnerable to denial of service via unbounded loop when whitespaceBreak is used with a small width","details":"### Impact\nA denial-of-service (infinite loop) can occur in `text()` / `textSync()` when\n**both**:\n- `whitespaceBreak: true` is set, **and**\n- `width` is set smaller than the rendered width of a single FIGlet character.\nUnder these conditions `breakWord()` could never find a valid break point, so the\nword-wrapping loop in `generateFigTextLines()` never terminated. This pins a CPU\ncore and grows memory without bound, blocking the Node.js event loop.\n\n### Severity\nLow or Medium. Triggering requires a non-default configuration (`whitespaceBreak: true`) and\nan attacker-controlled `width` value reaching `text()`/`textSync()`. This library is typically\nused with fixed options, where this is not\nreachable. Applications that pass an untrusted `width` together with\n`whitespaceBreak` on a request path are affected.\n\n### Patches\nFixed in **figlet 1.11.3**. `breakWord()` now always makes forward progress\n(emitting an over-wide character on its own line), and FIGlet header parsing now\nrejects invalid values (e.g. zero/negative height).\n\n### Workarounds\nDo not expose `width` to untrusted input, or leave `whitespaceBreak` disabled\n(the default), or upgrade to 1.11.3.","published":"2026-10-01T20:21:54.408Z","modified":"2026-10-21T03:00:24.065959142Z","cvss":null,"epss":null,"cisaKev":null,"exploitsKnown":null,"affectedPackages":[{"ecosystem":"npm","name":"figlet","fixedVersion":"1.11.3"}],"fix":{"url":"https://github.com/patorjk/figlet.js/commit/cb2839d0e53aeafbd361e9587abc72e49e41cbb3","label":"patorjk/figlet.js@cb2839d"},"references":[{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/96xxx/CVE-2026-96780.json"},{"type":"ADVISORY","url":"https://github.com/patorjk/figlet.js/security/advisories/GHSA-62ch-8vmq-8xm7"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-96780"},{"type":"FIX","url":"https://github.com/patorjk/figlet.js/commit/cb2839d0e53aeafbd361e9587abc72e49e41cbb3"},{"type":"FIX","url":"https://github.com/patorjk/figlet.js/pull/169"},{"type":"PACKAGE","url":"https://github.com/patorjk/figlet.js"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2026-10-21T03:00:24.065959142Z"}}