CriticalVulnerability
GHSA-4mr5-g6f9-cfrh: PraisonAI vulnerable to sandbox escape via `print.__self__` builtins module leak in `execute_code` (subprocess mode)
- Identifiers
- CVE-2026-47392GHSA-4mr5-g6f9-cfrh
- Published
- Record updated
- Affected
- PraisonAI <= 4.6.39, fixed in 4.6.40
- praisonaiagents <= 1.6.39, fixed in 1.6.40
- Known exploitation
- Not listed in the CISA Known Exploited Vulnerabilities catalog at the last check.
- EPSS
- 0.9%
Summary
PraisonAI's `execute_code()` in `praisonaiagents/tools/python_tools.py` (v1.6.37, subprocess sandbox mode) can be fully bypassed. Using `print.__self__` to reach the real `builtins` module, then `vars()` and runtime string construction to obtain `__import__`, lets an attacker run arbitrary OS commands on the host, defeating the sandbox. The bypass survives patches for CVE-2026-39888, CVE-2026-34938 and CVE-2026-40158, and the advisory rates it CVSS 9.9 Critical.
Mitigation
The source does not state a fix yet. Check the original advisory for updates.
Related items
- MediumAI Agents Navigate Unfamiliar OT Systems and Move Equipment in Minutes, Booz Allen FindsSimilar attack · SecurityWeek
- MediumHow Claude Code’s 256KB blind spot put developers’ secrets in the preview paneSimilar attack · CSO Online
- InfoHow to Run a Deepfake Readiness Drill Before a Cloned Voice Calls Your TeamSimilar attack · The Hacker News
- InfoResearchers Used a Public OpenAI Model to Build a $250,000 Chrome Full-Chain Exploit in Six DaysSimilar attack · The Hacker News
- MediumAn AI Agent Found a Critical OTP Bypass in Production. The Attack Was the Easy Part.Similar attack · The Hacker News