v2.0.2
A security release from a release-time review of the 2.0.x HTTP transport and the auth providers. No public API changes.
Security
- Authentication is enforced on every Streamable HTTP verb. GET (open SSE) and DELETE (terminate session) previously ran no auth provider; the
Mcp-Session-Idalone gated them, so a leaked session id let a caller read a session's server-to-client SSE traffic or terminate sessions without a credential. Both verbs now run the same auth gate as POST, before any session lookup. No-op underbarrel_mcp_auth_none. - Resource, prompt and completion handler crashes no longer leak exception terms to the client.
resources/read,prompts/getandcompletion/completeserialised the caughtClass:Reasoninto the JSON-RPC error (onlytools/callwas fixed in 2.0.1). They now log server-side and return a generic message. - The built-in listener caps concurrent connections. With
idle_timeoutatinfinity(so long-lived SSE GETs are never reaped) a connection lived until the peer closed it, so a connection flood or slow/idle clients could exhaust file descriptors and memory. Each listener now bounds established connections (default 16384,max_connectionsoption). - Basic-auth unknown-user timing matches the configured mode. When
hash_passwordswasfalsethe unknown-user path ran PBKDF2 while the configured path ran a fast SHA-256 compare, revealing username existence by timing. The stand-in now matches the active mode.
Fixed
- The client reported version
2.0.0inclient_info; it now matches the library version, and the README dependency example no longer pins the stalev1.3.0tag.
Full Changelog: v2.0.1...v2.0.2