Skip to content
This repository was archived by the owner on Jun 25, 2026. It is now read-only.

Override brace-expansion to patched versions to resolve DoS advisory#91

Merged
fastjames merged 1 commit into
masterfrom
deps/brace-expansion-advisory
Jun 24, 2026
Merged

Override brace-expansion to patched versions to resolve DoS advisory#91
fastjames merged 1 commit into
masterfrom
deps/brace-expansion-advisory

Conversation

@fastjames

Copy link
Copy Markdown

Resolves the brace-expansion advisories (GHSA-f886-m6hf-6m8v zero-step-sequence DoS, GHSA-jxxr-4gwj-5jf2 numeric-range max bypass).

Problem

Three transitive copies of brace-expansion, in three different major ranges, were vulnerable:

eslint       -> minimatch@10 -> brace-expansion@5.0.5
jest-circus  -> ...          -> minimatch@9  -> brace-expansion@2.0.2
ts-jest      -> ...          -> minimatch@3  -> brace-expansion@1.1.12

Fix

Because the advisory spans majors 1.x / 2.x / 5.x, a single override can't fix all three without forcing one major onto incompatible minimatch consumers. Instead, version-targeted overrides bump each range to its own patched release:

"overrides": {
  "brace-expansion@1": "^1.1.13",
  "brace-expansion@2": "^2.0.3",
  "brace-expansion@5": "^5.0.6"
}

Result: 1.1.12 -> 1.1.15, 2.0.2 -> 2.1.1, 5.0.5 -> 5.0.6. Lockfile-only beyond the overrides block.

Note: npm audit fix also clears this advisory, but it drags in unrelated @babel/core/browserslist bumps that overlap #89. These targeted overrides keep the change scoped to brace-expansion alone.

Verification (node v24.14.0, per engines: >= 24)

  • npm run build (tsc) — passes
  • npm test37 passed, 4 suites
  • npm audit — brace-expansion advisory no longer present

Note

The remaining advisories are tracked separately: @babel/core in #89 and the js-yaml istanbul chain in #90.

@coderabbitai

coderabbitai Bot commented Jun 24, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: a367ea5a-f161-4f8d-a715-aeb7b6ee546a

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch deps/brace-expansion-advisory

Comment @coderabbitai help to get the list of available commands.

@fastjames fastjames self-assigned this Jun 24, 2026
@fastjames
fastjames requested a review from k1bs June 24, 2026 16:20

@k1bs k1bs left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🍰

Three transitive copies of brace-expansion were vulnerable to the
zero-step-sequence DoS (GHSA-f886-m6hf-6m8v) and numeric-range max
bypass (GHSA-jxxr-4gwj-5jf2):

  eslint -> minimatch@10 -> brace-expansion@5.0.5
  jest-circus -> ... -> minimatch@9 -> brace-expansion@2.0.2
  ts-jest -> ... -> test-exclude -> minimatch@3 -> brace-expansion@1.1.12

The advisory spans three major ranges, so version-targeted npm
overrides bump each to its respective patched release (1.1.15 /
2.1.1 / 5.0.6) without forcing a single major across incompatible
consumers. Build and all 37 tests pass on node 24.
@fastjames
fastjames force-pushed the deps/brace-expansion-advisory branch from a1bdf1a to ee8e4ef Compare June 24, 2026 16:31
@fastjames
fastjames merged commit 55e89e7 into master Jun 24, 2026
11 checks passed
@fastjames
fastjames deleted the deps/brace-expansion-advisory branch June 24, 2026 16:35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants