Title: Document and lock the tools/list pre-auth posture; consider DISCOVERY_METHODS for JSON-RPC method gating · Issue #222 · adcontextprotocol/adcp-client-python · GitHub
Open Graph Title: Document and lock the tools/list pre-auth posture; consider DISCOVERY_METHODS for JSON-RPC method gating · Issue #222 · adcontextprotocol/adcp-client-python
X Title: Document and lock the tools/list pre-auth posture; consider DISCOVERY_METHODS for JSON-RPC method gating · Issue #222 · adcontextprotocol/adcp-client-python
Description: Summary MCP's streamable-HTTP transport accepts tools/list JSON-RPC calls without authentication — the gate only applies to tools/call. This is consistent with the MCP spec (tool discovery is a handshake concern) and with the AdCP spec (...
Open Graph Description: Summary MCP's streamable-HTTP transport accepts tools/list JSON-RPC calls without authentication — the gate only applies to tools/call. This is consistent with the MCP spec (tool discovery is a han...
X Description: Summary MCP's streamable-HTTP transport accepts tools/list JSON-RPC calls without authentication — the gate only applies to tools/call. This is consistent with the MCP spec (tool discovery is a...
Opengraph URL: https://github.com/adcontextprotocol/adcp-client-python/issues/222
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Document and lock the tools/list pre-auth posture; consider DISCOVERY_METHODS for JSON-RPC method gating","articleBody":"## Summary\n\nMCP's streamable-HTTP transport accepts `tools/list` JSON-RPC calls without authentication — the gate only applies to `tools/call`. This is consistent with the MCP spec (tool discovery is a handshake concern) and with the AdCP spec (`get_adcp_capabilities` is pre-auth). But the posture isn't documented; the example and integration test both focus on `tools/call` gating and leave `tools/list` implicit.\n\nSecurity reviewer on PR #219 flagged this:\n> The example middleware only peeks at `method == \"tools/call\"` — `tools/list` skips the auth gate entirely. An unauthenticated attacker hits `POST /mcp/` with `{\\\"method\\\": \\\"tools/list\\\"}` and gets the full inventory: tool names, input schemas, descriptions, annotations.\n\nSeverity: medium. Information disclosure (capability surface, parameter shapes) — not direct compromise, but reconnaissance.\n\n## Proposed fix\n\nTwo-part, minimum:\n\n1. **Document the posture.** Add a section to `docs/handler-authoring.md` and `examples/mcp_with_auth_middleware.py` docstring stating explicitly:\n - `tools/list` is unauthenticated per MCP+AdCP spec (handshake concern).\n - Operators who need tool-list auth should gate `method in {\\\"tools/list\\\", \\\"tools/call\\\"}` and only skip when `name in DISCOVERY_TOOLS`.\n - Tool names, schemas, and descriptions are considered non-sensitive by default; operators who embed deployment hints in descriptions should review.\n\n2. **Ship `DISCOVERY_METHODS` companion frozenset.** Parallel to `DISCOVERY_TOOLS`, expose the JSON-RPC method names that are pre-auth by spec. Initial set: `{\\\"initialize\\\", \\\"tools/list\\\"}`. Downstream middleware then composes `method in DISCOVERY_METHODS or (method == \\\"tools/call\\\" and tool_name in DISCOVERY_TOOLS)` for their auth gate.\n\n3. **Update the example** to use the composed gate, so copy-paste adopters get the stricter posture by default.\n\n## After (dependent on #220)\n\nOnce the advertised-tools gate (#220) ships, `tools/list` only returns the tools the handler overrode, which shrinks the reconnaissance surface significantly. Revisit the default posture then.\n\n## Context\n\nTracked from PR #219 expert security review.","author":{"url":"https://github.com/bokelley","@type":"Person","name":"bokelley"},"datePublished":"2026-04-20T06:04:18Z","url":"https://github.com/adcontextprotocol/adcp-client-python/issues/222"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:0b86aa58-8284-d14c-1a15-a87ee81b8ed0 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C3E4:6DC60:D15A0:10684D:6B00F6DD |
| html-safe-nonce | 7766bd34193fa5b2d34abde6f72299422865bac84a6a4b7aad7539d232576c04 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDM0U0OjZEQzYwOkQxNUEwOjEwNjg0RDo2QjAwRjZERCIsInZpc2l0b3JfaWQiOiIxOTE1OTg0MTYwOTIxNTQ4NTA5IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | e0db4a3a55b7c75067e34b25f25390c48a53390e719d3443eac6da37460cc564 |
| hovercard-subject-tag | issue:4293462473 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/adcontextprotocol/adcp-client-python/222/issue_layout |
| twitter:image | https://opengraph.githubassets.com/f55115a6841196f4f98bd81557e24edb707e865254c6111b95aea02d13fcc2e7/adcontextprotocol/adcp-client-python/issues/222 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/f55115a6841196f4f98bd81557e24edb707e865254c6111b95aea02d13fcc2e7/adcontextprotocol/adcp-client-python/issues/222 |
| og:image:alt | Summary MCP's streamable-HTTP transport accepts tools/list JSON-RPC calls without authentication — the gate only applies to tools/call. This is consistent with the MCP spec (tool discovery is a han... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | bokelley |
| hostname | github.com |
| expected-hostname | github.com |
| None | 4ef498cbabcbe3c50befc7a5b743e7072ee770b4daf0e15e54801180d1fa91fc |
| turbo-cache-control | no-preview |
| go-import | github.com/adcontextprotocol/adcp-client-python git https://github.com/adcontextprotocol/adcp-client-python.git |
| octolytics-dimension-user_id | 221690821 |
| octolytics-dimension-user_login | adcontextprotocol |
| octolytics-dimension-repository_id | 1090305973 |
| octolytics-dimension-repository_nwo | adcontextprotocol/adcp-client-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1090305973 |
| octolytics-dimension-repository_network_root_nwo | adcontextprotocol/adcp-client-python |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 9983dd5da06943f833c971dd5b6bc988e2858be5 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width