Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
ReconAuthenticate to PraisonAI API
-
DeliveryCraft malicious table_prefix with SQL payload
-
ExploitSubmit configuration change request
-
InstallTrigger conversation store initialization
-
C2Injected SQL executes in backend
-
ExecuteExtract sensitive data or modify database schema
-
ImpactPersist access via database backdoors
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Parameterized queries, prepared statements
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Persistence The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Requires authenticated access (PR:L) to PraisonAI instance where table_prefix parameter is controllable via external input. Specifically exploitable when: (1) application uses multi-tenant architecture with per-tenant table prefixes derived from user-supplied tenant identifiers, (2) API endpoints accept storage configuration parameters that flow to backend constructors, (3) user-editable configuration files (YAML/JSON) control table_prefix values loaded at runtime, or (4) administrative interfaces allow dynamic backend reconfiguration. Default deployments using hardcoded table_prefix='praison_' are NOT vulnerable. Exploitation is NOT limited by database type-all nine unpatched backends (MySQL, PostgreSQL, Turso, SingleStore, Supabase, SurrealDB, and async variants) are equally exploitable. PostgreSQL backend has additional attack surface via unvalidated schema parameter at line 88. Network access required (AV:N) but low attack complexity (AC:L) once authenticated. |
| Impact | CVSS 8.1 (High) with vector AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N reflects authenticated network-based exploitation with low complexity enabling high confidentiality and integrity impact. Real-world risk is CONTEXTUAL: default configuration using table_prefix='praison_' is NOT vulnerable; exploitation requires deployments where table_prefix is dynamically set from external input-common in multi-tenant SaaS architectures, API-driven configuration systems, or environments allowing user-modifiable config files. The 52 injection points across nine backends represent significant attack surface, but PR:L (low privilege authentication required) and scope limited to backend data access constrains blast radius. MISSING DATA IMPACTS ASSESSMENT: No EPSS score available to gauge exploitation likelihood; no CISA KEV listing indicates active exploitation not confirmed; vendor advisory confirms patch but public POC availability unknown. Risk is HIGH for multi-tenant deployments with external table_prefix control, MEDIUM for single-tenant with authenticated API access, LOW for hardcoded default configurations. Incomplete initial fix pattern (CVE-2026-40315) suggests systematic code review debt-defenders should verify all backends are upgraded to patched versions. |
| Exploit ScenarioDerived | Authenticated attacker in multi-tenant PraisonAI deployment modifies API request or configuration file to set table_prefix to "praison_'; DROP TABLE users; --". Application passes unsanitized prefix into f-string SQL in postgres.py line 89 during conversation store initialization. Resulting query CREATE TABLE praison_'; DROP TABLE users; --_conversations executes SQL injection payload, dropping the users table and potentially escalating to full database compromise through subsequent injections. No public POC confirmed but exploitation pattern identical to previously fixed CVE-2026-40315. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 08, 2026
SQL injection in PraisonAI's multi-backend conversation storage system allows authenticated attackers to execute arbitrary SQL commands. The incomplete fix for CVE-2026-40315 validated input only in SQLiteConversationStore, leaving nine other database backends (MySQL, PostgreSQL, Turso, SingleStore, Supabase, SurrealDB, and their async variants) vulnerable to f-string SQL injection via unvalidated table_prefix and schema parameters. 52 injection points exist across the codebase. Exploitable in multi-tenant deployments or API-driven configurations where table_prefix is derived from external input. Patches released in praisonai 4.6.9 and praisonaiagents 1.6.9 address all affected backends. EPSS and KEV data unavailable; no public POC confirmed at time of analysis.
RemediationAI
Upgrade immediately to praisonai version 4.6.9 or later and praisonaiagents version 1.6.9 or later via pip install --upgrade praisonai praisonaiagents. Vendor advisory at https://github.com/MervinPraison/PraisonAI/security/advisories/GHSA-rg3h-x3jw-7jm5 confirms patches implement regex validation (^[a-zA-Z0-9_]*$) across all affected backends. If immediate patching is blocked, implement these SPECIFIC compensating controls: (1) Hardcode table_prefix to 'praison_' in all backend initialization code-prevents external input entirely but breaks multi-tenant table isolation; (2) Deploy web application firewall rules blocking SQL metacharacters (semicolon, dash-dash, quotes) in any API parameters mapped to storage configuration-may cause false positives with legitimate underscores in prefixes; (3) Restrict database user privileges to DML-only (revoke CREATE/DROP/ALTER)-limits injection impact to data exfiltration/modification but prevents normal table creation workflows; (4) Enable database query logging and monitor for suspicious DDL statements containing unusual table/schema names-detective control only, no prevention. Each workaround trades functionality for security; patching remains the only complete fix.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 4 packages in pypi, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
PraisonAI is a multi-agent AI teams system with conversation persistence backed by multiple database systems. The vulnerability stems from CWE-89 (SQL Injection) via unsafe f-string formatting in Python database connectors. The original CVE-2026-40315 fix implemented regex validation (^[a-zA-Z0-9_]*$) for table_prefix in sqlite.py:52 only. The remaining backends (mysql.py, postgres.py, async_sqlite.py, async_mysql.py, async_postgres.py, turso.py, singlestore.py, supabase.py, surrealdb.py) continued using table_prefix directly in f-string SQL DDL and DML statements without sanitization. PostgreSQL backend additionally accepts an unvalidated schema parameter at line 88. Affected packages are pip/praisonai (vulnerable <= 4.5.148) and pip/praisonaiagents (vulnerable <= 1.6.7), indicating the vulnerability exists in both the core PraisonAI framework and its standalone agents library.
Know when Praisonai 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:L/UI:N/S:U/C:H/I:H/A:N
Primary rating from Vendor (github) · only source for this CVE.
CVSS VectorVendor: github
DescriptionCVE.org
PraisonAI is a multi-agent teams system. Prior to praisonai version 4.6.9 and praisonaiagents version 1.6.9, the fix for CVE-2026-40315 added input validation to SQLiteConversationStore only. Nine sibling backends - MySQL, PostgreSQL, async SQLite/MySQL/PostgreSQL, Turso, SingleStore, Supabase, SurrealDB - pass table_prefix straight into f-string SQL. Same root cause, same code pattern, same exploitation. 52 unvalidated injection points across the codebase. postgres.py additionally accepts an unvalidated schema parameter used directly in DDL. This issue has been patched in praisonai version 4.6.9 and praisonaiagents version 1.6.9.
Executive ViewAI
PraisonAI versions prior to 4.6.9 contain a critical SQL injection vulnerability affecting nine database backends that allows authenticated attackers to execute arbitrary SQL commands, posing a significant risk to organizations using PraisonAI for conversation storage, particularly in multi-tenant or API-driven deployments where table prefixes are externally controlled. This represents a regression from a prior incomplete patch and exposes customer data to unauthorized access, modification, and potential exfiltration.
Apply vendor patch. Until upgrade is feasible, restrict API access to trusted internal networks only, disable external control of table_prefix parameters, audit database user privileges to least-privilege accounts, and monitor database query logs for anomalous SQL syntax patterns.
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
SQL injection exploits the way applications construct database queries by mixing user input directly into SQL statements.
Remote code execution in PraisonAI before 1.6.78 allows attackers to run arbitrary Python on the host by manipulating th
PraisonAI's TypeScript MCP server (npm package `praisonai`, versions 1.5.0 through 1.7.1) exposes an HTTP JSON-RPC trans
WebSocket origin-validation bypass in PraisonAI's Browser Server (praisonai/browser/server.py) before 4.6.58 lets an att
PraisonAI's `praisonai serve` subsystem (agents and unified modes) accepts an `--api-key` CLI flag that is parsed but ne
System prompt extraction and unauthorized tool invocation in PraisonAI before 4.6.78 arise because the prompt-injection
Unauthenticated remote agent invocation in PraisonAI versions 4.6.34 through 4.6.57 allows any network-reachable caller
SSRF protection bypass in PraisonAI's praisonaiagents library (all versions before 1.6.58) lets low-privileged users rou
Server-side request forgery in PraisonAI's Crawl4AI/Chromium crawling backend (all versions before 1.6.78) lets low-priv
Authentication fail-open in PraisonAI's Recipe HTTP server allows unauthenticated remote attackers to invoke recipe exec
Authentication bypass in PraisonAI's AgentServer component exposes all routes - /publish, /events, /info, /health - to u
Arbitrary Python code execution in PraisonAI's workflow include feature allows an attacker who controls a local recipe d
Server-side request forgery in PraisonAI's web_crawl() function (versions 1.5.128-1.6.57) allows an attacker who can inf
EUVD-2026-28594
GHSA-rg3h-x3jw-7jm5
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB