oclif / plugin-warn-if-update-available

warn user if a new CLI version is available
MIT License
38 stars 13 forks source link

lodash.template security vulnerability #589

Closed brendanmckeown closed 5 months ago

brendanmckeown commented 5 months ago

Describe the bug

A high severity security vulnerability exists in the lodash.template dependency of this project (version 4.5.0). The suggested fix by npm audit is to downgrade the oclif package to v3. The lodash.template dependency does not have a patch, and should probably be replaced by either lodash or lodash-es in this project.

More info: https://github.com/advisories/GHSA-35jh-r3h4-6jhm

To Reproduce Steps to reproduce the behavior: Run npm audit in a project that uses this package.

Expected behavior There are no security vulnerabilities.

Screenshots image

Environment (please complete the following information):

        "@oclif/core": "^3.26.4",
        "@oclif/plugin-help": "^6.0.21",
        "@oclif/plugin-plugins": "^5.0.14",
        "oclif": "^4.8.8",

Additional context Add any other context about the problem here.

arnaudbesnier commented 5 months ago

For contributors information

The Lodash documentation encourages people to stop using per-method packages like lodash.findlast and install lodash instead. That won't help for indirect dependencies, but you know, FYI, if you're using lodash.findlast directly, perhaps consider switching to lodash and using _.findlast() that way instead.

https://github.com/lodash/lodash/issues/5832#issuecomment-2064269538

tiwarishubham635 commented 5 months ago

This has been fixed in lodash v4.17.21. Can this be updated here as well? We are waiting for it for our cli project

git2gus[bot] commented 5 months ago

This issue has been linked to a new work item: W-15692116

tiwarishubham635 commented 5 months ago

@mdonnalley @iowillhoit Thanks for merging this fix! One more thing, you have a dependency on oclif 4.10.2 that also uses lodash.template. They have fixed it in v4.10.5. Can you bump the oclif version as well?

mdonnalley commented 5 months ago

Dependabot runs weekly on all the oclif repos. We'll let that take care of the dependency bump. If you absolutely need the upgrade today, then feel free to make a PR yourself.

tiwarishubham635 commented 5 months ago

Sure, I have created this

QBlockQ commented 1 month ago

lodash is really missed up !!