Skip to content

fix(deps): resolve Dependabot alerts for postcss, fast-uri, dompurify, brace-expansion - #4398

Merged
cixzhang merged 1 commit into
mainfrom
fix/dependency-vulnerabilities-20260726
Jul 27, 2026
Merged

cixzhang merged 1 commit into
mainfrom
fix/dependency-vulnerabilities-20260726

Conversation

@cixzhang

Copy link
Copy Markdown
Contributor

Resolves 5 open Dependabot alerts (4 high, 1 low) by bumping pnpm overrides in pnpm-workspace.yaml:

Package Previous Patched Severity CVE
postcss ^8.5.10 ^8.5.18 high Path traversal in source map auto-loading
fast-uri (none) ^3.1.4 high Host confusion via literal backslash
brace-expansion (none) ^2.1.2 high DoS via exponential-time expansion
dompurify ^3.4.11 ^3.4.12 low CUSTOM_ELEMENT_HANDLING bypass

All transitive (Tier 1) -- no direct API surface changes.

Not addressed in this PR (require human review):

  • next 15.5.20 -> 15.5.21: blocked by minimumReleaseAge (published 2026-07-21, clears quarantine 2026-07-28). Will auto-resolve on next lockfile refresh after that date.
  • js-yaml 4.x -> 5.x: major version bump (separate issue filed)
  • sharp 0.34 -> 0.35: major version bump (separate issue filed)
  • @hono/node-server 1.x -> 2.x: major version bump (separate issue filed)

Verification: pnpm install + pnpm build + pnpm test --run (380 files, 7746 tests, all green).

Night Watch — Dependencies

…, brace-expansion

Bump pnpm overrides to patched versions:
- postcss: ^8.5.10 -> ^8.5.18 (path traversal in source map loading)
- dompurify: ^3.4.11 -> ^3.4.12 (CUSTOM_ELEMENT_HANDLING bypass)
- fast-uri: ^3.1.4 (new override, host confusion via backslash)
- brace-expansion: ^2.1.2 (new override, DoS via exponential expansion)

Verified: pnpm install + build + test (380 files, 7746 tests pass).
@vercel

vercel Bot commented Jul 26, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
astryx Ready Ready Preview, Comment Jul 26, 2026 1:28pm

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jul 26, 2026
github-actions Bot added a commit that referenced this pull request Jul 26, 2026
@github-actions

Copy link
Copy Markdown
Contributor

PR Analysis Report

📚 Storybook Preview

View Storybook for this PR
GitHub Pages may take up to a minute to hydrate after deploy.

🧪 Sandbox Preview

View Sandbox for this PR
GitHub Pages may take up to a minute to hydrate after deploy.

No new or modified components detected.

Bundle Size Summary

Package Size (ESM) Size (CJS) Gzipped
@astryxdesign/core N/A 4.7KB 0B

Accessibility Audit

Status: No accessibility violations detected.


Generated by PR Enrichment workflow | Storybook | Sandbox | View full report

@cixzhang
cixzhang merged commit d57e546 into main Jul 27, 2026
18 checks passed
@github-actions
github-actions Bot deleted the fix/dependency-vulnerabilities-20260726 branch July 28, 2026 06:57
cixzhang pushed a commit that referenced this pull request Jul 28, 2026
next pulls sharp as an optional dependency for image optimization and
resolves 0.34.5, which inherits four libvips advisories: CVE-2026-33327,
CVE-2026-33328, CVE-2026-35590 and CVE-2026-35591.

They are patched in sharp 0.35.0, a semver-major bump on the 0.x line, so
next's own `^0.34` range can never reach it — hence an override rather than a
lockfile refresh. Both next entries in the tree (15.5.20 and
16.3.0-preview.5) resolve through it, and the platform packages move with
it: `@img/sharp-libvips-*` goes 1.2.4 to 1.3.2, which is where the actual
fix lives.

sharp is already in `allowBuilds`, so the native postinstall is unchanged.
0.35.3 published 2026-07-01, well clear of the repo's 7-day
`minimumReleaseAge`.

The override is temporary by construction — the comment says to drop it once
next depends on 0.35 itself.

Verified beyond the lockfile, since the concern with this bump is the native
binary and next's image pipeline rather than the resolution:
  - sharp 0.35.3 loads and reports libvips 8.18.3
  - it round-trips a real encode (create -> .png() -> Buffer)
  - `pnpm build` (core, lab, charts, vega, 7 themes) succeeds
  - `pnpm -F @astryxdesign/docsite build` succeeds — a full next build with
    prerendering, which is where image optimization would surface
  - `pnpm test`: 384 files, 7871 tests, all pass

No changeset: this touches no published package's source, matching #3889 and
#4398, which were both lockfile + pnpm-workspace.yaml only.

Fixes #4400
sangwook-dev added a commit to sangwook-dev/astryx that referenced this pull request Jul 29, 2026
…atalog

Re-verified every override entry by removing it, re-resolving the lockfile, and running pnpm audit. The entries that no longer do anything useful are removed: stylex, tmp, @babel/core, hono, both scoped js-yaml floors and the picomatch trio carried over from yarn resolutions all resolve identically without the override, and prettier and minimatch were dedup-only forces whose removal lets consumers follow their own declared ranges.

brace-expansion ^2.1.2 goes too. It was added in meta#4398 as a security floor, but 2.x sits below the declared range of every consumer in the graph — minimatch@10 (via @eslint/config-array) declares ^5.0.5, minimatch@3 (via @babel/cli) declares ^1.1.7 — so it was a downgrade, not a floor. It stayed invisible only because the equally stale minimatch ^9.0.7 force held minimatch on a line that still used brace-expansion's default CJS export. Dropping minimatch alone lets @eslint/config-array resolve minimatch 10, which calls the named `expand` that 2.x does not have, and ESLint dies with "brace_expansion_1.expand is not a function". Dropping both lets each consumer resolve inside its own range (5.0.7 and 1.1.16) and ESLint runs clean.

The entries that guard live advisories stay, documented with the dependent that pins the vulnerable version and the condition for deleting them: postcss ^8.5.18 (next@15 pins 8.4.31), dompurify ^3.4.12 ([email protected] pins 3.2.7, 16 advisories), esbuild >=0.28.1 ([email protected] resolves 0.27.7), fast-uri ^3.1.4 (meta#4398), sharp ^0.35.3 (meta#4449), and the read-yaml-file 2.x lift.

Both js-yaml chains move to ^5.2.2, adopting the fix in meta#4402 — the previous '>=4.2.0' floor was unbounded and resolved onto js-yaml 5.2.1, inside the vulnerable >=5.0.0 <=5.2.1 range. Written as a caret rather than '>=' so a future js-yaml 6 cannot repeat that. [email protected] is added to minimumReleaseAgeExclude so the floor can resolve.

Workspace-wide version pins that lived in overrides move to the pnpm catalog alongside vite: @stylexjs/stylex, @stylexjs/babel-plugin, prettier, esbuild. Peer ranges stay untouched — they are consumer contracts, not workspace pins.

pnpm audit goes from 12 findings to 10; the remaining 10 match main's baseline exactly.
sangwook-dev added a commit to sangwook-dev/astryx that referenced this pull request Jul 31, 2026
…atalog

Re-verified every override entry by removing it, re-resolving the lockfile, and running pnpm audit. The entries that no longer do anything useful are removed: stylex, tmp, @babel/core, hono, both scoped js-yaml floors and the picomatch trio carried over from yarn resolutions all resolve identically without the override, and prettier and minimatch were dedup-only forces whose removal lets consumers follow their own declared ranges.

brace-expansion ^2.1.2 goes too. It was added in meta#4398 as a security floor, but 2.x sits below the declared range of every consumer in the graph — minimatch@10 (via @eslint/config-array) declares ^5.0.5, minimatch@3 (via @babel/cli) declares ^1.1.7 — so it was a downgrade, not a floor. It stayed invisible only because the equally stale minimatch ^9.0.7 force held minimatch on a line that still used brace-expansion's default CJS export. Dropping minimatch alone lets @eslint/config-array resolve minimatch 10, which calls the named `expand` that 2.x does not have, and ESLint dies with "brace_expansion_1.expand is not a function". Dropping both lets each consumer resolve inside its own range (5.0.7 and 1.1.16) and ESLint runs clean.

The entries that guard live advisories stay, documented with the dependent that pins the vulnerable version and the condition for deleting them: postcss ^8.5.18 (next@15 pins 8.4.31), dompurify ^3.4.12 ([email protected] pins 3.2.7, 16 advisories), esbuild >=0.28.1 ([email protected] resolves 0.27.7), fast-uri ^3.1.4 (meta#4398), sharp ^0.35.3 (meta#4449), and the read-yaml-file 2.x lift.

Both js-yaml chains move to ^5.2.2, adopting the fix in meta#4402 — the previous '>=4.2.0' floor was unbounded and resolved onto js-yaml 5.2.1, inside the vulnerable >=5.0.0 <=5.2.1 range. Written as a caret rather than '>=' so a future js-yaml 6 cannot repeat that. [email protected] is added to minimumReleaseAgeExclude so the floor can resolve.

Workspace-wide version pins that lived in overrides move to the pnpm catalog alongside vite: @stylexjs/stylex, @stylexjs/babel-plugin, prettier, esbuild. Peer ranges stay untouched — they are consumer contracts, not workspace pins.

pnpm audit goes from 12 findings to 10; the remaining 10 match main's baseline exactly.
sangwook-dev added a commit to sangwook-dev/astryx that referenced this pull request Aug 20, 2026
…atalog

Re-verified every override entry by removing it, re-resolving the lockfile, and running pnpm audit. The entries that no longer do anything useful are removed: stylex, tmp, @babel/core, hono, both scoped js-yaml floors and the picomatch trio carried over from yarn resolutions all resolve identically without the override, and prettier and minimatch were dedup-only forces whose removal lets consumers follow their own declared ranges.

brace-expansion ^2.1.2 goes too. It was added in meta#4398 as a security floor, but 2.x sits below the declared range of every consumer in the graph — minimatch@10 (via @eslint/config-array) declares ^5.0.5, minimatch@3 (via @babel/cli) declares ^1.1.7 — so it was a downgrade, not a floor. It stayed invisible only because the equally stale minimatch ^9.0.7 force held minimatch on a line that still used brace-expansion's default CJS export. Dropping minimatch alone lets @eslint/config-array resolve minimatch 10, which calls the named `expand` that 2.x does not have, and ESLint dies with "brace_expansion_1.expand is not a function". Dropping both lets each consumer resolve inside its own range (5.0.7 and 1.1.16) and ESLint runs clean.

The entries that guard live advisories stay, documented with the dependent that pins the vulnerable version and the condition for deleting them: postcss ^8.5.18 (next@15 pins 8.4.31), dompurify ^3.4.12 ([email protected] pins 3.2.7, 16 advisories), esbuild >=0.28.1 ([email protected] resolves 0.27.7), fast-uri ^3.1.4 (meta#4398), sharp ^0.35.3 (meta#4449), and the read-yaml-file 2.x lift.

Both js-yaml chains move to ^5.2.2, adopting the fix in meta#4402 — the previous '>=4.2.0' floor was unbounded and resolved onto js-yaml 5.2.1, inside the vulnerable >=5.0.0 <=5.2.1 range. Written as a caret rather than '>=' so a future js-yaml 6 cannot repeat that. [email protected] is added to minimumReleaseAgeExclude so the floor can resolve.

Workspace-wide version pins that lived in overrides move to the pnpm catalog alongside vite: @stylexjs/stylex, @stylexjs/babel-plugin, prettier, esbuild. Peer ranges stay untouched — they are consumer contracts, not workspace pins.

pnpm audit goes from 12 findings to 10; the remaining 10 match main's baseline exactly.

� Conflicts:
�	pnpm-workspace.yaml
cixzhang pushed a commit that referenced this pull request Aug 22, 2026
…atalog (#4101)

* chore(deps): prune stale pnpm overrides, move workspace pins to the catalog

Re-verified every override entry by removing it, re-resolving the lockfile, and running pnpm audit. The entries that no longer do anything useful are removed: stylex, tmp, @babel/core, hono, both scoped js-yaml floors and the picomatch trio carried over from yarn resolutions all resolve identically without the override, and prettier and minimatch were dedup-only forces whose removal lets consumers follow their own declared ranges.

brace-expansion ^2.1.2 goes too. It was added in #4398 as a security floor, but 2.x sits below the declared range of every consumer in the graph — minimatch@10 (via @eslint/config-array) declares ^5.0.5, minimatch@3 (via @babel/cli) declares ^1.1.7 — so it was a downgrade, not a floor. It stayed invisible only because the equally stale minimatch ^9.0.7 force held minimatch on a line that still used brace-expansion's default CJS export. Dropping minimatch alone lets @eslint/config-array resolve minimatch 10, which calls the named `expand` that 2.x does not have, and ESLint dies with "brace_expansion_1.expand is not a function". Dropping both lets each consumer resolve inside its own range (5.0.7 and 1.1.16) and ESLint runs clean.

The entries that guard live advisories stay, documented with the dependent that pins the vulnerable version and the condition for deleting them: postcss ^8.5.18 (next@15 pins 8.4.31), dompurify ^3.4.12 ([email protected] pins 3.2.7, 16 advisories), esbuild >=0.28.1 ([email protected] resolves 0.27.7), fast-uri ^3.1.4 (#4398), sharp ^0.35.3 (#4449), and the read-yaml-file 2.x lift.

Both js-yaml chains move to ^5.2.2, adopting the fix in #4402 — the previous '>=4.2.0' floor was unbounded and resolved onto js-yaml 5.2.1, inside the vulnerable >=5.0.0 <=5.2.1 range. Written as a caret rather than '>=' so a future js-yaml 6 cannot repeat that. [email protected] is added to minimumReleaseAgeExclude so the floor can resolve.

Workspace-wide version pins that lived in overrides move to the pnpm catalog alongside vite: @stylexjs/stylex, @stylexjs/babel-plugin, prettier, esbuild. Peer ranges stay untouched — they are consumer contracts, not workspace pins.

pnpm audit goes from 12 findings to 10; the remaining 10 match main's baseline exactly.

� Conflicts:
�	pnpm-workspace.yaml

* chore: retrigger CI (known Markdown perf-test flake, fixed by #4099)

* chore(deps): address #4101 review, prune 6 more pnpm overrides

Per cixzhang's review: floor brace-expansion on the 5.x line (^5.0.9, inside minimatch@10's own ^5.0.5) instead of re-pinning 2.x and forcing minimatch alongside it — minimatch now resolves on its own. Also move @stylexjs/postcss-plugin into the catalog; it was left literal next to the now-catalog stylex/babel-plugin pins and would have silently drifted on the next bump.

Re-verified every remaining override against the current lockfile the same way: drop it, re-resolve, check what actually lands. hono, @changesets/parse>js-yaml, fast-uri, ip-address, and nanoid all resolve to safe versions unforced now, so they're pruned (hono also drops out of minimumReleaseAgeExclude). @hono/node-server and read-yaml-file (+ its js-yaml floor) stay — pnpm audit reports clean without them, but the actual resolved versions without the override are vulnerable (@hono/node-server 1.19.17, read-yaml-file 1.x pulling js-yaml 3.x), which audit's advisory feed doesn't catch.

pnpm install --frozen-lockfile, pnpm audit (0 findings), and eslint all pass on the result.

* chore(deps): bump docsite's MCP SDK to drop the @hono/node-server override

@modelcontextprotocol/sdk 1.30.0 widens its @hono/node-server range to '^1.19.9 || ^2.0.5', so the patched 2.x line resolves on its own now — no override needed to hold it there. Verified: @hono/node-server resolves to 2.1.0, hono to 4.13.1, pnpm audit stays clean.

pnpm install --frozen-lockfile and eslint pass on the result.

This branch was successfully deployed

1 active deployment
Preview — 085f6109 Deployed Jul 26, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant