Skip to content

Expose the upstream refresh guard opt-out in RunConfig and CRDs #6931

Open

Description

@tgrunnagle

Problem

#6930 adds a built-in upstream refresh guard to the embedded auth server (pkg/authserver). It refuses a refresh_token grant with invalid_grant when the token session's upstream credential is definitively dead. The guard is on by default. The only opt-out, authserver.Config.DisableUpstreamRefreshGuard, is a Go field. runner/embeddedauthserver.go never sets it, so thv, vMCP and the operator always run the guard.

With the guard on, a refresh token stays useful only while the upstream credential does. That holds even in deployments whose resource server never reads upstream tokens. An operator who wants the old behaviour has no switch.

Proposal

Expose the opt-out through the RunConfig embedded auth server config and the operator CRDs (MCPExternalAuthConfig / VirtualMCPServer embedded auth server settings), and wire it to Config.DisableUpstreamRefreshGuard.

Acceptance criteria

  • A RunConfig field disables the guard for thv and the proxy runner.
  • The operator CRDs expose the same field, with generated CRD docs.
  • docs/arch/11-auth-server-storage.md ("Upstream refresh guard", Opt-out) no longer says the switch is Go-only.

Context

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs-triageIssue needs initial triage by a maintainer

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions