Skip to content

๐Ÿšจ [security] Update vue-router 4.6.4 โ†’ 5.2.0 (major) - #2784

Open
depfu[bot] wants to merge 1 commit into
developfrom
depfu/update/npm/vue-router-5.2.0
Open

๐Ÿšจ [security] Update vue-router 4.6.4 โ†’ 5.2.0 (major)#2784
depfu[bot] wants to merge 1 commit into
developfrom
depfu/update/npm/vue-router-5.2.0

Conversation

@depfu

@depfu depfu Bot commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

๐Ÿšจ Your current dependencies have known security vulnerabilities ๐Ÿšจ

This dependency update fixes known security vulnerabilities. Please see the details below and assess their impact carefully. We recommend to merge and deploy this as soon as possible!


Here is everything you need to know about this upgrade. Please take a good look at what changed and the test results before merging this pull request.

What changed?

โœณ๏ธ vue-router (4.6.4 โ†’ 5.2.0) ยท Repo

Release Notes

5.2.0

ย ย ย ๐Ÿš€ Features

ย ย ย ๐Ÿž Bug Fixes

ย ย ย ย View changes on GitHub

5.1.0

ย ย ย ๐Ÿš€ Features

  • Typed definePage params.path ย -ย  by @posva in #2716 (d65de)
  • Strict type for definePage param default ย -ย  by @posva (0ae10)
  • Support raw param parsers ย -ย  by @posva (eadec)
  • Force array type raw param parsers ย -ย  by @posva (7a68b)
  • Allow overriding the global Router type ย -ย  by @posva (1cd93)
  • Emit runtime warning for invalid format in query params ย -ย  by @posva (8259a)
  • Override useRouter() return with experimental types config ย -ย  by @posva (39a34)
  • Allow string as a param parser for convenience ย -ย  by @posva (be37b)

ย ย ย ๐Ÿž Bug Fixes

  • Fix auto import fixes and make experimental esm only ย -ย  by @posva (db3a6)
  • Deterministic param parser types order ย -ย  by @posva (bf0fc)
  • Avoid importing unused param parsers ย -ย  by @posva (41c00)
  • Filter invalid query params without failing to match ย -ย  by @posva (db717)
  • Detect not set format ย -ย  by @posva (aa89e)
  • Allow undefined values for params in query ย -ย  by @posva (4726e)
  • experimental: Repeatable params in subsegments ย -ย  by @posva (84664)
  • types: Add vite as optional peer dependency ย -ย  by @ForgottenR, @posva and shihuijie in #2712 (facbf)
ย ย ย ย View changes on GitHub

5.0.7

ย ย ย ๐Ÿš€ Features

  • Upgrade to babel 8 ย -ย  by @posva (8d3e6)
  • Make defineParamParser() more intuitive ย -ย  by @posva (8715b)
  • Upgrade @vue/devtools-api ย -ย  by @posva (87c3a)
  • matcher: Hint at params: {} workaround in discarded params warning ย -ย  by @posva and shanliuling in #2689 (c2b13)
  • param-parsers: Add include/exclude options ย -ย  by @posva (91cde)

ย ย ย ๐Ÿž Bug Fixes

ย ย ย ย View changes on GitHub

5.0.6

ย ย ย ๐Ÿž Bug Fixes

ย ย ย ย View changes on GitHub

5.0.5

ย ย ย ๐Ÿš€ Features

ย ย ย ๐Ÿž Bug Fixes

  • Track definePage imports per-file to fix named view race condition ย -ย  by @posva (11191)
  • Avoid double decoding hash on string location ย -ย  by @posva (1578c)
ย ย ย ย View changes on GitHub

5.0.4

ย ย ย ๐Ÿž Bug Fixes

  • Avoid iterator helpers for Node 20 compat ย -ย  by @cwandev in #2635 (47130)
  • Escape backslahes in string literals ย -ย  by @posva (71fdb)
  • Avoid false duplicate route warning for named views ย -ย  by @posva (72012)
  • Allow pushing to auto routes ย -ย  by @posva (47f03)
  • loaders: Restore context in sequential awaits ย -ย  by @posva (fce5d)
ย ย ย ย View changes on GitHub

5.0.3

ย ย ย ๐Ÿšจ Breaking Changes

  • experimental:
    • Make miss() throw internally and return never ย -ย  by @posva (077e1)
    • Add reroute() and deprecate NavigationResult ย -ย  by @posva (308db)
    • Remove selectNavigationResult ย -ย  by @posva (9e88a)

ย ย ย ๐Ÿš€ Features

  • Support _parent in nested folders ย -ย  by @posva (0a37f)
  • Warn on _parent conflict ย -ย  by @posva (182fe)
  • Set _parent as non matchable by default ย -ย  by @posva (8f91c)
  • Warn on conflicting components for routes ย -ย  by @posva (34ace)
  • Use type module ย -ย  by @posva (dc9ff)
  • Add deprecation warning for next() callback in navigation guards ย -ย  by @posva (797f5)
  • Extract alias from definePage ย -ย  by @posva (835df)
  • Display aliases in logs ย -ย  by @posva (7aa60)
  • Deprecate new NavigationResult(to) in favor of reroute(to) ย -ย  by @posva (382e3)
  • experimental:
    • Handle aliasOf in resolvers ย -ย  by @posva (8fe45)
    • Generate aliases from override in resolver ย -ย  by @posva (a00ac)
    • Warn against non absolute aliases ย -ย  by @posva (476c6)

ย ย ย ๐Ÿž Bug Fixes

  • Avoid non matchable routes in auto-routes ย -ย  by @posva (48649)
  • Handle quotes in d.ts ย -ย  by @posva (d7764)
  • Avoid route entry in map for _parent ย -ย  by @posva (1dfcc)
  • Handle nested groups ย -ย  by @posva (4a4be)
  • Stable route ordering for group folders with same path ย -ย  by @posva (1db94)
  • Correct route ordering for group nodes with inflated scores ย -ย  by @posva (515f4)
  • Cleanup old route overrides ย -ย  by @posva (b28a7)
  • Remove name from _parent.vue files ย -ย  by @posva (6e8f1)
  • ci:
    • Format sponsor files before change detection ย -ย  by @posva (f68d6)
    • Use manual git commit in update-sponsors ย -ย  by @posva (8ee99)
  • experimental:
    • Resolve TS errors in resolver/router type hierarchy ย -ย  by @posva (a86f1)
  • types:
  • volar:

ย ย ย ๐ŸŽ Performance

  • Avoid merging empty object in record ย -ย  by @posva (4213e)
ย ย ย ย View changes on GitHub

5.0.2

ย ย ย ๐Ÿž Bug Fixes

ย ย ย ย View changes on GitHub

5.0.0

Vue Router 5 is a boring release, it merges unplugin-vue-router into the core package with no breaking changes. The only exception is that the iife build no longer includes @vue/devtools-api because it has been upgraded to v8 and does not expose an IIFE build itself. You can track that change in this issue. See the migration guide for instructions on how to upgrade from unplugin-vue-router to Vue Router 5.

ย ย ย ๐Ÿš€ Features

ย ย ย ๐Ÿž Bug Fixes

ย ย ย ย View changes on GitHub

Does any of this look wrong? Please let us know.

Commits

See the full diff on Github. The new version differs by more commits than we can show here.

โ†—๏ธ yaml (indirect, 2.8.2 โ†’ 2.9.0) ยท Repo

Security Advisories ๐Ÿšจ

๐Ÿšจ yaml is vulnerable to Stack Overflow via deeply nested YAML collections

Parsing a YAML document with yaml may throw a RangeError due to a stack overflow.

The node resolution/composition phase uses recursive function calls without a depth bound. An attacker who can supply YAML for parsing can trigger a RangeError: Maximum call stack size exceeded with a small payload (~2โ€“10 KB). The RangeError is not a YAMLParseError, so applications that only catch YAML-specific errors will encounter an unexpected exception type. Depending on the host application's exception handling, this can fail requests or terminate the Node.js process.

Flow sequences allow deep nesting with minimal bytes (2 bytes per level: one [ and one ]). On the default Node.js stack, approximately 1,000โ€“5,000 levels of nesting (2โ€“10 KB input) exhaust the call stack. The exact threshold is environment-dependent (Node.js version, stack size, call stack depth at invocation).

Note: the library's Parser (CST phase) uses a stack-based iterative approach and is not affected. Only the compose/resolve phase uses actual call-stack recursion.

All three public parsing APIs are affected: YAML.parse(), YAML.parseDocument(), and YAML.parseAllDocuments().

PoC

const YAML = require('yaml');

// ~10 KB payload: 5000 levels of nested flow sequences
const payload = '['.repeat(5000) + '1' + ']'.repeat(5000);

try {
YAML.parse(payload);
} catch (e) {
console.log(e.constructor.name); // RangeError (NOT YAMLParseError)
console.log(e.message); // Maximum call stack size exceeded
}

Test environment: Node.js v24.12.0, macOS darwin arm64

Version Nesting Depth Input Size Result
1.0.0 5,000 10,001 B RangeError
1.10.2 5,000 10,001 B RangeError
2.0.0 5,000 10,001 B RangeError
2.8.2 5,000 10,001 B RangeError
2.8.3 5,000 10,001 B YAMLParseError

Depth threshold on yaml 2.8.2:

Nesting Depth Input Size Result
500 1,001 B Parses successfully
1,000 2,001 B RangeError (threshold varies by stack size)
5,000 10,001 B RangeError
Release Notes

2.9.0

The changes here are really only patches, but I'm releasing this as a minor version to note a small change to the documentation of parseDocument() and parseAllDocuments(): I've removed the claim that they'll "never throw".

It remains the case that practically all non-malicious inputs will be handled without emitting an error, but there is a decent chance that code paths remain where e.g. a RangeError due to call stack exhaustion can be triggered by malicious inputs. Up to now, I've considered these as security vulnerabilities, and in fact it's the only category of error for which yaml CVEs have been issued so far.

Starting from this release, I'll be considering such errors as bugs, but not vulnerabilities. I do welcome people and/or LLMs looking for them, but please report them as normal issues rather than suspected security vulnerabilities. This also applies to previously undiscovered bugs in earlier releases.

  • fix: Avoid calling Array.prototype.push.apply() with large source array
  • fix(lexer): Avoid recursive calls that may exhaust the call stack

2.8.4

  • Disable alias resolution with maxAliasCount:0 (#677)
  • Handle invalid unicode escapes (e1a1a77)
  • Apply minFractionDigits only to decimal strings (#676)

2.8.3

  • Add trailingComma ToString option for multiline flow formatting (#670)
  • Catch stack overflow during node composition (1e84ebb)

Does any of this look wrong? Please let us know.

Commits

See the full diff on Github. The new version differs by 19 commits:

๐Ÿ†• @โ€‹types/jsesc (added, 2.5.1)

๐Ÿ†• @โ€‹vue-macros/common (added, 3.1.4)

๐Ÿ†• ast-kit (added, 2.2.0)

๐Ÿ†• ast-walker-scope (added, 0.9.0)

๐Ÿ†• confbox (added, 0.2.4)

๐Ÿ†• confbox (added, 0.1.8)

๐Ÿ†• exsolve (added, 1.1.1)

๐Ÿ†• local-pkg (added, 1.2.1)

๐Ÿ†• magic-string-ast (added, 1.0.3)

๐Ÿ†• mlly (added, 1.8.2)

๐Ÿ†• pkg-types (added, 1.3.1)

๐Ÿ†• pkg-types (added, 2.3.1)

๐Ÿ†• muggle-string (added, 0.4.1)

๐Ÿ†• quansync (added, 0.2.11)

๐Ÿ†• scule (added, 1.3.0)

๐Ÿ†• ufo (added, 1.6.4)

๐Ÿ†• unplugin (added, 3.3.0)

๐Ÿ†• webpack-virtual-modules (added, 0.6.2)

๐Ÿ†• @โ€‹babel/generator (added, 8.0.0)

๐Ÿ†• @โ€‹babel/helper-string-parser (added, 8.0.0)

๐Ÿ†• @โ€‹babel/helper-validator-identifier (added, 8.0.4)

๐Ÿ†• @โ€‹babel/parser (added, 8.0.4)

๐Ÿ†• @โ€‹babel/types (added, 8.0.4)

๐Ÿ†• chokidar (added, 5.0.0)

๐Ÿ†• readdirp (added, 5.1.1)

๐Ÿ—‘๏ธ @โ€‹vue/devtools-api (removed)


Depfu Status

Depfu will automatically keep this PR conflict-free, as long as you don't add any commits to this branch yourself. You can also trigger a rebase manually by commenting with @depfu rebase.

All Depfu comment commands
@โ€‹depfu rebase
Rebases against your default branch and redoes this update
@โ€‹depfu recreate
Recreates this PR, overwriting any edits that you've made to it
@โ€‹depfu merge
Merges this PR once your tests are passing and conflicts are resolved
@โ€‹depfu cancel merge
Cancels automatic merging of this PR
@โ€‹depfu close
Closes this PR and deletes the branch
@โ€‹depfu reopen
Restores the branch and reopens this PR (if it's closed)
@โ€‹depfu pause
Ignores all future updates for this dependency and closes this PR
@โ€‹depfu pause [minor|major]
Ignores all future minor/major updates for this dependency and closes this PR
@โ€‹depfu resume
Future versions of this dependency will create PRs again (leaves this PR as is)

@depfu depfu Bot added dependencies Pull requests that update a dependency file Technical Debt Technical debt labels Jul 22, 2026
@depfu
depfu Bot force-pushed the depfu/update/npm/vue-router-5.2.0 branch 3 times, most recently from be2fa17 to 84f0e7f Compare July 27, 2026 19:00
@depfu
depfu Bot force-pushed the depfu/update/npm/vue-router-5.2.0 branch from 84f0e7f to 49d3796 Compare August 13, 2026 03:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file Technical Debt Technical debt

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants