Quick answers
- Is CVE-2026-40111 exploited in the wild?
- No. Junglewise Threat Intelligence has no report of CVE-2026-40111 being exploited in the wild.
- How severe is CVE-2026-40111?
- Critical severity, with a CVSS score of 8.8, published 9 April 2026.
- Which products and versions are affected?
- praisonaiagents (PyPI) ECOSYSTEM:introduced=0,fixed=1.5.128.
- Is there a fix for CVE-2026-40111?
- Yes. praisonaiagents (PyPI): upgrade to 1.5.128 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
- How is CVE-2026-40111 attacked?
- It is attacked with local access or over the network, in a software library.
- Am I affected by CVE-2026-40111?
- Check whether you run MervinPraison PraisonAI Agents, Praisonaiagents or praisonaiagents (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.
How to fix
- praisonaiagents (PyPI): upgrade to 1.5.128 or later
pip install "praisonaiagents>=1.5.128"
Technical details
The vulnerability exists in `src/praisonai-agents/praisonaiagents/memory/hooks.py` where user-controlled command strings from `hooks.json` are passed directly to `subprocess.run()` with `shell=True`. The application lacks any sanitization or validation (such as `shlex.quote()` or allowlisting) for these commands. Attackers can exploit this via two surfaces: directly through hook event configurations or indirectly via prompt injection if an agent has file-write access to the workspace, allowing it to overwrite `.praisonai/hooks.json`. This enables arbitrary command execution with the privileges of the agent process and allows for persistent backdoors that trigger during standard lifecycle events like `BEFORE_TOOL` or `AFTER_TOOL`. A fix is available in version 1.5.128.
Affected products
- MervinPraison praisonaiagents <= 1.5.126
Identifiers
- CVE-2026-40111
- GHSA-v7px-3835-7gjx
- PYSEC-2026-487
Timeline
- 2026-04-09: disclosed
- 2026-04-10: advisory: GHSA-v7px-3835-7gjx published
- 2026-04-10: patched: Fixed in version 1.5.128