Security mailing lists by PureSourceCode

CVE-2026-40112

MEDIUM 6.1CVSS 3.1

PraisonAI Vulnerable to Stored XSS via Unsanitized Agent Output in HTML Rendering (nh3 Not a Required Dependency)

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.

Published
9 Apr 2026
Last modified
26 Oct 2026
Assigned by
security-advisories@github.com
NVD status
Analyzed
Weakness
CWE-79
Also known as
GHSA-cfg2-mxfj-j6pwPYSEC-2026-2910
Sources
NVDJSONOSV GHSA-cfg2-mxfj-j6pwJSONOSV PYSEC-2026-2910JSON

Scores

SourceScored byVersionScoreVector / decision
NVD nvd@nist.gov (Primary) CVSS 3.1 MEDIUM 6.1 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
NVD security-advisories@github.com (Secondary) CVSS 3.1 MEDIUM 5.4 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
OSV GitHub CVSS 3.1 MEDIUM 5.4 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
OSV PyPA CVSS 3.1 MEDIUM 5.4 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
NVD praison praisonai
cpe:2.3:a:praison:praisonai:*:*:*:*:*:*:*:*
< 4.5.128 4.5.128
OSV PyPI praisonai < 4.5.128 4.5.128

References

History

  • 25 Nov 2026 21:02 UTC · NVD: first stored (published 9 Apr 2026)
  • 25 Nov 2026 20:12 UTC · OSV: first stored (published 13 Jul 2026)
  • 25 Nov 2026 20:11 UTC · OSV: first stored (published 10 Apr 2026)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.