|
| 1 | +# MCP Specification Compliance Audit |
| 2 | + |
| 3 | +**Audit Date:** 2026-04-01 |
| 4 | +**Framework Version:** mcp-framework@0.2.19 |
| 5 | +**SDK Version (installed):** @modelcontextprotocol/sdk@1.11.0 |
| 6 | +**SDK Version (latest):** @modelcontextprotocol/sdk@1.29.0 |
| 7 | +**Latest MCP Spec:** 2025-11-25 |
| 8 | +**Codebase Spec Target:** ~2025-03-26 (HTTP Stream) / 2024-11-05 (SSE) |
| 9 | + |
| 10 | +--- |
| 11 | + |
| 12 | +## Executive Summary |
| 13 | + |
| 14 | +The mcp-framework is **significantly behind** the current MCP specification. The codebase |
| 15 | +targets approximately the 2025-03-26 spec era, missing two full spec revisions |
| 16 | +(2025-06-18 and 2025-11-25). The SDK dependency is 18 minor versions behind (1.11.0 vs |
| 17 | +1.29.0). Roughly **25+ spec features** are missing or incomplete. |
| 18 | + |
| 19 | +The core primitives (tools, prompts, resources, sampling, completions, subscriptions) work |
| 20 | +well, but the framework lacks most features introduced in the June and November 2025 spec |
| 21 | +releases: tool annotations, structured content, elicitation, tasks, logging protocol, |
| 22 | +progress tracking, audio content, resource links, and several auth enhancements. |
| 23 | + |
| 24 | +--- |
| 25 | + |
| 26 | +## Feature Matrix |
| 27 | + |
| 28 | +### Legend |
| 29 | + |
| 30 | +| Symbol | Meaning | |
| 31 | +|--------|---------| |
| 32 | +| :white_check_mark: | Fully implemented | |
| 33 | +| :large_orange_diamond: | Partially implemented | |
| 34 | +| :x: | Not implemented | |
| 35 | +| N/A | Not applicable to server frameworks | |
| 36 | + |
| 37 | +--- |
| 38 | + |
| 39 | +### Core Protocol |
| 40 | + |
| 41 | +| Feature | Spec Version | Status | Notes | |
| 42 | +|---------|-------------|--------|-------| |
| 43 | +| JSON-RPC 2.0 message format | 2024-11-05 | :white_check_mark: | Via SDK | |
| 44 | +| Capability negotiation | 2024-11-05 | :white_check_mark: | Auto-detected from loaded items | |
| 45 | +| Protocol version negotiation | 2024-11-05 | :white_check_mark: | Via SDK | |
| 46 | +| `MCP-Protocol-Version` HTTP header | 2025-11-25 | :x: | New requirement for Streamable HTTP | |
| 47 | +| `Implementation.description` field | 2025-11-25 | :x: | Optional description in init | |
| 48 | +| Ping (`ping`) | 2024-11-05 | :large_orange_diamond: | SSE keep-alive only, not as protocol-level handler | |
| 49 | + |
| 50 | +--- |
| 51 | + |
| 52 | +### Server Features: Tools |
| 53 | + |
| 54 | +| Feature | Spec Version | Status | Notes | |
| 55 | +|---------|-------------|--------|-------| |
| 56 | +| `tools/list` | 2024-11-05 | :white_check_mark: | With pagination | |
| 57 | +| `tools/call` | 2024-11-05 | :white_check_mark: | With argument validation | |
| 58 | +| `notifications/tools/list_changed` | 2024-11-05 | :white_check_mark: | Capability declared | |
| 59 | +| `inputSchema` (JSON Schema) | 2024-11-05 | :white_check_mark: | Via Zod conversion | |
| 60 | +| Text content in results | 2024-11-05 | :white_check_mark: | | |
| 61 | +| Image content in results | 2024-11-05 | :white_check_mark: | Base64 encoding | |
| 62 | +| `isError` flag | 2024-11-05 | :white_check_mark: | | |
| 63 | +| **Tool `title` field** | 2025-06-18 | :x: | Human-readable display name | |
| 64 | +| **Tool `icons` array** | 2025-11-25 | :x: | Icon metadata for UI display | |
| 65 | +| **Tool Annotations** (`readOnlyHint`, `destructiveHint`, `idempotentHint`, `openWorldHint`) | 2025-06-18 | :x: | Behavior hints for clients | |
| 66 | +| **`outputSchema`** (JSON Schema for output) | 2025-06-18 | :x: | Structured output validation | |
| 67 | +| **`structuredContent`** in results | 2025-06-18 | :x: | Typed JSON output alongside unstructured | |
| 68 | +| **Audio content** in results | 2025-06-18 | :x: | `type: "audio"` with base64 data | |
| 69 | +| **Resource links** in results | 2025-06-18 | :x: | `type: "resource_link"` with URI | |
| 70 | +| **Embedded resources** in results | 2025-06-18 | :x: | `type: "resource"` with inline data | |
| 71 | +| **Content annotations** (audience, priority, lastModified) | 2025-06-18 | :x: | Metadata on content blocks | |
| 72 | +| **Tool naming guidance** (1-128 chars, allowed chars) | 2025-11-25 | :x: | Validation not enforced | |
| 73 | +| **`execution.taskSupport`** declaration | 2025-11-25 | :x: | Task-augmented execution opt-in | |
| 74 | +| Input validation errors as Tool Execution Errors (not Protocol Errors) | 2025-11-25 | :x: | For LLM self-correction | |
| 75 | + |
| 76 | +--- |
| 77 | + |
| 78 | +### Server Features: Resources |
| 79 | + |
| 80 | +| Feature | Spec Version | Status | Notes | |
| 81 | +|---------|-------------|--------|-------| |
| 82 | +| `resources/list` | 2024-11-05 | :white_check_mark: | With pagination | |
| 83 | +| `resources/read` | 2024-11-05 | :white_check_mark: | Text and blob content | |
| 84 | +| `resources/templates/list` | 2024-11-05 | :white_check_mark: | URI templates | |
| 85 | +| `resources/subscribe` / `unsubscribe` | 2024-11-05 | :white_check_mark: | | |
| 86 | +| `notifications/resources/list_changed` | 2024-11-05 | :white_check_mark: | | |
| 87 | +| `notifications/resources/updated` | 2024-11-05 | :white_check_mark: | | |
| 88 | +| **Resource `title` field** | 2025-11-25 | :x: | Human-readable display name | |
| 89 | +| **Resource `icons` array** | 2025-11-25 | :x: | Icon metadata | |
| 90 | +| **Resource `size` field** | 2025-11-25 | :x: | Size in bytes | |
| 91 | +| **Resource annotations** (audience, priority, lastModified) | 2025-06-18 | :x: | On resources and content | |
| 92 | +| **Resource template `title`** | 2025-11-25 | :x: | | |
| 93 | +| **Resource template `icons`** | 2025-11-25 | :x: | | |
| 94 | + |
| 95 | +--- |
| 96 | + |
| 97 | +### Server Features: Prompts |
| 98 | + |
| 99 | +| Feature | Spec Version | Status | Notes | |
| 100 | +|---------|-------------|--------|-------| |
| 101 | +| `prompts/list` | 2024-11-05 | :white_check_mark: | | |
| 102 | +| `prompts/get` | 2024-11-05 | :white_check_mark: | With argument support | |
| 103 | +| `notifications/prompts/list_changed` | 2024-11-05 | :white_check_mark: | | |
| 104 | +| **Prompt `title` field** | 2025-11-25 | :x: | Human-readable display name | |
| 105 | +| **Prompt `icons` array** | 2025-11-25 | :x: | Icon metadata | |
| 106 | + |
| 107 | +--- |
| 108 | + |
| 109 | +### Server Features: Completions |
| 110 | + |
| 111 | +| Feature | Spec Version | Status | Notes | |
| 112 | +|---------|-------------|--------|-------| |
| 113 | +| `completion/complete` | 2024-11-05 | :white_check_mark: | For prompt and resource args | |
| 114 | +| Paginated completion results | 2024-11-05 | :white_check_mark: | `hasMore` flag | |
| 115 | + |
| 116 | +--- |
| 117 | + |
| 118 | +### Client Features (Server -> Client requests) |
| 119 | + |
| 120 | +| Feature | Spec Version | Status | Notes | |
| 121 | +|---------|-------------|--------|-------| |
| 122 | +| **Sampling** (`sampling/createMessage`) | 2024-11-05 | :white_check_mark: | Via `MCPTool.samplingRequest()` | |
| 123 | +| **Sampling with tools** (`tools` + `toolChoice` params) | 2025-11-25 | :x: | Tool calling within sampling | |
| 124 | +| **Sampling audio content** | 2025-06-18 | :x: | Audio in sampling messages | |
| 125 | +| **Elicitation** (`elicitation/create`) - Form mode | 2025-06-18 | :x: | Server requests user input via forms | |
| 126 | +| **Elicitation** - URL mode | 2025-11-25 | :x: | Server redirects user to external URL | |
| 127 | +| **Elicitation** - `notifications/elicitation/complete` | 2025-11-25 | :x: | Completion notification for URL mode | |
| 128 | +| **Roots** (`roots/list`) | 2024-11-05 | :x: | Server queries filesystem boundaries | |
| 129 | +| **Roots** - `notifications/roots/list_changed` | 2024-11-05 | :x: | Root change notifications | |
| 130 | + |
| 131 | +--- |
| 132 | + |
| 133 | +### Utilities |
| 134 | + |
| 135 | +| Feature | Spec Version | Status | Notes | |
| 136 | +|---------|-------------|--------|-------| |
| 137 | +| **Logging** (`logging/setLevel`) | 2024-11-05 | :x: | Client sets server log level | |
| 138 | +| **Logging** (`notifications/message`) | 2024-11-05 | :x: | Server sends structured log to client | |
| 139 | +| **Progress** (`notifications/progress` via `progressToken`) | 2024-11-05 | :x: | Progress tracking for long operations | |
| 140 | +| **Cancellation** (`notifications/cancelled`) | 2024-11-05 | :x: | Cancel in-progress requests | |
| 141 | +| **Tasks** (`tasks/get`, `tasks/result`, `tasks/list`, `tasks/cancel`) | 2025-11-25 | :x: | Experimental: durable async execution | |
| 142 | +| **Tasks** - `notifications/tasks/status` | 2025-11-25 | :x: | Task status change notifications | |
| 143 | +| **Tasks** - Tool-level task negotiation (`execution.taskSupport`) | 2025-11-25 | :x: | Per-tool task support declaration | |
| 144 | +| Pagination | 2024-11-05 | :white_check_mark: | Via `nextCursor` | |
| 145 | + |
| 146 | +--- |
| 147 | + |
| 148 | +### Transports |
| 149 | + |
| 150 | +| Feature | Spec Version | Status | Notes | |
| 151 | +|---------|-------------|--------|-------| |
| 152 | +| **stdio** | 2024-11-05 | :white_check_mark: | | |
| 153 | +| **SSE** (HTTP+SSE, deprecated) | 2024-11-05 | :white_check_mark: | Maintained for backward compat | |
| 154 | +| **Streamable HTTP** (POST + optional SSE) | 2025-03-26 | :white_check_mark: | Via SDK's StreamableHTTPServerTransport | |
| 155 | +| Session management (`MCP-Session-Id`) | 2025-03-26 | :white_check_mark: | | |
| 156 | +| Stream resumability (`Last-Event-ID`) | 2025-03-26 | :large_orange_diamond: | Configurable but depends on SDK | |
| 157 | +| Batch vs stream response modes | 2025-03-26 | :white_check_mark: | | |
| 158 | +| CORS support | 2025-03-26 | :white_check_mark: | SSE + HTTP Stream | |
| 159 | +| **Origin header validation** (DNS rebinding protection) | 2025-11-25 | :x: | MUST validate, return 403 | |
| 160 | +| **`MCP-Protocol-Version` header** | 2025-11-25 | :x: | Required on all HTTP requests | |
| 161 | +| **HTTP DELETE for session termination** | 2025-11-25 | :x: | Client-initiated session cleanup | |
| 162 | +| **SSE polling** (server disconnect + client reconnect) | 2025-11-25 | :x: | Server-initiated SSE disconnect with `retry` | |
| 163 | +| **HTTP GET stream** for server-initiated messages | 2025-03-26 | :large_orange_diamond: | Depends on SDK impl | |
| 164 | +| Localhost-only binding for local servers | 2025-11-25 | :x: | Default 0.0.0.0 should be 127.0.0.1 | |
| 165 | + |
| 166 | +--- |
| 167 | + |
| 168 | +### Authentication & Authorization |
| 169 | + |
| 170 | +| Feature | Spec Version | Status | Notes | |
| 171 | +|---------|-------------|--------|-------| |
| 172 | +| API Key auth | Custom | :white_check_mark: | | |
| 173 | +| JWT auth (HS256, RS256) | Custom | :white_check_mark: | | |
| 174 | +| OAuth 2.1 (JWT validation) | 2025-06-18 | :white_check_mark: | JWKS + audience/issuer | |
| 175 | +| OAuth 2.1 (Token introspection) | 2025-06-18 | :white_check_mark: | RFC 7662 | |
| 176 | +| Protected Resource Metadata (`/.well-known/oauth-protected-resource`) | 2025-06-18 | :white_check_mark: | RFC 9728 | |
| 177 | +| Per-endpoint auth toggle | Custom | :white_check_mark: | | |
| 178 | +| `WWW-Authenticate` challenge headers | 2025-06-18 | :white_check_mark: | RFC 6750 | |
| 179 | +| **OpenID Connect Discovery 1.0** | 2025-11-25 | :x: | Auth server discovery enhancement | |
| 180 | +| **Incremental scope consent** via `WWW-Authenticate` | 2025-11-25 | :x: | Progressive scope requests | |
| 181 | +| **OAuth Client ID Metadata Documents** | 2025-11-25 | :x: | Recommended client registration | |
| 182 | + |
| 183 | +--- |
| 184 | + |
| 185 | +### SDK & Dependencies |
| 186 | + |
| 187 | +| Item | Current | Latest | Gap | |
| 188 | +|------|---------|--------|-----| |
| 189 | +| `@modelcontextprotocol/sdk` | 1.11.0 | 1.29.0 | 18 minor versions behind | |
| 190 | +| Target MCP spec version | ~2025-03-26 | 2025-11-25 | 2 spec revisions behind | |
| 191 | + |
| 192 | +--- |
| 193 | + |
| 194 | +## Priority Recommendations |
| 195 | + |
| 196 | +### P0 - Critical (Spec Compliance / Security) |
| 197 | + |
| 198 | +1. **Upgrade SDK** to `@modelcontextprotocol/sdk@^1.29.0` - Many features may come for |
| 199 | + free from the SDK upgrade, and security fixes are included. |
| 200 | +2. **Origin header validation** on Streamable HTTP transport - Security requirement to |
| 201 | + prevent DNS rebinding attacks. Return HTTP 403 for invalid origins. |
| 202 | +3. **`MCP-Protocol-Version` header** support - Required on all HTTP requests per spec. |
| 203 | +4. **Localhost binding** - Local servers should bind to `127.0.0.1` by default, not `0.0.0.0`. |
| 204 | + |
| 205 | +### P1 - High (Key June 2025 Features) |
| 206 | + |
| 207 | +5. **Tool Annotations** - Allow tools to declare `readOnlyHint`, `destructiveHint`, |
| 208 | + `idempotentHint`, `openWorldHint`. Clients rely on these for safety decisions. |
| 209 | +6. **Structured Content** - Support `outputSchema` on tools and `structuredContent` in |
| 210 | + `CallToolResult`. This is a major adoption driver. |
| 211 | +7. **Tool/Resource/Prompt `title` and `icons`** - Display metadata for client UIs. |
| 212 | +8. **Logging protocol** - Implement `logging/setLevel` handler and `notifications/message` |
| 213 | + sending. Currently only internal file logging exists. |
| 214 | +9. **Elicitation** (Form mode) - Enable servers to request user input mid-operation. Core |
| 215 | + agentic feature from June 2025 spec. |
| 216 | + |
| 217 | +### P2 - Medium (November 2025 Features + Completeness) |
| 218 | + |
| 219 | +10. **Progress tracking** - Support `progressToken` in `_meta` and send |
| 220 | + `notifications/progress` for long-running tool calls. |
| 221 | +11. **Cancellation** - Handle `notifications/cancelled` to abort in-progress requests. |
| 222 | +12. **Audio content type** - Support `type: "audio"` in tool results and sampling. |
| 223 | +13. **Resource links** (`type: "resource_link"`) and **embedded resources** (`type: "resource"`) |
| 224 | + in tool results. |
| 225 | +14. **Content annotations** (audience, priority, lastModified) on all content blocks. |
| 226 | +15. **Roots** support - Allow tools to query `roots/list` for filesystem boundaries. |
| 227 | +16. **Sampling with tools** - Add `tools` and `toolChoice` to sampling requests. |
| 228 | +17. **Resource `size` field** and **annotations**. |
| 229 | + |
| 230 | +### P3 - Low (Experimental / Advanced) |
| 231 | + |
| 232 | +18. **Tasks** (experimental) - Durable async execution with polling. Complex but enables |
| 233 | + long-running operations. |
| 234 | +19. **Elicitation URL mode** - Out-of-band user interaction via external URLs. |
| 235 | +20. **OpenID Connect Discovery** for auth server discovery. |
| 236 | +21. **OAuth Client ID Metadata Documents**. |
| 237 | +22. **Incremental scope consent**. |
| 238 | +23. **HTTP DELETE for session termination**. |
| 239 | +24. **Tool naming validation** (1-128 chars, allowed character set). |
| 240 | + |
| 241 | +--- |
| 242 | + |
| 243 | +## Feature Count Summary |
| 244 | + |
| 245 | +| Category | Implemented | Partial | Missing | Total | |
| 246 | +|----------|------------|---------|---------|-------| |
| 247 | +| Core Protocol | 3 | 1 | 2 | 6 | |
| 248 | +| Tools | 6 | 0 | 12 | 18 | |
| 249 | +| Resources | 6 | 0 | 6 | 12 | |
| 250 | +| Prompts | 3 | 0 | 2 | 5 | |
| 251 | +| Completions | 2 | 0 | 0 | 2 | |
| 252 | +| Client Features | 1 | 0 | 7 | 8 | |
| 253 | +| Utilities | 1 | 0 | 7 | 8 | |
| 254 | +| Transports | 7 | 2 | 5 | 14 | |
| 255 | +| Auth | 7 | 0 | 3 | 10 | |
| 256 | +| **Totals** | **36** | **3** | **44** | **83** | |
| 257 | + |
| 258 | +**Compliance Rate: ~47%** (39/83 features implemented or partially implemented) |
| 259 | + |
| 260 | +--- |
| 261 | + |
| 262 | +## Spec Version Changelog Reference |
| 263 | + |
| 264 | +### 2025-06-18 (Missing) |
| 265 | +- Tool annotations, structured content, output schemas |
| 266 | +- Elicitation (form mode) |
| 267 | +- Audio content type |
| 268 | +- Resource/content annotations |
| 269 | +- OAuth 2.1 auth specification (partially implemented) |
| 270 | +- Resource links and embedded resources in tool results |
| 271 | + |
| 272 | +### 2025-11-25 (Missing) |
| 273 | +- Tasks (experimental) |
| 274 | +- Icons on tools, resources, prompts, templates |
| 275 | +- Title field on tools, resources, prompts, templates |
| 276 | +- URL mode elicitation |
| 277 | +- Sampling with tools |
| 278 | +- OpenID Connect Discovery |
| 279 | +- Incremental scope consent |
| 280 | +- OAuth Client ID Metadata Documents |
| 281 | +- MCP-Protocol-Version header |
| 282 | +- Origin validation (DNS rebinding protection) |
| 283 | +- SSE polling support |
| 284 | +- Tool naming guidance |
| 285 | +- Enhanced ElicitResult and EnumSchema |
| 286 | + |
| 287 | +--- |
| 288 | + |
| 289 | +## Sources |
| 290 | + |
| 291 | +- [MCP Specification 2025-11-25](https://modelcontextprotocol.io/specification/2025-11-25) |
| 292 | +- [MCP Changelog 2025-11-25](https://modelcontextprotocol.io/specification/2025-11-25/changelog) |
| 293 | +- [MCP Anniversary Blog Post](https://blog.modelcontextprotocol.io/posts/2025-11-25-first-mcp-anniversary/) |
| 294 | +- [MCP GitHub Releases](https://github.com/modelcontextprotocol/modelcontextprotocol/releases) |
| 295 | +- [Auth0 MCP Spec Updates](https://auth0.com/blog/mcp-specs-update-all-about-auth/) |
0 commit comments