CVE-2026-67214

NameCVE-2026-67214
Descriptionnanoid (Nano ID) before 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.
SourceCVE (at NVD; CERT, ENISA, LWN, oss-sec, fulldisc, Debian ELTS, Red Hat, Ubuntu, Gentoo, SUSE bugzilla/CVE, GitHub advisories/code/issues, web search, more)

Vulnerable and fixed packages

The table below lists information on source packages.

Source PackageReleaseVersionStatus
node-mocha (PTS)bullseye8.2.1+ds1+~cs29.4.27-3vulnerable
bullseye (security)8.2.1+ds1+~cs29.4.27-3+deb11u1vulnerable
bookworm10.1.0+ds1+~cs29.3.1-1fixed
trixie10.7.2+ds1+~cs33.1.11-2fixed
forky, sid11.7.7+ds1+~cs36.3.16-1fixed
node-postcss (PTS)bullseye8.2.1+~cs5.3.23-8vulnerable
bullseye (security)8.2.1+~cs5.3.23-8+deb11u1vulnerable
bookworm8.4.20+~cs8.0.23-1+deb12u1vulnerable
trixie8.4.49+~cs9.2.32-1vulnerable
forky8.5.15+~cs9.3.39-1fixed
sid8.5.23+~cs10.2.23-1fixed

The information below is based on the following data on fixed versions.

PackageTypeReleaseFixed VersionUrgencyOriginDebian Bugs
node-mochasource(unstable)9.1.4+ds1+~cs28.2.8-1
node-postcsssource(unstable)8.5.15+~cs9.3.39-1

Notes

node-postcss bundles nanoid
node-mocha/9.1.4+ds1+~cs28.2.8-1 removes the node-nanoid copy
Fixed by: https://github.com/ai/nanoid/commit/6de05d794f62eeac3f527c74c34c6af0c1d32e49 (5.1.16)

Search for package or bug name: Reporting problems