CVE-2021-23566 Information Exposure
Attackers can reproduce the last generated ID via the valueOf function, leading to information exposure in applications using the nanoid library.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2021-23566?
CVE-2021-23566 is a medium-severity vulnerability in nanoid, published on 14 Jan 2022. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
The package nanoid from 3.0.0 and before 3.1.31 are vulnerable to Information Exposure via the valueOf() function which allows to reproduce the last id generated.
Weakness: CWE-704
Which versions are affected by CVE-2021-23566?
2 open source packages ship an affected version, including nanoid. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
nanoid npm | From 3.0.0 | 3.1.31 |
nanoid npm | From 3.0.0 | 3.1.31 |
Products include Nanoid Project Nanoid.
How do I fix CVE-2021-23566?
Upgrade nanoid to 3.1.31 or later.
Is CVE-2021-23566 being exploited?
There is no known exploitation of CVE-2021-23566 in the wild and no public exploit code.
Other vulnerabilities in nanoid
Sources
Also known as DEBIAN-CVE-2021-23566, GHSA-qrpm-p2h7-hrv2, UBUNTU-CVE-2021-23566.