Skip to content

fix(deps): clear Dependabot dev-dep advisories (vite, js-yaml, esbuild) - #125

Merged
dean0x merged 1 commit into
mainfrom
fix/dependabot-dev-deps
Jun 27, 2026
Merged

fix(deps): clear Dependabot dev-dep advisories (vite, js-yaml, esbuild)#125
dean0x merged 1 commit into
mainfrom
fix/dependabot-dev-deps

Conversation

@dean0x

@dean0x dean0x commented Jun 27, 2026

Copy link
Copy Markdown
Owner

What

Clears all 4 open Dependabot alerts (all dev-scope). npm audit0 vulnerabilities.

Alert Package Sev Fix
#6 vite high 8.0.14 → 8.0.16server.fs.deny bypass (GHSA-fx2h-pf6j-xcff)
#7 vite med same bump — launch-editor NTLMv2 disclosure (GHSA-v6wh-96g9-6wx3)
#5 js-yaml med 4.1.1 → 4.2.0 — quadratic DoS in merge keys (GHSA-h67p-54hq-rp68)
#3 esbuild low dropped — dev-server file read (GHSA-g7r4-m6w7-qqqr)

Version choices: 30-day supply-chain soak

Pinned to the oldest patched releases that satisfy a ~30-day soak window, not npm's freshest:

Picked Age Rejected (too fresh) Age
vite 8.0.16 26d vite 8.1.0 4d
js-yaml 4.2.0 27d js-yaml 4.3.0 1d

Incidental sub-deps that rode in with vite/rolldown are also soaked: rolldown 1.0.3 (31d), @oxc-project/types 0.133.0 (32d), tinyglobby 0.2.17 (28d). No unsoaked package was introduced.

Why exact pins, not overrides

overrides are broken in this repo's npm 10 setup: they never reify (npm reads them from the empty lockfile, not package.json) and they poison sibling resolution (with an esbuild override present, npm silently pinned vite to 8.0.14 instead of 8.0.16). So each version is pinned via an exact devDependency in the workspace that owns it:

  • packages/vite-plugin: vite ^8.0.08.0.16
  • crates/mds-napi: add js-yaml 4.2.0 (transitive via @napi-rs/cli)

These are temporary soak-pins — relax to caret ranges once 8.1.0 / 4.3.0 cross 30 days.

On esbuild removal

esbuild was only ever an unused optional peer of vite (the plugin builds with tsc; vite bundles via rolldown — nothing in the repo imports esbuild). When vite hoists to a single root copy, the unused peer isn't reinstalled and drops out, clearing #3 with zero functional change. (The bundler was already rolldown-based at 8.0.14 — this is not a bundler swap.)

Verification

  • npm audit0 vulnerabilities
  • @mdscript/vite-plugin build (tsc) ✅ + tests 24/24 pass
  • Lockfile: only esbuild's 27 entries removed; all other cross-platform binaries intact (@rolldown/binding-*, @rollup/rollup-*, lightningcss-*, @napi-rs/*, @rspack/binding-* unchanged); npm ci validates
  • No root overrides; no mass dependency drift

Resolve all 4 open Dependabot alerts (all dev-scope; npm audit now clean):
- vite 8.0.14 -> 8.0.16   GHSA-fx2h-pf6j-xcff (high), GHSA-v6wh-96g9-6wx3 (med)
- js-yaml 4.1.1 -> 4.2.0  GHSA-h67p-54hq-rp68 (med)
- esbuild dropped         GHSA-g7r4-m6w7-qqqr (low)

Versions are pinned to the OLDEST patched releases that satisfy a ~30-day
supply-chain soak window. npm's defaults (vite 8.1.0, js-yaml 4.3.0) were too
fresh at 4d / 1d; the chosen 8.0.16 (26d) and 4.2.0 (27d) are battle-tested.

Pinned via exact devDependency declarations in the owning workspaces, NOT root
`overrides`: overrides do not reify in this repo's npm 10 setup (read from the
empty lockfile, never written) and silently mis-resolve siblings (an esbuild
override pinned vite to 8.0.14 instead of 8.0.16).

esbuild was only ever an unused optional peer of vite (the plugin builds with
tsc; vite bundles via rolldown -- nothing imports esbuild). It drops out cleanly
when vite hoists to a single root copy, clearing the advisory with no functional
change. Confirmed by leaving it out: build + tests still pass.

Verified: npm audit = 0; vite-plugin tsc build + 24/24 tests pass; every
introduced version 26-32 days old; cross-platform lockfile entries intact
(only esbuild's 27 entries removed); npm ci validates.
@dean0x
dean0x merged commit c3b39ab into main Jun 27, 2026
15 of 16 checks passed
@dean0x
dean0x deleted the fix/dependabot-dev-deps branch June 27, 2026 20:53
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