Claude Agent SDK: Argument Injection via resume Option Allows Arbitrary Command Execution
Default status is the baseline for the product, each version can override it (e.g. patched versions marked unaffected).
| Vendor | Product | Default status | Versions | ||||||
|---|---|---|---|---|---|---|---|---|---|
| anthropics | claude-agent-sdk-python | affected |
|
No data.
No data.
No data available yet.
| Source | ID | Title |
|---|---|---|
Github GHSA |
GHSA-h4mw-j7qp-8mwm | Claude Agent SDK: Argument Injection via resume Option Allows Arbitrary Command Execution |
No CVSS v3.1
No CVSS v3.0
No CVSS v2
This CVE is not in the KEV list.
Exploit prediction score: < 1% (0.705% probability within 30 days)
| Type | Values Removed | Values Added |
|---|---|---|
| Metrics |
ssvc
|
| 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
|
No data.