uPlot CVE-2024-21489
HIGHSeverity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:L/SC:N/SI:N/SA:N/E:P/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
AC:H because exploitation requires attacker data to reach uplot.assign(), dependent on application architecture, not inherent to the library endpoint itself.
Primary rating from Vendor (snyk).
CVSS VectorVendor: snyk
Lifecycle Timeline
5Blast Radius
ecosystem impact- 20 npm packages depend on uplot (8 direct, 12 indirect)
Ecosystem-wide dependent count for version 1.6.31.
DescriptionCVE.org
Versions of the package uplot before 1.6.31 are vulnerable to Prototype Pollution via the uplot.assign function due to missing check if the attribute resolves to the object prototype.
AnalysisAI
Prototype Pollution in the uPlot JavaScript charting library (versions before 1.6.31) allows an attacker who can supply crafted object data to the internal uplot.assign or copy functions to modify Object.prototype, corrupting shared state across the entire JavaScript runtime. All three distribution formats (CJS, ESM, IIFE) were affected identically, as confirmed by the fix commit 5756e3e which adds __proto__ key guards to both functions in each bundle. A proof-of-concept is confirmed by the E:P modifier in the provided CVSS 4.0 vector; no confirmed active exploitation (not in CISA KEV). EPSS of 0.63% (46th percentile) reflects realistic but low mass-exploitation probability.
Technical ContextAI
uPlot is a lightweight JavaScript time-series charting library distributed via npm. The root cause is CWE-1321 (Improperly Controlled Modification of Object Prototype Attributes): the internal assign() function iterates over all keys of a source object using for...in and recursively calls copy() without checking whether any key equals __proto__. In JavaScript, assigning to obj['__proto__'] does not add a property to obj; it replaces the prototype of obj, propagating any injected properties to every subsequent object instantiated in the runtime. The fix (commit 5756e3e9b91270b303157e14bd0174311047d983) introduces a constant const __proto__ = "__proto__" and guards both copy() and assign() with if (k != __proto__) checks. The Java WebJars wrapper (SNYK-JAVA-ORGWEBJARSNPM-8163085) bundles the affected JS and is independently vulnerable. No CPE strings were provided in the input data.
Affected ProductsAI
The uPlot npm package in all versions before 1.6.31 is affected across all distribution formats: uPlot.cjs.js (CommonJS), uPlot.esm.js (ES Module), uPlot.iife.js, and uPlot.iife.min.js. The Java WebJars wrapper org.webjars.npm:uplot is also affected as documented at SNYK-JAVA-ORGWEBJARSNPM-8163085. No CPE strings were provided in the input. The fix is confirmed in commit 5756e3e9b91270b303157e14bd0174311047d983; the patched release version is 1.6.31 per Snyk advisory SNYK-JS-UPLOT-6209224.
RemediationAI
Upgrade the uPlot npm package to version 1.6.31 or later, which contains the fix from commit 5756e3e9b91270b303157e14bd0174311047d983. Java projects using the WebJars wrapper should upgrade to the corresponding patched org.webjars.npm:uplot version. Advisory details are available at https://security.snyk.io/vuln/SNYK-JS-UPLOT-6209224 and https://security.snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-8163085. If an immediate upgrade is not possible, the primary compensating control is to ensure no untrusted user-supplied JSON is passed as chart configuration options to uPlot - sanitize or schema-validate all chart option objects server-side before they reach the uPlot API. This control trades off feature flexibility but eliminates the attack surface without modifying the library.
More in Prototype Pollution
View allPrototype pollution in Adobe Acrobat Reader versions 24.001.30356, 26.001.21367 and earlier enables arbitrary code execu
Prototype pollution in the farinspace Partners WordPress plugin (versions up to and including 0.2.0) enables remote unau
Prototype pollution vulnerability in 'deephas' versions 1.0.0 through 1.0.5 allows attacker to cause a denial of service
A Prototype Pollution issue in Cronvel Tree-kit v.0.7.4 and before allows a remote attacker to execute arbitrary code vi
A Prototype Pollution issue in Aliconnect /sdk v.0.0.6 allows an attacker to execute arbitrary code via the aim function
All versions of the package safe-eval are vulnerable to Prototype Pollution via the safeEval function, due to improper s
This affects the package vm2 before 3.9.4 via a Prototype Pollution attack vector, which can lead to execution of arbitr
Prototype Pollution in chargeover redoc v2.0.9-rc.69 allows attackers to execute arbitrary code or cause a Denial of Ser
alizeait unflatto <= 1.0.2 was discovered to contain a prototype pollution via the method exports.unflatto at /dist/inde
A vulnerability exists in the 'dagre-d3-es' Node.js package version 7.0.9, specifically within the 'bk' module's addConf
A Prototype Pollution vulnerability in the util-deps.addFileDepend function of magix-combine-ex versions thru 1.2.10 all
Chartist 1.x through 1.3.0 allows Prototype Pollution via the extend function. Rated critical severity (CVSS 9.8), this
Same technique Information Disclosure
View allShare
External POC / Exploit Code
Leaving vuln.today