Categories
CVE-2026-47392 critical CVSS 9.9

Vulnerability in praisonaiagents (CVE-2026-47392)

Summary

Vulnerability in praisonaiagents (CVE-2026-47392). Successful exploitation can lead to full system takeover. Exploitable via print.__self__. Mitigation: upgrade to 1.6.40 or later.

Original description

The description as published by the source.

Summary

execute_code() in praisonaiagents/tools/python_tools.py (v1.6.37, subprocess sandbox mode) can be fully bypassed using print.__self__ to retrieve the real Python builtins module, from which __import__ can be extracted via vars() and runtime string construction. This achieves arbitrary OS command execution on the host, completely defeating the sandbox.

This is a novel bypass that survives all patches for CVE-2026-39888 (frame traversal), CVE-2026-34938 (str subclass), and CVE-2026-40158 (type.__getattribute__ trampoline).


Severity

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H — 9.9 Critical


Root Cause

Three independent gaps in the AST-based security validation:

Gap 1: __self__ missing from _blocked_attrs

In CPython, all built-in functions (C-level functions) have a __self__ attribute that returns the module they belong to. The built-in functions in safe_builtins (print, len, range, etc.) are the real CPython built-in functions, so print.__self__ returns ``.

The _blocked_attrs frozenset (line 52) does NOT include __self__. The AST check at line 74 only blocks attributes that are IN this set, so print.__self__ passes.

Gap 2: vars not blocked as callable or attribute

builtins.vars(obj) returns obj.__dict__. The function name vars is not in the AST Call blocklist (line 83: only blocks exec, eval, compile, __import__, open, input, breakpoint, setattr, delattr, `dir…

Source: GitHub Security Advisories (Global) NVD GitHub Advisory

Auto-generated summary

Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.

A vulnerability tracked as CVE-2026-47392 has been found in praisonaiagents.
Attackers can target a specific entry point like print.__self__ over the network to misuse the product.
Successful exploitation can lead to full system takeover. CVSS score: 9.9/10.
What to do: upgrade praisonaiagents to 1.6.40 or later.
If unsure, ask your IT team or search "praisonaiagents CVE-2026-47392" on the vendor's site.

CVE-2026-47392 (praisonaiagents) — CWE-184 / CVSS v3 9.9
Attack vector: remote (network-reachable) / no user interaction
Attack surface: print.__self__ / builtins / __import__ / type.__getattribute__
Patched: 1.6.40 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.

❓ What is the problem

A vulnerability (CWE-184) exists in praisonaiagents. Attackers reach the vulnerable code path via print.__self__.

📍 Affected scope

Check the vendor advisory for the affected versions of praisonaiagents. Attack surface: print.__self__ / builtins / __import__ / type.__getattribute__.

🔥 Severity

Severity: Critical (CVSS 9.9/10). Successful exploitation can lead to full system takeover.

🔧 How to fix

Update to 1.6.40.

🛡️ Workaround

Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.

🔍 Detection

Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'praisonaiagents' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.

Response actions

Concrete steps and command examples for SOC/SRE teams to execute in order

  1. 1
    Identify exposure identify
    grep -r 'praisonaiagents' . | grep -v node_modules

    リポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で praisonaiagents を grep し、稼働しているサービス・バージョンを把握する。

  2. 2
    Apply patch patch
    Upgrade praisonaiagents to 1.6.40

    ステージング環境で 1.6.40 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。

  3. 3
    Post-deployment verification verify
    Confirm patched version is live in production

    パッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。

Affected packages

pip praisonaiagents
[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.40"}]}]
pip PraisonAI
[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.6.40"}]}]
PyPI praisonaiagents
[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.40"}]}]
PyPI praisonai
[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.6.40"}]}]

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details