Skip to main content
← All vulnerabilities
CVE-2026-67214GHSA-28WG-GHJ8-5HJV

nanoid Infinite Loop via Negative Size in non-secure module

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 5.1.16, 3.3.16
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: none
  • Automatable: no
  • Technical impact: partial

Summary

nanoid (Nano ID) before 3.3.16 and 5.1.16 contains an infinite loop in the customAlphabet and nanoid functions of its non-secure module (nanoid/non-secure). When these functions are given a negative size, the loop counter is decremented from a negative value and never reaches its termination condition, spinning indefinitely and hanging the calling thread. An application that passes an unvalidated, attacker-controlled negative size to these functions is exposed to a denial-of-service condition.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: none · Automatable: no · Technical impact: partial

  3. Record last updated

Affected versions

  • nanoid_project nanoid

    From 4.0.0 · fixed in 5.1.16; fixed in 3.3.16

  • nanoidnpm

    fixed in 3.3.16

  • nanoidnpm

    From 4.0.0 · fixed in 5.1.16

References 4

GitHub · ai/nanoid

vulncheck.com