Skip to content

[PR] fix: refresh upstream CA cache on configured path changes - #6096

Closed
Afloat16 wants to merge 1 commit into
ranxianglei:masterfrom
Afloat16:2026-11-10_ca-path-cache-refresh
Closed

Afloat16 wants to merge 1 commit into
ranxianglei:masterfrom
Afloat16:2026-11-10_ca-path-cache-refresh

Conversation

@Afloat16

Copy link
Copy Markdown
Contributor

Problem

upstreamCaIdentity throttles all configured-file lookups for 30 seconds even after the selected path changes. The new path reuses the old dispatcher identity and merged roots, including a prior missing-file result.

Changes

Throttle mtime probes only when the configured path matches the cached identity. Path changes refresh immediately. Same-path edits retain the existing 30-second rotation behavior and built-in roots are still merged.

Validation

  • Before: tests/issue3776-tls-mitm-diagnostics.test.ts — 11 passed, 2 failed.
  • After: 13 passed, 0 failed, including same-path TTL and existing real HTTPS proxy controls.
  • npm run typecheck — passed.
  • npm run build — passed.
  • Published fork tree 22c1d711ba79efb3d687a9023248794509c2a5ad exactly matches tested local commit 275ce03b447813f9f86d5b486f4bd560add561a7.

The full remote-suite verdict belongs to CI. #3786 introduced the trust-file cache; open #4417 adds TLS forensics and certificate logging. Neither invalidates the identity when the configured path changes. All 3,221 historical PRs were screened; independent of #6046–#6055.

Closes #6095

@ranxianglei ranxianglei changed the title fix: refresh upstream CA cache on configured path changes [PR] fix: refresh upstream CA cache on configured path changes Nov 10, 2026
@ranxianglei

Copy link
Copy Markdown
Owner

Landed via batch PR #6439 (merged) — closing as superseded.

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

(ai: vllm-qwen/qwen3.8-27b)

Verified the supersession before endorsing it:

  • Batch PR [PR] chore(batch): land 50 open Afloat16 fixes in one history-preserving batch #6439 ("chore(batch): land 50 open Afloat16 fixes in one history-preserving batch") is merged into master — merge commit 873715d40a.
  • This PR's fix, fix: refresh upstream CA cache on configured path changes (commit 6ce4cdba90), is an ancestor of that merge → it landed via [PR] chore(batch): land 50 open Afloat16 fixes in one history-preserving batch #6439.
  • The fix is live in origin/master:src/upstream-ca.ts: the 30s probe throttle now reads if (now - lastStatAt < IDENTITY_TTL_MS && lastIdentity.startsWith(${caFile}\u0000)) return lastIdentity; — the throttle applies only when the configured path matches the cached identity, so a live path switch refreshes immediately while same-path edits keep the 30s rotation. This is exactly the change this PR described.

Confirmed: this PR is superseded by #6439. Closing is yours to do.

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

(ai: vllm-qwen/qwen3.8-27b)

Re-checked live — state is unchanged since the last pass: the owner's floor-1 decision stands (superseded by batch PR #6439) and the verification is already on record (floor 3 — #6439 merged at 873715d40a, fix commit 6ce4cdba90 is an ancestor of that merge, fix live in origin/master:src/upstream-ca.ts). Nothing new to do here; the thread awaits the owner's close.

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.

Changing the configured CA file temporarily reuses the previous trust material

2 participants