CVE-2021-39227
CRITICAL 9.8CVSS 3.1Prototype Pollution in the merge and clone helper methods
ZRender is a lightweight graphic library providing 2d draw for Apache ECharts. In versions prior to 5.2.1, using merge and clone helper methods in the src/core/util.ts module results in prototype pollution. It affects the popular data visualization library Apache ECharts, which uses and exports these two methods directly. The GitHub Security Advisory page for this vulnerability contains a proof of concept. This issue is patched in ZRender version 5.2.1. One workaround is available: Check if there is __proto__ in the object keys. Omit it before using it as an parameter in these affected methods. Or in echarts.util.merge and setOption if project is using ECharts.
- Published
- 17 Sep 2021
- Last modified
- 8 Jul 2026
- Assigned by
- security-advisories@github.com
- NVD status
- Modified
- Weakness
- CWE-1321CWE-915
- Also known as
- GHSA-fhv8-fx5f-7fxf
- Sources
- NVDJSONOSV GHSA-fhv8-fx5f-7fxfJSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | CRITICAL 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| NVD | security-advisories@github.com (Secondary) | CVSS 3.1 | MEDIUM 6.2 | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| OSV | GitHub | CVSS 3.1 | MEDIUM 6.2 | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | HIGH 7.5 | AV:N/AC:L/Au:N/C:P/I:P/A:P |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | baidu | zrendercpe:2.3:a:baidu:zrender:*:*:*:*:*:*:*:* |
< 5.2.1 | 5.2.1 |
| OSV | npm | zrender | >= 5.0.0, < 5.2.1 | 5.2.1 |
| OSV | npm | zrender | < 4.3.3 | 4.3.3 |
References
- https://github.com/ecomfe/zrender/pull/826 · Patch, Third Party Advisory, WEB
- https://github.com/ecomfe/zrender/releases/tag/5.2.1 · Release Notes, Third Party Advisory, WEB
- https://github.com/ecomfe/zrender/security/advisories/GHSA-fhv8-fx5f-7fxf · Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2021-39227 · ADVISORY
- https://github.com/ecomfe/zrender · PACKAGE
History
- 25 Nov 2026 20:33 UTC · NVD: first stored (published 17 Sep 2021)
- 25 Nov 2026 20:11 UTC · OSV: first stored (published 20 Sep 2021)