Skip to content

Activate Node auth middleware and CA startup under src - #34

Merged
ThatXliner merged 1 commit into
mainfrom
security/scouting-node-auth-middleware
Oct 21, 2026
Merged

ThatXliner merged 1 commit into
mainfrom
security/scouting-node-auth-middleware

Conversation

@ThatXliner

@ThatXliner ThatXliner commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Put the existing auth middleware and CA startup hook beside src/app, where Next.js 15 actually discovers them. The project-root files were ignored by the compiler. Run auth middleware on the supported Node runtime and install the existing eMudhra default-CA filter before Supabase client creation/session HTTPS. Cookie handling, matcher, and application UI source are unchanged.

Verification: focused strict TypeScript check passes. The production build emits both Node middleware and instrumentation bundles, compiles successfully, and then stops at the same existing invalid matches/page.tsx export. No new type/build error was introduced.

Both compiled hooks were executed independently on unpatched Node 24.22.0. Each removes the affected default root without a test-side filter call, rejects both incident chains through real fetch, and accepts example.com HTTPS. The compiled middleware returns its expected passthrough response, includes Node TLS and runtime: nodejs, and is absent from the Edge middleware manifest.

Live deployment remains blocked by unavailable access to the established Team3256 Vercel scope. This PR does not claim deployed TLS verification.

The emitted middleware also executes its actual Supabase getUser HTTPS path using a synthetic local session cookie. A test-only native-fetch wrapper verifies the CA is already removed and that both outgoing credentials are dummy, then forwards only that fixed auth GET to the fixed incident hosts or example.com. Both bad chains reject and good HTTPS is accepted. No real Supabase account or project credentials are used.

@ThatXliner
ThatXliner merged commit 64b5044 into main Oct 21, 2026
0 of 3 checks passed
ThatXliner added a commit that referenced this pull request Nov 8, 2026
PRs #33 and #34 added a server-side filter that removes the four compromised eMudhra roots from Node's default CA store. They also added a CI step and a script that probe the incident hosts. Node 22.23.4, 24.22.1 and 26.12.1, and Vercel's managed Node (22.x is now v22.23.4, 24.x is v24.22.2, 26.x is v26.13.0), no longer ship those roots, so the filter has nothing left to remove. The probe script tests the incident hosts, not this app, and it will break when those hosts go away.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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