chore(deps): update dependency path-to-regexp to v8#5378
Conversation
Up to standards ✅🟢 Issues
|
There was a problem hiding this comment.
Code Review: Dependency Update — path-to-regexp 0.1.13 → 8.4.2
This is a security-driven dependency update scoped entirely to the docs/ package. The changes look correct and appropriate.
What's happening
The PR updates the resolutions override in docs/package.json from path-to-regexp@0.1.13 to 8.4.2. The resolutions field is a Yarn mechanism to force a specific version of a transitive dependency — meaning path-to-regexp is not used directly by the docs site, but by a transitive dependency (e.g., express used by the dev server). The override ensures the vulnerable version isn't pulled in transitively.
The yarn.lock correctly reflects this:
path-to-regexp@~0.1.12is still present (retained for other transitive dependencies that specify that range)path-to-regexp@8.4.2is added as the new forced resolution
Security context
The jump to v8.4.0+ fixes two CVEs:
Both involve wildcard backtracking vulnerabilities in route matching — significant issues for any HTTP routing use.
Potential concern (low risk here)
The API between v0.x and v8.x of path-to-regexp changed significantly. However, since this is a resolutions override on a transitive dependency (not a direct usage), any direct API consumers in the dep tree would be relying on the old API. This could cause a runtime mismatch if the transitive dep (e.g., an older version of express's router) calls the v0.x API but gets the v8.x module.
That said, this is a docs site used only during local dev/build — the blast radius is minimal and this is the correct approach to eliminate the vulnerability from the dependency graph.
Verdict
Approved. This is a well-scoped security dependency update. The yarn.lock changes are consistent with the intent. Given the CVE severity and that this only affects the docs toolchain, the update is appropriate to merge.
There was a problem hiding this comment.
Approved. Security update for path-to-regexp (CVE-2026-4926, CVE-2026-4923), scoped to docs toolchain only. Changes are correct — yarn.lock is consistent with the resolutions override.
725b9f3 to
bc6b57b
Compare
There was a problem hiding this comment.
Code Review: path-to-regexp v0.1.13 → v8.4.2
This is a Renovate-generated security update scoped entirely to the docs/ directory. The changes are correct and well-scoped.
What the PR does
Updates the resolutions override in docs/package.json to force path-to-regexp@8.4.2 for the express transitive dependency. This is the right approach — rather than pinning the package globally (which could break other transitive consumers on different semver ranges), the resolution is scoped as express/path-to-regexp, meaning Yarn only forces the newer version when express is the requester.
Security fix context
v8.4.0 addressed two CVEs:
- CVE-2026-4926 (GHSA-j3q9-mxjg-w52f) — wildcard backtracking allowing ReDoS
- CVE-2026-4923 (GHSA-27v5-c462-wpq7) — large optional route combinations causing regex explosion
These are ReDOS vulnerabilities with potentially serious impact in server environments. Even though this only affects the docs toolchain, eliminating the vulnerability from the dependency graph is the right call.
yarn.lock analysis
The lock file changes are consistent with the intent:
path-to-regexp@~0.1.12entry is retained (other transitive deps still request this range)path-to-regexp@3.3.0entry is unchanged (unrelated dep)path-to-regexp@8.4.2is added as the new resolved version for the express resolution
One minor observation: the old path-to-regexp@0.1.13 entry previously served double duty (matching both the bare 0.1.13 pin and ~0.1.12). After this change it only matches ~0.1.12. This is correct behavior since the 0.1.13 explicit pin was the old resolution override that's now been replaced.
API compatibility note
The v0.x → v8.x jump is a significant API overhaul, but since this is a resolutions override rather than a direct dependency, this only matters if a transitive dep calls path-to-regexp's public API directly. In the context of Docusaurus/express dev tooling for a docs site, the runtime risk is minimal.
Verdict
Approved. Clean, well-scoped security update. No concerns with the implementation.
Pull request was closed
bc6b57b to
b0da3ab
Compare
There was a problem hiding this comment.
Code Review: chore(deps): update dependency path-to-regexp to v8
This is a Renovate Bot-generated dependency update for the docs/ directory, bumping path-to-regexp from 1.9.0 → 8.4.2 as a security resolution override.
Summary
The change is minimal and correct:
docs/package.json: updates theresolutionsentry forexpress/path-to-regexpfrom1.9.0to8.4.2docs/yarn.lock: updated lock file entries accordingly, preserving the^1.7.0and~0.1.12entries untouched (they resolve to different version pins)
Security Significance
This update is specifically important — v8.4.0 fixes two CVEs:
Both are related to wildcard backtracking (ReDoS vectors). Updating to 8.4.2 patches these and also includes additional performance improvements (~20-25% parse/compile speedup) and a smaller bundle size.
Assessment
The scope is correctly limited to the docs/ subdirectory — this is a dev/docs tooling dependency, not part of the core TUnit .NET library. The yarn.lock correctly retains path-to-regexp@1.9.0 as a direct dependency resolution for packages that explicitly require ^1.7.0 (the resolution override only forces the express/path-to-regexp path to 8.4.2).
No concerns. This is a straightforward, well-scoped security dependency bump. Approved.
Updated [TUnit.Core](https://github.com/thomhurst/TUnit) from 1.23.7 to 1.28.7. <details> <summary>Release notes</summary> _Sourced from [TUnit.Core's releases](https://github.com/thomhurst/TUnit/releases)._ ## 1.28.7 <!-- Release notes generated using configuration in .github/release.yml at v1.28.7 --> ## What's Changed ### Other Changes * fix: prevent StringBuilder race in console interceptor during parallel tests by @thomhurst in thomhurst/TUnit#5414 ### Dependencies * chore(deps): update tunit to 1.28.5 by @thomhurst in thomhurst/TUnit#5415 **Full Changelog**: thomhurst/TUnit@v1.28.5...v1.28.7 ## 1.28.5 <!-- Release notes generated using configuration in .github/release.yml at v1.28.5 --> ## What's Changed ### Other Changes * perf: eliminate redundant builds in CI pipeline by @thomhurst in thomhurst/TUnit#5405 * perf: eliminate store.ToArray() allocation on mock behavior execution hot path by @thomhurst in thomhurst/TUnit#5409 * fix: omit non-class/struct constraints on explicit interface mock implementations by @thomhurst in thomhurst/TUnit#5413 ### Dependencies * chore(deps): update tunit to 1.28.0 by @thomhurst in thomhurst/TUnit#5406 **Full Changelog**: thomhurst/TUnit@v1.28.0...v1.28.5 ## 1.28.0 <!-- Release notes generated using configuration in .github/release.yml at v1.28.0 --> ## What's Changed ### Other Changes * fix: resolve build warnings in solution by @thomhurst in thomhurst/TUnit#5386 * Perf: Optimize MockEngine hot paths (~30-42% faster) by @thomhurst in thomhurst/TUnit#5391 * Move Playwright install into pipeline module by @thomhurst in thomhurst/TUnit#5390 * perf: optimize solution build performance by @thomhurst in thomhurst/TUnit#5393 * perf: defer per-class JIT via lazy test registration + parallel resolution by @thomhurst in thomhurst/TUnit#5395 * Perf: Generate typed HandleCall<T1,...> overloads to eliminate argument boxing by @thomhurst in thomhurst/TUnit#5399 * perf: filter generated attributes to TUnit-related types only by @thomhurst in thomhurst/TUnit#5402 * fix: generate valid mock class names for generic interfaces with non-built-in type args by @thomhurst in thomhurst/TUnit#5404 ### Dependencies * chore(deps): update tunit to 1.27.0 by @thomhurst in thomhurst/TUnit#5392 * chore(deps): update dependency path-to-regexp to v8 by @thomhurst in thomhurst/TUnit#5378 **Full Changelog**: thomhurst/TUnit@v1.27.0...v1.28.0 ## 1.27.0 <!-- Release notes generated using configuration in .github/release.yml at v1.27.0 --> ## What's Changed ### Other Changes * Fix Dependabot security vulnerabilities in docs site by @thomhurst in thomhurst/TUnit#5372 * fix: use 0.0.0-scrubbed sentinel version in snapshot scrubber to avoid false Dependabot alerts by @thomhurst in thomhurst/TUnit#5374 * Speed up Engine.Tests by removing ProcessorCount parallelism cap by @thomhurst in thomhurst/TUnit#5379 * ci: add concurrency groups to cancel redundant workflow runs by @thomhurst in thomhurst/TUnit#5373 * Add scope-aware initialization and disposal OpenTelemetry spans to trace timeline and HTML report by @Copilot in thomhurst/TUnit#5339 * Add WithInnerExceptions() for fluent AggregateException assertion chaining by @thomhurst in thomhurst/TUnit#5380 * Drop net6.0 and net7.0 TFMs, keep net8.0+ and netstandard2.x by @thomhurst in thomhurst/TUnit#5387 * Remove all [Obsolete] members and migrate callers by @thomhurst in thomhurst/TUnit#5384 * Add AssertionResult.Failed overload that accepts an Exception by @thomhurst in thomhurst/TUnit#5388 ### Dependencies * chore(deps): update dependency mockolate to 2.3.0 by @thomhurst in thomhurst/TUnit#5370 * chore(deps): update tunit to 1.25.0 by @thomhurst in thomhurst/TUnit#5371 * chore(deps): update dependency minimatch to v9.0.9 by @thomhurst in thomhurst/TUnit#5375 * chore(deps): update dependency path-to-regexp to v0.2.5 by @thomhurst in thomhurst/TUnit#5376 * chore(deps): update dependency minimatch to v10 by @thomhurst in thomhurst/TUnit#5377 * chore(deps): update dependency picomatch to v4 by @thomhurst in thomhurst/TUnit#5382 * chore(deps): update dependency svgo to v4 by @thomhurst in thomhurst/TUnit#5383 * chore(deps): update dependency path-to-regexp to v1 [security] by @thomhurst in thomhurst/TUnit#5385 **Full Changelog**: thomhurst/TUnit@v1.25.0...v1.27.0 ## 1.25.0 <!-- Release notes generated using configuration in .github/release.yml at v1.25.0 --> ## What's Changed ### Other Changes * Fix missing `default` constraint on explicit interface implementations with unconstrained generics by @thomhurst in thomhurst/TUnit#5363 * feat(mocks): add ReturnsAsync typed factory overload with method parameters by @thomhurst in thomhurst/TUnit#5367 * Fix Arg.IsNull<T> and Arg.IsNotNull<T> to support nullable value types by @thomhurst in thomhurst/TUnit#5366 * refactor(mocks): use file-scoped types for generated implementation details by @thomhurst in thomhurst/TUnit#5369 * Compress HTML report JSON data and minify CSS by @thomhurst in thomhurst/TUnit#5368 ### Dependencies * chore(deps): update tunit to 1.24.31 by @thomhurst in thomhurst/TUnit#5356 * chore(deps): update dependency mockolate to 2.2.0 by @thomhurst in thomhurst/TUnit#5357 * chore(deps): update dependency polyfill to 9.24.1 by @thomhurst in thomhurst/TUnit#5365 * chore(deps): update dependency polyfill to 9.24.1 by @thomhurst in thomhurst/TUnit#5364 **Full Changelog**: thomhurst/TUnit@v1.24.31...v1.25.0 ## 1.24.31 <!-- Release notes generated using configuration in .github/release.yml at v1.24.31 --> ## What's Changed ### Other Changes * Fix Aspire 13.2.0+ timeout caused by ProjectRebuilderResource being awaited by @Copilot in thomhurst/TUnit#5335 * chore(deps): update dependency polyfill to 9.24.0 by @thomhurst in thomhurst/TUnit#5349 * Fix nullable IParsable type recognition in source generator and analyzer by @Copilot in thomhurst/TUnit#5354 * fix: resolve race condition in HookExecutionOrderTests by @thomhurst in thomhurst/TUnit#5355 * Fix MaxExternalSpansPerTest cap bypass when Activity.Parent chain is broken by @Copilot in thomhurst/TUnit#5352 ### Dependencies * chore(deps): update tunit to 1.24.18 by @thomhurst in thomhurst/TUnit#5340 * chore(deps): update dependency stackexchange.redis to 2.12.14 by @thomhurst in thomhurst/TUnit#5343 * chore(deps): update verify to 31.15.0 by @thomhurst in thomhurst/TUnit#5346 * chore(deps): update dependency polyfill to 9.24.0 by @thomhurst in thomhurst/TUnit#5348 **Full Changelog**: thomhurst/TUnit@v1.24.18...v1.24.31 ## 1.24.18 <!-- Release notes generated using configuration in .github/release.yml at v1.24.18 --> ## What's Changed ### Other Changes * feat(mocks): shorter, more readable generated mock type names by @thomhurst in thomhurst/TUnit#5334 * Fix DisposeAsync() ordering for nested property injection by @Copilot in thomhurst/TUnit#5337 ### Dependencies * chore(deps): update tunit to 1.24.13 by @thomhurst in thomhurst/TUnit#5331 **Full Changelog**: thomhurst/TUnit@v1.24.13...v1.24.18 ## 1.24.13 <!-- Release notes generated using configuration in .github/release.yml at v1.24.13 --> ## What's Changed ### Other Changes * perf(mocks): optimize MockEngine for lower allocation and faster verification by @thomhurst in thomhurst/TUnit#5319 * Remove defunct `UseTestingPlatformProtocol` reference for vscode by @erwinkramer in thomhurst/TUnit#5328 * perf(aspnetcore): prevent thread pool starvation during parallel WebApplicationTest server init by @thomhurst in thomhurst/TUnit#5329 * fix TUnit0073 for when type from from another assembly by @SimonCropp in thomhurst/TUnit#5322 * Fix implicit conversion operators bypassed in property injection casts by @Copilot in thomhurst/TUnit#5317 * fix(mocks): skip non-virtual 'new' methods when discovering mockable members by @thomhurst in thomhurst/TUnit#5330 * feat(mocks): IFoo.Mock() discovery with generic fallback and ORP resolution by @thomhurst in thomhurst/TUnit#5327 ### Dependencies * chore(deps): update tunit to 1.24.0 by @thomhurst in thomhurst/TUnit#5315 * chore(deps): update aspire to 13.2.1 by @thomhurst in thomhurst/TUnit#5323 * chore(deps): update verify to 31.14.0 by @thomhurst in thomhurst/TUnit#5325 ## New Contributors * @erwinkramer made their first contribution in thomhurst/TUnit#5328 **Full Changelog**: thomhurst/TUnit@v1.24.0...v1.24.13 ## 1.24.0 <!-- Release notes generated using configuration in .github/release.yml at v1.24.0 --> ## What's Changed ### Other Changes * perf: optimize TUnit.Mocks hot paths by @thomhurst in thomhurst/TUnit#5304 * fix: resolve System.Memory version conflict on .NET Framework (net462) by @thomhurst in thomhurst/TUnit#5303 * fix: resolve CS0460/CS0122/CS0115 when mocking concrete classes from external assemblies by @thomhurst in thomhurst/TUnit#5310 * feat(mocks): parameterless Returns() and ReturnsAsync() for async methods by @thomhurst in thomhurst/TUnit#5309 * Fix typo in NUnit manual migration guide by @aa-ko in thomhurst/TUnit#5312 * refactor(mocks): unify Mock.Of<T>() and Mock.OfPartial<T>() into single API by @thomhurst in thomhurst/TUnit#5311 * refactor(mocks): clean up Mock API surface by @thomhurst in thomhurst/TUnit#5314 * refactor(mocks): remove generic/untyped overloads from public API by @thomhurst in thomhurst/TUnit#5313 ### Dependencies * chore(deps): update tunit to 1.23.7 by @thomhurst in thomhurst/TUnit#5305 * chore(deps): update dependency mockolate to 2.1.1 by @thomhurst in thomhurst/TUnit#5307 ## New Contributors * @aa-ko made their first contribution in thomhurst/TUnit#5312 **Full Changelog**: thomhurst/TUnit@v1.23.7...v1.24.0 Commits viewable in [compare view](thomhurst/TUnit@v1.23.7...v1.28.7). </details> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This PR contains the following updates:
1.9.0→8.4.2Release Notes
pillarjs/path-to-regexp (path-to-regexp)
v8.4.2Compare Source
Fixed
9a78879Performance
937c02d57247e65844988Bundle size to 1.93 kB, from 1.97 kB.
v8.4.1Compare Source
Fixed
6bc8e84/*foowith/a/b=/a/*foo.htmlwith/a/b.html/c.html=/a/b.html5bcd30b/:"a"_:"b"against/foo__. This makes intuitive sense because the second parameter is not going to backtrack on_anymore, but it's somewhat unexpected since there's no reason it shouldn't match the second_.v8.4.0Compare Source
Important
Fixed
Changed
/users{/delete}it will restrict the number of generated combinations to < 256, equivalent to 8 top-level optional groups and unlikely to occur in a real world application, but avoids exploding the regex size for applications that accept user created routesv8.3.0Compare Source
Changed
2a7f2a4TokenData(#391)687a9bba4a8552a6bdf40Other
9df24484a91505d63f44b973d15cv8.2.0Compare Source
Fixed
path-to-regexpto run on older browsers by targeting ES20155969033sflag from regexp51dbd45v8.1.0Compare Source
Added
pathToRegexpmethod back for generating a regexstringifymethod for convertingTokenDatainto a path stringv8.0.0: Simpler APICompare Source
Heads up! This is a fairly large change (again) and I need to apologize in advance. If I foresaw what this version would have ended up being I would not have released version 7. A longer blog post and explanation will be incoming this week, but the pivot has been due to work on Express.js v5 and this will the finalized syntax used in Express moving forward.
Edit: The post is out - https://blakeembrey.com/posts/2024-09-web-redos/
Added
*namesyntax, aligns with:behavior but using an asterisk insteadChanged
?,+, and*- only optional exists moving forward (use wildcards for+,{*foo}for*)Added
:"foo-bar"string | TokenData | Array<string | TokenData>Removed
loosemodev7.2.0: Support array inputs (again)Compare Source
Added
matchandpathToRegexp3fdd88fv7.1.0: Strict modeCompare Source
Added
strictoption to detect potential ReDOS issuesFixed
suffix + prefixwhen not specifiedTokenDataTokenDatamanually, previouslyparsefilled it in automaticallyComments
strict: trueand I'm probably releasing a V8 with it enabled by default ASAP as a necessary security mitigationv7.0.0: Wildcard, unicode, and modifier changesCompare Source
Hi all! There's a few major breaking changes in this release so read carefully.
Breaking changes:
compileonly accepts strings as values (i.e. no numbers, useString(value)before compiling a path)encode !== false, it must be an array of strings\p{XID_Continue}).?,*,+) must be used after a param explicitly wrapped in{}/or.*) has been added back and matches Express.js expected behaviorendsWithoptionstrict: truetotrailing: false;,,,!, and@for future use-casestokensToRegexp,tokensToFunctionandregexpToFunctionin favor of simplifying exports/can be repeated multiple times in a matched path (i.e./fooworks like//foo, etc)encodeanddecodeno longer receive the token as the second parameterencodeURIComponentand decode defaults todecodeURIComponentAdded:
encodePathto fix an issue aroundencodebeing used for both path and parameters (the path and parameter should be encoded slightly differently)looseas an option to support arbitrarily matching the delimiter in paths, e.g.foo/barandfoo///barshould work the sameencodeanddecodeto be set tofalsewhich skips all processing of the parameters input/outputTokenData(exported, returned byparse) as inputRequests for feedback:
{}is an obvious drawback but I'm seeking feedback on whether it helps make path behavior clearer/and.as implicit prefixesv6.3.0: Fix backtracking in 6.xCompare Source
Fixed
f1253b4v6.2.2: Updated READMECompare Source
No API changes. Documentation only release.
Changed
c7ec332e828000v6.2.1: Fix matching:name*parameterCompare Source
Fixed
:name*parameter (#261)762bc6b86baef8Added
ae9e57677df638b39edd4v6.2.0: Named Capturing GroupsCompare Source
Added
Fixed
strictflag documentation (#227)v6.1.0: Use/#?as Default DelimiterCompare Source
Fixed
/#?as default delimiter to avoid matching on query or fragment parametersdelimiter: '.'v6.0.0: Custom Prefix and Suffix GroupsCompare Source
This release reverts the prefix behavior added in v3 back to the behavior seen in v2. For the most part, path matching is backward compatible with v2 with these enhancements:
/(abc(?=d))/{abc(.*)def}/test(foopreviously worked treating(as a literal character, now it expects(to be closed and is treated as a group/test\(fooChanged
prefixesoption to configure this (starts as/.which acts like every version since 0.x again){}to capture prefix/suffix explicitly, enables custom use-cases like/:attr1{-:attr2}?v5.0.0: Remove Default Encode URI ComponentCompare Source
No changes to path rules since 3.x, except support for nested RegEx parts in 4.x.
Changed
RegexpOptionsinterface toTokensToRegexpOptionsnormalizePathnamefrom library, document solution in READMEencodeURIComponentv4.0.5: Decode URICompare Source
Removed
whitelistin favor ofdecodeURI(advanced behavior can happen outsidepath-to-regexp)v4.0.4: RemoveString#normalizeCompare Source
Fixed
String.prototype.normalizeto continue supporting IEv4.0.3: Normalize Path WhitelistCompare Source
Added
/%.-)v4.0.2: AllowRegexpOptionsinmatchCompare Source
Fixed
RegexpOptionsinmatch(...)functionv4.0.1: Fix Spelling of RegexpCompare Source
Fixed
regexpspelling across 4.xv4.0.0: ES2015 Package for BundlersCompare Source
All path rules are backward compatible with 3.x, except for nested
()and other RegEx special characters that were previously ignored.Changed
matchdoes not default todecodeURIComponentAdded
normalizePathnameutility for supporting unicode paths in librariesv3.3.0: Add backtracking protectionCompare Source
Fixed
d31670av3.2.0: Match FunctionCompare Source
Added
matchfunction to libraryv3.1.0: Validate and sensitive optionsCompare Source
sensitiveoption fortokensToFunction(#191)validateoption to path functions (#178)v3.0.0Compare Source
/:att1-:att2-:att3-:att4-:att5)partialsupport, prefer escaping the prefix delimiter explicitly (e.g.\\/(apple-)?icon-:res(\\d+).png)v2.4.0Compare Source
startoption to disable anchoring from beginning of the stringv2.3.0Compare Source
delimiterwhen processing repeated matching groups (e.g.foo/barhas no prefix, but has a delimiter)v2.2.1Compare Source
end: falseto match both relative and absolute pathsv2.2.0Compare Source
tokenas second argument toencodeoption (e.g.encode(value, token))v2.1.0Compare Source
/foo/before required either/foo/or/foo//to match in non-ending modev2.0.0Compare Source
endsWithto match paths like/test?query=stringup to the query stringdelimitersfor specific characters to be treated as parameter prefixes (e.g./:test)isarraydependency/test/is now treated as/test/instead of/testwhen matching)keysargument that acceptedoptionskeyslist attached to theRegExpoutputtokensToFunction(e.g.compile) to accept anencodefunction for pretty encoding (e.g. pass your own implementation)Configuration
📅 Schedule: (UTC)
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Renovate Bot.