Skip to content

fix(security): isolate unused deps, patch runtime CVEs, drop Slither - #267

Merged
ThatAlexPalmer merged 1 commit into
mainfrom
fix/security-dependabot-alerts
Aug 21, 2026
Merged

fix(security): isolate unused deps, patch runtime CVEs, drop Slither#267
ThatAlexPalmer merged 1 commit into
mainfrom
fix/security-dependabot-alerts

Conversation

@ThatAlexPalmer

Copy link
Copy Markdown
Member

What?

Clear the GitHub security tab so we can deploy the API + Mongo stack. This PR does the approved work in one change so Dependabot sees a single cleaned lockfile.

  • Remove unused alert sources: ocf/ is no longer a pnpm workspace (submodule stays for JSON schemas). Drop unused solc and date-fns. Delete Slither (config, CI SARIF job, make slither, docs).
  • Patch used runtime deps: mongoose 9.9.3 (Mongo 8 compatible), uuid 14.0.2 (moved to production deps), next 16.3.2 on both app and docs. Docs migrate Nextra 3 Pages Router → Nextra 4 App Router. Express stays on 4.x.
  • Transitive pins via pnpm.overrides (ws, nanoid, fast-uri, brace-expansion, ajv, qs, etc.). Previous overrides that pinned known-bad @xmldom/xmldom@0.9.9 and socket.io-parser@4.2.6 are gone.
  • CI / Dependabot: one weekly npm scan at / (the /app extra scan was a no-op). Ignore Express majors. Parallel Foundry job in CI. GitHub Actions were already on latest (checkout/setup-node v6, cache v5, pnpm/action-setup v6).
  • Nested .github/ folders are not added — GitHub only reads the root. Package-specific notes live in SECURITY.md / WARP.md.

Why?

Security tab had ~147 Dependabot alerts (3 critical / 56 high) plus 3 low Slither SARIF findings. Most criticals (parse-url, handlebars, websocket-driver) came from OCF's unused docs/jest tree. Remaining highs were real: mongoose 7, uuid 9, Next 15/16.2.10, plus transitives on the server/app path.

Local pnpm audit after this lockfile: 0 critical, 0 high. Leftover: moderate uuid@8/uuid@9 pulled by ethers/wagmi (forcing 11+ would break CJS require), plus low @babel/core.

Testing

  • pnpm install — workspace is 4 packages (root, app, docs, @tap/units); ocf is not installed.
  • Mongoose 9.9.3 connected to local Mongo on 27027 (mongo:latest / 8.2.x): 8 issuers, 1 factory; Issuer.findOne() returned TAP issuer e151551c-….
  • uuid v4 ESM import works on Node 24.
  • pnpm test:units — 10/10.
  • pnpm --filter tap-app test:nav — 33/33.
  • pnpm --filter tap-app build — Next 16.3.2, all /app/* routes.
  • pnpm --filter tap-docs build — 37 static pages + Pagefind index.
  • Served docs on :3001: /, /development, /security, /protocol, /api-reference, /features, /tests, /development/setup, /protocol/tap-ocf all 200; unknown path 404. Security page no longer mentions Slither.
  • pnpm --filter tap-app lint and pnpm --filter tap-docs lint clean.

After merge (manual):

  1. Enable secret scanning + push protection (Settings → Code security). It is off today (API 404).
  2. Dismiss the 3 leftover Slither code-scanning alerts as used-in-tests / won't fix — GitHub will not auto-close them when the tool is removed.
  3. Rebuild the server Docker image so production runs mongoose 9 against cluster Mongo 8.
  4. Wait for Dependabot to rescan main; remaining uuid 8/9 moderates can be ignored as transitive wallet-stack CJS.

Remove ocf from the pnpm workspace (keep the submodule for JSON schemas),
drop unused solc/date-fns, and upgrade mongoose 9.9.3, uuid 14, and Next
16.3.2 for both app and docs (Nextra 4 App Router). Pin patched transitives
via pnpm.overrides. Replace Slither with Aderyn plus Foundry invariants,
scan npm once weekly from the root lockfile, and run Foundry tests in CI.
@vercel

vercel Bot commented Aug 21, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
tap-cap-table-app Ready Ready Preview Aug 21, 2026 12:49pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
docs Ignored Ignored Aug 21, 2026 12:49pm

Request Review

@ThatAlexPalmer
ThatAlexPalmer merged commit 80e3d01 into main Aug 21, 2026
5 checks passed
@ThatAlexPalmer
ThatAlexPalmer deleted the fix/security-dependabot-alerts branch August 21, 2026 12: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