Claude Agent SDK is a Python SDK for Claude Code. Prior to 0.2.121, the resume option is passed to the Claude CLI as a separate token without validation, so a dash-leading value is parsed as an independent CLI flag. An attacker can inject the --mcp-config flag to define a stdio MCP server, causing arbitrary command execution at CLI startup outside the SDK permission controls. The issue is exploitable when an application passes untrusted input as the session ID to resume. This issue is fixed in version 0.2.121.
Advisories
Source ID Title
Github GHSA Github GHSA GHSA-h4mw-j7qp-8mwm Claude Agent SDK: Argument Injection via resume Option Allows Arbitrary Command Execution
Fixes

Solution

No solution given by the vendor.


Workaround

No workaround given by the vendor.

History

Fri, 16 Oct 2026 20:00:00 +0000

Type Values Removed Values Added
Description Claude Agent SDK is a Python SDK for Claude Code. Prior to 0.2.121, the resume option is passed to the Claude CLI as a separate token without validation, so a dash-leading value is parsed as an independent CLI flag. An attacker can inject the --mcp-config flag to define a stdio MCP server, causing arbitrary command execution at CLI startup outside the SDK permission controls. The issue is exploitable when an application passes untrusted input as the session ID to resume. This issue is fixed in version 0.2.121.
Title Claude Agent SDK: Argument Injection via resume Option Allows Arbitrary Command Execution
Weaknesses CWE-20
CWE-78
CWE-88
References
Metrics cvssV4_0

{'score': 9.2, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}


Projects

Sign in to view the affected projects.

cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-10-16T19:44:01.260Z

Reserved: 2026-09-23T14:35:50.128Z

Link: CVE-2026-96620

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-16T20:18:28.293

Modified: 2026-10-16T20:18:28.293

Link: CVE-2026-96620

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-16T22:00:16Z

Weaknesses