deepmerge mergeObject() allows prototype poisoning of returned objects
Impact
deepmerge through 4.3.1 contains a prototype poisoning vulnerability in the mergeObject() function that fails to properly validate keys being written to target objects. Attackers can supply malicious source objects in merge operations to inject attacker-controlled properties into the returned object's prototype, causing applications to inherit unintended values when accessing properties without own-property checks.
Source excerpt · OSVAffected packages
Start with the recorded fix for your release branch. Check your installed version and test compatibility before upgrading. Fixing this advisory does not rule out other vulnerabilities in the release.
| Affected range | Recorded fix |
|---|---|
| From 4.2.0 through 4.3.1 (inclusive)Semantic versions | Not recorded |
Version evidence: OSV · GHSA-gcqx-w48m-w2h4
View original version evidence (0 explicit versions)
Original source description
deepmerge through 4.3.1 contains a prototype poisoning vulnerability in the mergeObject() function that fails to properly validate keys being written to target objects. Attackers can supply malicious source objects in merge operations to inject attacker-controlled properties into the returned object's prototype, causing applications to inherit unintended values when accessing properties without own-property checks.
References
- Security advisory nvd.nist.gov/vuln/detail/CVE-2026-93753
- Source reference github.com/TehShrike/deepmerge/issues/273
- Source reference github.com/TehShrike/deepmerge
- Source reference github.com/TehShrike/deepmerge/blob/5b87756a5671635679001cbac72aa42f23472c81/index.js
- Security advisory www.vulncheck.com/advisories/deepmerge-through-4.3.1-prototype-poisoning-via-mergeobject