{"answers":{"affected":"3 open source packages ship an affected version, including github.com/modelcontextprotocol/go-sdk.","exploited":"There is no known exploitation of GHSA-q382-vc8q-7jhj in the wild and no public exploit code.","fix":"Upgrade github.com/modelcontextprotocol/go-sdk to 1.4.1 or later.","what":"GHSA-q382-vc8q-7jhj is a vulnerability in github.com/modelcontextprotocol/go-sdk, published on 19 Mar 2026. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for GHSA-q382-vc8q-7jhj and fix it if it is affected.\n\nWhat it is: GHSA-q382-vc8q-7jhj is a vulnerability in github.com/modelcontextprotocol/go-sdk, published on 19 Mar 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: There is no known exploitation of GHSA-q382-vc8q-7jhj in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- github.com/modelcontextprotocol/go-sdk (Go): affected all versions; fixed in 1.4.1\n- github.com/modelcontextprotocol/go-sdk (Go): affected all versions; fixed in 1.4.1\n- github.com/modelcontextprotocol/go-sdk (Go): affected all versions; fixed in 1.4.1\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/GHSA-q382-vc8q-7jhj/ (Markdown: https://insights.sbomify.com/GHSA-q382-vc8q-7jhj/index.md)","id":"GHSA-q382-vc8q-7jhj","markdown":"https://insights.sbomify.com/GHSA-q382-vc8q-7jhj/index.md","name":"GHSA-q382-vc8q-7jhj","record":{"aliases":["GO-2026-4770"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["security_bypass"],"network_reachable":"yes","non_default_config":false,"product_category":"Go MCP SDK","requires_auth":"none","summary":"Attackers can bypass intermediary inspection and policy filters in MCP messages by exploiting null Unicode character handling in JSON parsing.","user_interaction":"not_required","vuln_class":"security_feature_bypass"},"analysis_generated_by":"qwen3.8-flash-next","assigner":null,"cpe":[],"cvss":{"score":null,"severity":null,"source":null,"vector":null,"version":null},"cwes":[],"description":"The Go SDK recently transitioned to the `segmentio/encoding` library for JSON parsing in version 1.3.1. While this change addressed both case-insensitivity and ASCII folding issues, the new parser implemented aggressive key matching that treated keys with `null` Unicode characters appended at the end as equivalent to their base strings.\n\n#### Impact\n\nWhen combined with duplicate keys, the described behavior leads to a \"last key wins\" resolution that could override the intended MCP message. This had the potential for:\n  - **Bypassing intermediary inspection:** Proxies or policy layers that matched on exact field names may have failed to detect or filter these messages.\n  - **Cross-implementation inconsistency:** Other MCP SDKs (TypeScript, Python) use case-sensitive parsing and would reject the same messages, creating potential security-boundary confusion.\n\n####  Fix:\n\nThe `segmentio/encoding` package was patched with a fix in https://github.com/segmentio/encoding/commit/7d5a25dbc5da13aed3cb047a127e4d0e96f536fb and a new version of the package was released (`v0.5.4`). The SDK switched to the patched version of the dependency in 724dd47aa. Users are advised to update to v1.4.1 to resolve this issue.\n\n#### Credits:\nThank you to Francesco Lacerenza (Doyensec) for reporting this issue.","ecosystems":["Go"],"exploits":{"exploitdb":null,"first_seen":null,"github_poc":null,"max_poc_stars":null,"metasploit":null,"nuclei":null,"refs":[],"tier":null},"has_fix":true,"headline":"Improper handling of null Unicode character when parsing JSON in github.com/modelcontextprotocol/go-sdk","id":"GHSA-q382-vc8q-7jhj","indexable":true,"kev":null,"kind":"advisory","links":{"ecosystem":"Go","product":null,"products":[],"type":"security_feature_bypass","year":"2026"},"n_packages":3,"n_references":null,"packages":[{"ecosystem":"Go","fixed":["1.4.1"],"introduced":["0"],"last_affected":[],"package":"github.com/modelcontextprotocol/go-sdk","purl":null,"source":"GHSA-q382-vc8q-7jhj"},{"ecosystem":"Go","fixed":["1.4.1"],"introduced":["0"],"last_affected":[],"package":"github.com/modelcontextprotocol/go-sdk","purl":"pkg:golang/github.com/modelcontextprotocol/go-sdk","source":"GHSA-q382-vc8q-7jhj"},{"ecosystem":"Go","fixed":["1.4.1"],"introduced":["0"],"last_affected":[],"package":"github.com/modelcontextprotocol/go-sdk","purl":"pkg:golang/github.com/modelcontextprotocol/go-sdk","source":"GO-2026-4770"}],"products":null,"published":"2026-03-19","related":[],"sources":[{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CC BY 4.0","name":"Go Vulnerability Database","prefix":"GO"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":null,"updated":null,"vendors":null},"summary":"Attackers can bypass intermediary inspection and policy filters in MCP messages by exploiting null Unicode character handling in JSON parsing.","url":"https://insights.sbomify.com/GHSA-q382-vc8q-7jhj/"}