-
Notifications
You must be signed in to change notification settings - Fork 365
Update jest, cypress packages to resolve security issues caused by form-data #9539
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Fixes a critical security vulnerability related to form-data using an unsafe random function for choosing a boundary.
package.json
Outdated
@@ -198,6 +198,7 @@ | |||
"nwsapi": "^2.2.1", | |||
"path-to-regexp": "~8.0.0", | |||
"patternfly": "~3.59.5", | |||
"terser": "~4.8.1" | |||
"terser": "~4.8.1", | |||
"form-data": "~4.0.4" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@elsamaryv one small fix, can you please put this in alphabetical order.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, I believe form-data 2.5.5 also contains the fix. Can we upgrade to that version instead to prevent such a big version jump from 2.3.3.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a way to do this without using resolutions? (IMO resolutions only should be used as a last resort). If we can update jest/jest-cli, perhaps newer versions support the right version range
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah @elsamaryv can you first try to upgrade the jest and jest-cli packages then see if it upgrades the form data package. If you are able to upgrade jest and jest-cli see what the most recent version you can get to for those without anything breaking and then see if that causes form-data to upgrade also.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated the Jest
and Cypress
packages that previously included form-data
via transitive dependencies. With these updates, form-data resolves to the patched versions 3.0.4 and 4.0.4. However, upgrading jest-cli
causes multiple test/suite failures, so I had to retain the current version, which still depends on the vulnerable [email protected].
Running yarn why form-data
shows:


50fdc1e
to
b4093bb
Compare
Backported to
|
Update jest, cypress packages to resolve security issues caused by form-data (cherry picked from commit 5cb4543)
Fixes a critical security vulnerability related to form-data dependency.
@miq-bot add-label dependencies