Skip to content

fix(deps): clear js-yaml and postcss dev-scope advisories - #22

Merged
stevan-borus merged 1 commit into
mainfrom
fix/dev-dep-vulns
Aug 10, 2026
Merged

fix(deps): clear js-yaml and postcss dev-scope advisories#22
stevan-borus merged 1 commit into
mainfrom
fix/dev-dep-vulns

Conversation

@stevan-borus

Copy link
Copy Markdown
Owner

Clears both open Dependabot alerts on main. Neither had a PR open.

Severity Package Advisory Was Now
High js-yaml Quadratic CPU consumption in !!omap resolution (CVE-2026-59870 not backported) 4.3.0 4.3.1
Moderate postcss Attacker-controlled sourceMappingURL reads arbitrary .map files when from is unset 8.5.22 8.5.26

Both are development-scope only — neither reaches published dist/, so no consumer of the package was ever affected. The practical exposure was CI and local builds.

The js-yaml override had gone stale

Worth flagging, since it is the actual reason this alert was open rather than covered.

97e0821 added "js-yaml@<4.2.0": "^4.2.0" for an earlier advisory. That selector only rewrites versions matching <4.2.0 — but the new advisory covers >=4.0.0 <4.3.1. We were resolving 4.3.0, which no longer matched the selector, so the override quietly applied to nothing while still looking active in package.json.

Widened to <4.3.1, and added the same style of guard for postcss.

Pinned js-yaml to ^4.3.1 rather than latest (5.2.3) deliberately — 5.x is a major and @changesets/cli is what pulls this in, so staying on the 4.x line avoids risking the release path for a dev-only fix.

Verification

  • pnpm audit --audit-level=lowNo known vulnerabilities found
  • Lockfile confirmed: no vulnerable versions remain
  • pnpm test -- --run — 35/35 passing
  • pnpm build — OK (CJS + ESM + declarations)
  • pnpm changeset status — CLI runs correctly on js-yaml 4.3.1, confirming the release tooling still works

No changeset: dev dependencies only, nothing reaches published dist/.

Note: biome:check still prints the $schema version notice on this branch — that is fixed separately in #21 and is info-level, so CI stays green.

The existing `js-yaml@<4.2.0` override was pinned to the range of an older
advisory, so it silently stopped protecting anything once CVE-2026-59870
landed covering `>=4.0.0 <4.3.1` — we were resolving 4.3.0 and still exposed.
Version-range override selectors are a trap that way: they look active in
package.json long after the advisory has moved past them. Widened to
`<4.3.1` and added the same guard for postcss's arbitrary .map file read.

Both are dev-scope only, so no published artifact was ever affected.
@stevan-borus

Copy link
Copy Markdown
Owner Author

Update: #21 has since merged, so the $schema caveat at the bottom of the description no longer applies — once this branch picks up main, biome:check is fully clean with no info notice.

@stevan-borus
stevan-borus merged commit 9235efb into main Aug 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant