Ad

CVE-2026-40112

MEDIUM CVSS 3.1: 6.1 EPSS 0.03%
Updated Apr 17, 2026
Flask
Parameter Value
CVSS 6.1 (MEDIUM)
Affected Versions before 4.5.128
Fixed In 4.5.128
Type CWE-79 (Cross-Site Scripting (XSS))
Vendor Flask
Public PoC No

PraisonAI is a multi-agent teams system. Prior to 4.5.128, the Flask API endpoint in src/praisonai/api.py renders agent output as HTML without effective sanitization. The _sanitize_html function relies on the nh3 library, which is not listed as a required or optional dependency in pyproject.toml.

When nh3 is absent (the default installation), the sanitizer is a no-op that returns HTML unchanged. An attacker who can influence agent input (via RAG data poisoning, web scraping results, or prompt injection) can inject arbitrary JavaScript that executes in the browser of anyone viewing the API output. This vulnerability is fixed in 4.5.128.

Attack Parameters

Attack Vector
Network
Can be exploited remotely
Attack Complexity
Low
Easy to exploit
Privileges Required
None
No privileges needed
User Interaction
Required
User action required

Impact Assessment

Confidentiality
Low
Partial data leak
Integrity
Low
Partial data modification
Availability
None
No disruption

CVSS Vector v3.1

Vulnerable Products 1

Configuration From (including) Up to (excluding)
Praison Praisonai
cpe:2.3:a:praison:praisonai:*:*:*:*:*:*:*:*
4.5.128