[Aikido] Fix security issue in lodash-es via minor version upgrade from 4.17.21 to 4.18.1 in client#798
Open
aikido-autofix[bot] wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Upgrade lodash-es to patch critical RCE vulnerability in _.template via options.imports injection and medium prototype pollution issues in _.unset and _.omit functions.
All breaking changes by upgrading lodash-es from version 4.17.21 to 4.18.1 (CHANGELOG)
_.unset/_.omit:constructorandprototypeare now blocked unconditionally as non-terminal path keys. Calls that previously returnedtrueand deleted the property now returnfalseand leave the target untouched._.template:importskeys containing forbidden identifier characters now throw"Invalid imports option passed into _.template"error, where previously they were accepted.✅ 3 CVEs resolved by this upgrade, including 1 critical 🚨 CVE
This PR will resolve the following CVEs:
🤖 Remediation details
Fix security vulnerabilities in
lodashandlodash-estransitive dependenciesShort summary
This PR remediates security vulnerabilities in two transitive dependencies —
lodashandlodash-es— present inclient/package-lock.json. Neither package is a direct dependency inclient/package.json; both are resolved transitively by multiple upstream packages. The fixes are lockfile-only forlodash(resolved vianpm update) and lockfile + override forlodash-es(requiring anoverridesentry inclient/package.jsondue to exact-version pinning by CKEditor sub-packages).lodash
lodashwas resolved at4.17.23in the lockfile, below the patched floor of4.18.0/4.18.1. All parents that pull inlodash(react-big-calendar,react-color,reactcss,semantic-ui-react,@uppy/core,@uppy/dashboard,@uppy/utils,recharts,@testing-library/jest-dom,whatwg-url) declare it with caret ranges (^4.17.xor^4.7.0) that are semver-compatible with4.18.1, so the lockfile was stale rather than structurally blocked. Runningnpm update lodash --package-lock-onlyfrom theclient/directory refreshed the single hoisted instance to4.18.1without any manifest changes.lodash-es
lodash-eswas resolved at4.17.21in the lockfile, below the patched floor of4.18.1. While non-CKEditor parents (react-big-calendar,react-color,semantic-ui-react) already declared compatible caret ranges, the CKEditor sub-packages (@ckeditor/ckeditor5-clipboard,@ckeditor/ckeditor5-core,@ckeditor/ckeditor5-engine, and many others at versions40.xand41.x) pinlodash-esexactly at"4.17.21", preventing a lockfile-only resolution. The predefined build@ckeditor/ckeditor5-build-multi-rootonly exists up to44.x, so no parent bump within the available version range could unblock the exact pin. A targeted selector-style override"lodash-es@<4.18.1": "4.18.1"was added to theoverridesblock inclient/package.json, andnpm install --package-lock-onlyresolved the single hoisted instance to4.18.1.Version changes
lodash4.17.234.18.1npm update(all parents allow^4.18.x)lodash-es4.17.214.18.1"lodash-es@<4.18.1": "4.18.1"added toclient/package.json; CKEditor sub-packages exact-pin4.17.21making lockfile-only resolution impossible