Update dependency diff to v5.2.2 [SECURITY] - #15
Open
renovate[bot] wants to merge 1 commit into
Open
Conversation
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
January 20, 2026 03:56
013215b to
8c7cf22
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
January 21, 2026 19:08
8c7cf22 to
cdc2c86
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
February 3, 2026 19:45
cdc2c86 to
c38de3a
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
February 13, 2026 20:14
c38de3a to
b1bf98c
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
2 times, most recently
from
March 14, 2026 17:21
0165f28 to
38ffb2d
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
April 15, 2026 11:38
38ffb2d to
c1fd5ac
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
May 1, 2026 07:38
c1fd5ac to
c433ad6
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
May 13, 2026 20:14
c433ad6 to
b6eef23
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
May 22, 2026 03:26
b6eef23 to
9d22292
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
2 times, most recently
from
June 4, 2026 04:00
e845a0c to
2714f9a
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
June 12, 2026 14:44
2714f9a to
192fd6f
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
July 18, 2026 00:05
192fd6f to
3948074
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
July 25, 2026 12:00
3948074 to
10c4a7a
Compare
renovate
Bot
force-pushed
the
renovate/npm-diff-vulnerability
branch
from
August 1, 2026 11:44
10c4a7a to
6067f9f
Compare
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.
This PR contains the following updates:
5.2.0→5.2.2jsdiff has a Denial of Service vulnerability in parsePatch and applyPatch
CVE-2026-24001 / GHSA-73rr-hh4g-fpgx
More information
Details
Impact
Attempting to parse a patch whose filename headers contain the line break characters
\r,\u2028, or\u2029can cause theparsePatchmethod to enter an infinite loop. It then consumes memory without limit until the process crashes due to running out of memory.Applications are therefore likely to be vulnerable to a denial-of-service attack if they call
parsePatchwith a user-provided patch as input. A large payload is not needed to trigger the vulnerability, so size limits on user input do not provide any protection. Furthermore, some applications may be vulnerable even when callingparsePatchon a patch generated by the application itself if the user is nonetheless able to control the filename headers (e.g. by directly providing the filenames of the files to be diffed).The
applyPatchmethod is similarly affected if (and only if) called with a string representation of a patch as an argument, since under the hood it parses that string usingparsePatch. Other methods of the library are unaffected.Finally, a second and lesser bug - a ReDOS - also exhibits when those same line break characters are present in a patch's patch header (also known as its "leading garbage"). A maliciously-crafted patch header of length n can take
parsePatchO(n³) time to parse.Patches
All vulnerabilities described are fixed in v8.0.3.
Workarounds
If using a version of jsdiff earlier than v8.0.3, do not attempt to parse patches that contain any of these characters:
\r,\u2028, or\u2029.References
PR that fixed the bug: https://github.com/kpdecker/jsdiff/pull/649
CVE Notes
Note that although the advisory describes two bugs, they each enable exactly the same attack vector (that an attacker who controls input to
parsePatchcan cause a DOS). Fixing one bug without fixing the other therefore does not fix the vulnerability and does not provide any security benefit. Therefore we assume that the bugs cannot possibly constitute Independently Fixable Vulnerabilities in the sense of CVE CNA rule 4.2.11, but rather that this advisory is properly construed under the rules as describing a single Vulnerability.Severity
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:UReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Release Notes
kpdecker/jsdiff (diff)
v5.2.2Compare Source
v5.2.1Compare Source
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.