Fix underscore vulnerability SNYK-JS-UNDERSCORE-1080984 #10
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.



Fix underscore vulnerability SNYK-JS-UNDERSCORE-1080984
Summary
This PR fixes a medium severity arbitrary code injection vulnerability in the
underscorepackage (CVE-2021-23358) by upgrading thecfenvdependency from^1.0.4to^1.2.4. The vulnerable underscore@1.9.1 was a transitive dependency introduced through cfenv@1.2.2, and the upgrade pulls in underscore@1.12.1 which contains the security fix.Key Changes:
cfenvversion in package.json from^1.0.4to^1.2.4variableoption was unsanitizedReview & Testing Checklist for Human
npm auditand verify SNYK-JS-UNDERSCORE-1080984 is no longer reportedRecommended Test Plan:
npm startnpm auditto confirm vulnerability count decreasedDiagram
%%{ init : { "theme" : "default" }}%% graph TD subgraph "Dependency Tree" package["package.json"]:::major-edit lock["package-lock.json"]:::major-edit cfenv["cfenv@1.2.4<br/>(upgraded from 1.0.4)"]:::minor-edit underscore["underscore@1.12.1<br/>(upgraded from 1.9.1)"]:::minor-edit app["app.js<br/>(goof application)"]:::context end package --> cfenv cfenv --> underscore app --> cfenv lock --> cfenv subgraph Legend L1["Major Edit"]:::major-edit L2["Minor Edit"]:::minor-edit L3["Context/No Edit"]:::context end classDef major-edit fill:#90EE90 classDef minor-edit fill:#87CEEB classDef context fill:#F5F5F5Notes
variableoption from_.templateSettingswas not sanitizednpm list underscoreshows version 1.12.1 andnpm auditno longer reports the underscore vulnerability