logo

CVE-2024-55565 nanoid

Package

Manager: npm
Name: nanoid
Vulnerable Version: >=4.0.0 <5.0.9 || >=0 <3.3.8

Severity

Level: Medium

CVSS v3.1: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N

CVSS v4.0: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:L/VA:N/SC:N/SI:L/SA:N

EPSS: 0.00032 pctl0.07697

Details

Predictable results in nanoid generation when given non-integer values When nanoid is called with a fractional value, there were a number of undesirable effects: 1. in browser and non-secure, the code infinite loops on while (size--) 2. in node, the value of poolOffset becomes fractional, causing calls to nanoid to return zeroes until the pool is next filled 3. if the first call in node is a fractional argument, the initial buffer allocation fails with an error Version 3.3.8 and 5.0.9 are fixed.

Metadata

Created: 2024-12-09T03:30:59Z
Modified: 2024-12-13T22:57:29Z
Source: https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2024/12/GHSA-mwcw-c2x4-8c55/GHSA-mwcw-c2x4-8c55.json
CWE IDs: ["CWE-835"]
Alternative ID: GHSA-mwcw-c2x4-8c55
Finding: F138
Auto approve: 1