fix: maintenance pass pt2 — 0 audit CVEs, a11y fixes, rate-limiter regression, markdown defense-in-depth#65
Merged
Merged
Conversation
### Fixes - Bump astro 6.1.9 → 6.4.4 (fixes server-island replay low CVE) - Add smol-toml ^1.6.1 override in pnpm-workspace.yaml (fixes moderate DoS CVE; astro still pins 1.6.0 internally) - Patch/minor bumps: react 19.2.7, react-dom, marked, @biomejs/biome 2.4.16, @types/react, @types/node, tsx, @astrojs/node 10.1.3, tailwindcss/@tailwindcss/vite 4.3.0, lucide-react 1.17.0, tailwind-merge 3.6.0 — audit now reports 0 vulnerabilities - rateLimit.ts: fixed unique-per-request fallback that silently disabled the limiter when X-Forwarded-For was missing/invalid; unattributed requests now share a single fallback bucket - rateLimit.test.ts: added regression test for the fallback bucket fix - markdown.ts: added explicit scheme allowlist in link/image renderers before sanitize-html; trims input to block whitespace bypass attacks (e.g. " javascript:...")
### Fixes - DocsToc.tsx: sort IntersectionObserver entries by DOM position so the active heading reflects what is actually on screen; read heading.id directly instead of recomputing a slug that diverged on duplicate-heading collisions - DocsHeader.astro: add aria-expanded + aria-controls to mobile menu button; sync sidebar inert/aria-hidden with menu state via resize listener; auto-close menu when crossing into desktop viewport - ThemeSwitcher.tsx: replace focusable backdrop button (announced as a full-viewport "Close theme menu" control) with non-focusable div + aria-hidden; move focus to current theme button on open - Search.tsx: wrap result content in <a href> with tabIndex=-1 and stopPropagation so middle/Cmd-click open in a new tab natively; drop unconditional window.location.href to prevent double-navigation - [...slug].astro: replace Astro.redirect branches with throw — route is prerendered and getStaticPaths enumerates all valid slugs so a missing slug or article is a build-time invariant violation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #65 +/- ##
==========================================
- Coverage 83.33% 82.90% -0.43%
==========================================
Files 11 11
Lines 264 275 +11
Branches 68 70 +2
==========================================
+ Hits 220 228 +8
- Misses 26 28 +2
- Partials 18 19 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This was referenced Jun 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
pnpm auditnow reports 0 vulnerabilitiesX-Forwarded-Forpreviously generated a unique key per request, silently disabling the limiter; unattributed requests now share a fallback bucket" javascript:...")Changes
Security / Dependencies
smol-toml ^1.6.1override (astro still pins 1.6.0 which has a moderate DoS CVE)Rate Limiter
"unknown"bucket so the limiter is never bypassed whenX-Forwarded-Foris absent or invalidMarkdown Defense-in-Depth
http:,https:,mailto:,#) in link and image renderers; input trimmed before scheme check to close whitespace bypassAccessibility & Navigation
aria-expanded/aria-controlson mobile menu button; sidebarinert/aria-hiddensynced to menu state; menu auto-closes on resize into desktop viewportheading.iddirectly (fixes duplicate-slug collision)div+aria-hidden; focus moves to current theme on open<a href>(tabIndex=-1, stopPropagation) for native middle/Cmd-click; removed unconditionalwindow.location.hrefthat caused double-navigationAstro.redirectbranches replaced withthrow— missing slug/article is a build-time invariant violation on a prerendered routeTest plan
pnpm test— all 153 tests passpnpm exec tsc --noEmit— no type errorspnpm build— clean production buildpnpm audit— 0 vulnerabilitiesaria-expandedstate correctly in a screen reader