inspector/test-servers/configs
Repository files (latest commit first)
Filename Latest commit message Latest commit date
cliffhall 65fd2b9e35 feat(auth): revoke OAuth tokens at the authorization server on clear (#2144)
Clearing the Inspector's OAuth state deleted the local copy of the tokens
and stopped there. The access token — and the refresh token, which is
long-lived by design — stayed valid at the authorization server until they
expired on their own, so a day of connect/disconnect iteration left it
holding grants for sessions that ended hours ago. RFC 7009 §1 describes
exactly that case, and nothing in the repo constructed a revocation
request, so a server author implementing `revocation_endpoint` had no way
to exercise it with the tool that exists to exercise this.

core/auth/revocation.ts builds and sends the request; the three clear paths
call it, so the behavior is written once — web's "Clear OAuth state and
disconnect" (both the active and stored-only paths), the TUI's Auth tab,
and the CLI's --relogin. It runs BEFORE the local clear, because the token,
the client credentials and the discovered `revocation_endpoint` all live in
the store the clear is about to empty. The request names the refresh token
when there is one: §2.1 asks the AS to also invalidate the access tokens
issued under the same grant, so one request covers both halves.

Best-effort by construction. Every path returns a TokenRevocationOutcome
rather than throwing: no advertised endpoint means nothing is sent and that
authorization server behaves exactly as before, and a network error, a
non-2xx, a 5s timeout or an unreadable store is reported and nothing more.
Forgetting the tokens is what the user asked for. `lost_authorization_state`
recovery deliberately skips it — it clears a half-finished flow to retry it,
and an authorization that never completed has no grant to revoke.

Client authentication resolves the preregistered slot first, mirroring
BaseOAuthClientProvider.clientInformation; reading only the dynamic slot
would send no authentication for a server configured with `oauth.clientId`.
The Basic credential is byte-identical to the SDK's applyBasicAuth so this
request and the token request cannot present the same secret differently.

Opt out per server with `oauth.revokeOnClear` (default on, only `false`
written to disk) or per CLI run with --no-revoke. Read at clear time rather
than connect time, so toggling needs no reconnect. Turning it off is a
testing affordance: a client that walks away still holding live tokens is a
case a server author may want to reproduce.

test-servers now advertises `revocation_endpoint` and serves POST
/oauth/revoke, faithful on §2.2 (an unknown token is a success) and §2.1
(revoking a refresh token invalidates the access tokens under the same
grant), with oauth-revocation-http.json / oauth-no-revocation-http.json as
showcase configs.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0177mPHAdECD18nLLCTwR5rh
Signed-off-by: cliffhall <cliff@futurescale.com>
2026-08-28 00:48:57 -04:00
..
advertised-extensions-http.json Extensions: advertised-extensions toggle in Server Settings (Phase 2 of #1633) (#1743) 2026-07-22 16:23:43 -04:00
app-elicitation-http.json feat(apps): negotiated app-rendered form elicitations 2026-08-22 19:05:33 -04:00
app-elicitation-native-http.json feat(apps): negotiated app-rendered form elicitations 2026-08-22 19:05:33 -04:00
demo.json feat(core): port v1.5 InspectorClient + transports + auth subsystem (#1302) (#1306) 2026-05-15 15:36:17 -04:00
duplicate-tool-names-http.json test: add a duplicate-tool-names test server for the #1957 repro 2026-08-10 20:22:47 -04:00
logging-legacy-http.json Logging: per-request log level on modern servers (era fork) (#1629) (#1724) 2026-07-19 17:08:22 -04:00
logging-modern-http.json Logging: per-request log level on modern servers (era fork) (#1629) (#1724) 2026-07-19 17:08:22 -04:00
mcp-app-domain-http.json test(web): prove the dedicated app origin end to end 2026-08-24 08:45:40 -04:00
mcp-app-http.json test: add an MCP App showcase config to reproduce and verify #1859 2026-08-05 17:59:09 -04:00
modern-http.json Add modern-era (2026-07-28) test-server preset (#1700) (#1703) 2026-07-17 11:12:40 -04:00
modern-mrtr-http.json History: MRTR conversation grouping + modern message vocabulary (#1705) 2026-07-17 20:02:11 -04:00
modern-network-http.json Network: modern Mcp-* headers, new error codes, cancellation-as-abort (#1628) (#1722) 2026-07-18 17:32:05 -04:00
mrtr-showcase-http.json fix(web): name an empty tool result instead of "No results yet" (#1860) 2026-08-16 18:31:01 -04:00
nullable-fields-http.json fix: render nullable enum fields as a Select instead of a raw JSON textarea 2026-08-15 16:10:17 -04:00
oauth-custom-resource-metadata-http.json fix(auth): pass the challenge's resource_metadata URL to SDK auth() 2026-08-24 19:48:40 -04:00
oauth-no-revocation-http.json feat(auth): revoke OAuth tokens at the authorization server on clear (#2144) 2026-08-28 00:48:57 -04:00
oauth-revocation-http.json feat(auth): revoke OAuth tokens at the authorization server on clear (#2144) 2026-08-28 00:48:57 -04:00
oauth-step-up-demo.json All of the mid-session and step-up auth work 2026-07-02 16:35:31 -07:00
pagination-http.json Thread cacheMode through managed list refresh via SDK cache-aware verbs (#1721) (#1723) 2026-07-19 01:06:31 -04:00
rfc6570-templates-http.json fix(core): share URI-template expansion and correct the SDK's multi-name branch 2026-08-16 18:51:12 -04:00
root-union-schemas-http.json fix: render tool schemas with root-level anyOf/oneOf composition 2026-08-26 00:37:43 -04:00
structured-output-http.json fix: render a tool result's structuredContent in the Tools screen (#1908) 2026-08-11 09:23:43 -04:00
subscriptions-legacy-http.json Resources: subscriptions/listen model on modern servers (era fork) (#1630) (#1730) 2026-07-20 19:33:40 -04:00
subscriptions-modern-http.json Resources: subscriptions/listen model on modern servers (era fork) (#1630) (#1730) 2026-07-20 19:33:40 -04:00
subscriptions-never-acknowledged-http.json fix(core): say why a never-acknowledged subscriptions/listen ended 2026-08-27 20:49:55 -04:00
tasks-legacy-http.json Tasks: io.modelcontextprotocol/tasks extension on modern servers (era fork) (#1731) 2026-07-21 19:17:04 -04:00
tasks-modern-http.json Tasks: io.modelcontextprotocol/tasks extension on modern servers (era fork) (#1731) 2026-07-21 19:17:04 -04:00
unportable-schemas-http.json fix: map the new exit code, keep add runnable, distinguish severity by shape 2026-08-25 02:37:10 -04:00
url-elicitation-form.json feat(core): port v1.5 InspectorClient + transports + auth subsystem (#1302) (#1306) 2026-05-15 15:36:17 -04:00
web-tabs-http.json chore(web): connected-flow smoke for the Tools, Resources and Prompts tabs 2026-08-26 23:09:44 -04:00
xaa-ema-http.json Auth hardening CI gaps + SDK consolidation: EMA leg 2 / scopes (#1527) (#1725) 2026-07-19 22:36:21 -04:00
xmcpheader-modern-http.json Tools: x-mcp-header annotation tooling + -32602 unknown-tool rendering (#1632) (#1735) 2026-07-22 11:42:54 -04:00