-
Notifications
You must be signed in to change notification settings - Fork 441
upgrade @swc/cli to fix yauzl off-by-one error #3291
Description
Is there an existing issue for this?
- I have searched the existing issues
Current behavior
yauzl (aka Yet Another Unzip Library) version 3.2.0 for Node.js contains an off-by-one error in the NTFS extended timestamp extra field parser within the getLastModDate() function. The while loop condition checks cursor < data.length + 4 instead of cursor + 4 <= data.length, allowing readUInt16LE() to read past the buffer boundary. A remote attacker can cause a denial of service (process crash via ERR_OUT_OF_RANGE exception) by sending a crafted zip file with a malformed NTFS extra field. This affects any Node.js application that processes zip file uploads and calls entry.getLastModDate() on parsed entries. Fixed in version 3.2.1.
This is fixed by upgrading @swc/cli to version 0.8.0
Minimum reproduction code
n/a
Steps to reproduce
No response
Expected behavior
to not receive depedabot errors for yauzl
Package version
11.0.16
NestJS version
No response
Node.js version
No response
In which operating systems have you tested?
- macOS
- Windows
- Linux
Other
No response