What’s Vulnerable › Vulnerabilities
CVE-2024-21505
- Severity: high (CVSS 7.5 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.7% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2024-03-25 · updated 2026-06-17
- Weakness: CWE-1321
Description
Versions of the package web3-utils before 4.2.1 are vulnerable to Prototype Pollution via the utility functions format and mergeDeep, due to insecure recursive merge. An attacker can manipulate an object's prototype, potentially leading to the alteration of the behavior of all objects inheriting from the affected prototype by passing specially crafted input to these functions.
Affected products
- Web3-Utils: before 4.2.1 — fixed in 4.2.1
How to fix
Upgrade to a fixed version: Web3-Utils 4.2.1. Check the vendor advisory for mitigations.
References
- https://github.com/web3/web3.js/commit/8ed041c6635d807b3da8960ad49e125e3d1b0e80
- https://security.snyk.io/vuln/SNYK-JS-WEB3UTILS-6229337
- https://github.com/web3/web3.js/commit/8ed041c6635d807b3da8960ad49e125e3d1b0e80
- https://security.snyk.io/vuln/SNYK-JS-WEB3UTILS-6229337
Get alerted when CVE-2024-21505 or the next vulnerability affects your stack