Skip to content

Backport yamux fix#1040

Merged
gilescope merged 6 commits into
release/node-0.22.1from
backport-bump-yamux
Mar 19, 2026
Merged

Backport yamux fix#1040
gilescope merged 6 commits into
release/node-0.22.1from
backport-bump-yamux

Conversation

@gilescope

@gilescope gilescope commented Mar 19, 2026

Copy link
Copy Markdown
Contributor

Overview

Backport fix for yamux vulnerability GHSA-vxx9-2994-q338. A malicious peer could crash a node by sending crafted yamux frames that trigger a panic via checked_add(...).expect(...) overflow in increase_send_window_by.

Changes:

  • Bump yamux 0.13.8 → 0.13.10 (contains the fix)
  • Patch yamux 0.12.1 → 0.12.2 via custom fork (midnightntwrk/rust-yamux) since upstream 0.12.x has no fix
  • Add regression tests verifying the node does not panic on:
    • WindowUpdate with u32::MAX credit (overflow)
    • Oversized Data|SYN frame exceeding default credit
    • Two consecutive WindowUpdates that together overflow

🗹 TODO before merging

  • Ready

📌 Submission Checklist

  • Changes are backward-compatible (or flagged if breaking)
  • Pull request description explains why the change is needed
  • Self-reviewed the diff
  • I have included a change file, or skipped for this reason: security fix backport
  • If the changes introduce a new feature, I have bumped the node minor version
  • Update documentation (if relevant)
  • Updated AGENTS.md if build commands, architecture, or workflows changed
  • No new todos introduced

🧪 Testing Evidence

  • Additional tests are provided (if possible)

Three regression tests added in node/tests/yamux_vulnerability.rs that reproduce the attack vectors from the advisory and verify the patched yamux handles them gracefully (no panic).

🔱 Fork Strategy

  • Node Runtime Update
  • Node Client Update
  • Other:
  • N/A

Links

Signed-off-by: Giles Cope <gilescope@gmail.com>
Signed-off-by: Giles Cope <gilescope@gmail.com>
Signed-off-by: Giles Cope <gilescope@gmail.com>
Signed-off-by: Giles Cope <gilescope@gmail.com>
Signed-off-by: Giles Cope <gilescope@gmail.com>
@gilescope gilescope requested a review from a team as a code owner March 19, 2026 19:34
Signed-off-by: Giles Cope <gilescope@gmail.com>
@gilescope gilescope merged commit 9ce4578 into release/node-0.22.1 Mar 19, 2026
48 of 50 checks passed
@gilescope gilescope deleted the backport-bump-yamux branch March 19, 2026 21:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant