You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(ingestion): use HTTP transport for MCP connector - #32342
Vishnuujain
changed the title
fix(ingestion): remove Stdio transport from MCP connector to close RCE (GHSA-8f6m-cj4x-3p96)
fix(ingestion): remove Stdio transport from MCP connector
Sep 1, 2026
The generated TypeScript types (src/generated/) and dereferenced JSON
schemas (src/jsons/) have been automatically updated based on JSON schema
changes in this PR.
Vishnuujain
changed the title
fix(ingestion): remove Stdio transport from MCP connector
fix(ingestion): use HTTP transport for MCP connector
Sep 1, 2026
The generated TypeScript types (src/generated/) and dereferenced JSON
schemas (src/jsons/) have been automatically updated based on JSON schema
changes in this PR.
The generated TypeScript types (src/generated/) and dereferenced JSON
schemas (src/jsons/) have been automatically updated based on JSON schema
changes in this PR.
Switches the MCP ingestion connector to HTTP transport only, removing the local subprocess (Stdio) path and hardening HttpTransport with Accept header validation, proper SSE-framed response parsing with multi-line data: reassembly, and Mcp-Session-Id passthrough. Stdio-configured servers are now discovered as governance records without being started. E2E documentation mismatch and SSE parse behavior have been resolved.
✅ 2 resolved✅ Quality: E2E doc mismatch: --sse-port with StreamableHTTP to /mcp
📄 ingestion/tests/integration/mcp/test_mcp_integration.py:361-375
The (skipped) E2E test configures TransportType.StreamableHTTP with url http://localhost:8096, so the client POSTs to <url>/mcp, but the docstring instructs starting the proxy with mcp-proxy --sse-port 8096, which serves an SSE endpoint (typically /sse) rather than a StreamableHTTP /mcp endpoint. Anyone running the test as documented would hit a 404. Update the command/flag or the transport/url so the documented setup matches the code path.
✅ Edge Case: SSE parse returns first data: frame, not matching id
📄 ingestion/src/metadata/ingestion/source/mcp/client.py:113-123
_parse_jsonrpc returns json.loads of the first data: line it encounters. For a StreamableHTTP server, a POST response streamed as text/event-stream may emit server-to-client notifications or other events before the actual JSON-RPC response, and SSE also permits a single event to span multiple data: lines. Returning the first frame unconditionally can yield the wrong message (or a partial one). Consider matching the response id (the request uses uuid4) and/or concatenating consecutive data: lines per event before decoding.
Options
Display: compact → Showing less information.
Comment with these commands to change the behavior for this request:
Compact
gitar display:verbose
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
safe to testAdd this label to run secure Github workflows on PRs
4 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
HttpTransporthardened:Acceptheader, JSON or SSE-framed responses (multi-linedata:reassembly, skips pre-response notifications),Mcp-Session-Idpassthrough.Stdioand the command/args/env fields are marked deprecated in descriptions (enum values kept, non-breaking).Fixes #32343