CVE-2021-3765 Inefficient Regular Expression Complexity in validatorjs/validator.js
An attacker can cause a denial of service by submitting specially crafted input that triggers inefficient regular expression processing in the validator.js library.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2021-3765?
CVE-2021-3765 is a medium-severity denial of service vulnerability in validatorjs/validator.js, published on 2 Nov 2021. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
validator.js is vulnerable to Inefficient Regular Expression Complexity
Weakness: CWE-1333
Which versions are affected by CVE-2021-3765?
2 open source packages ship an affected version, including validator. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
validator npm | All versions | 13.7.0 |
validator npm | All versions | 13.7.0 |
Products include Validator Project Validator.
How do I fix CVE-2021-3765?
Upgrade validator to 13.7.0 or later.
Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.
Is CVE-2021-3765 being exploited?
There is no known exploitation of CVE-2021-3765 in the wild and no public exploit code.
Other vulnerabilities in validatorjs/validator.js
Sources
Also known as CLSA-2026-1789162879, CLSA-2026-1790176084, GHSA-qgmg-gppg-76g5, MINI-2hvm-56g4-8j2f, MINI-5x6c-9jrc-rg6w, ROOT-APP-NPM-CVE-2021-3765 and 1 more.