Closed soryy708 closed 5 years ago
Confirmed. This is also reported in the yargs-unparser
repo: https://github.com/yargs/yargs-unparser/issues/35
However, yargs-unparser
specifies the dependency as "requires": { "lodash": "^4.17.11" }
. Thus, a temporary workaround is making sure a more recent version of lodash
(>=4.17.13) is installed.
Prerequisites
faq
labelnode node_modules/.bin/mocha --version
(Local) andmocha --version
(Global). We recommend that you not install Mocha globally.Description
Mocha depends on yargs-unparser, which depends on Lodash, which is vulnerable to prototype pollution in versions < 4.17.13. This does not show in
npm audit
, rather on GitHub if you publish a repository that depends onmocha
(^6.1.4).Steps to Reproduce
npm i mocha --save-dev
Expected behavior: No vulnerabilities in Mocha
Actual behavior:
Reproduces how often: Every time
Versions
mocha --version
andnode node_modules/.bin/mocha --version
: 6.1.4 (both)node --version
: v10.13.0Additional Information
None