All vulnerabilities
CVE-2026-60087GHSA-29r9-67vg-qj56PYSEC-2026-4265

praisonaiagents: PraisonAI: Human-in-the-loop tool approval is cached by tool name and silently reused for all subsequent calls with arbitrary arguments

MervinPraison praisonaiagentspipLibraries & packages
CVSS
6.1Medium
ExploitationPublic exploit codeCISA's assessment says proof of concept code is public, assessed 15 Jul 2026. Not in the KEV catalogCISA via CVE List
Exploit odds (EPSS)0.15%Chance of exploitation activity in the next 30 days, higher than 3% of CVEs. Scored 23 Oct 2026FIRST EPSS
Fixed in1.6.78Fixed versionGitHub
Published15 Jul 2026Updated 15 Oct 2026CVE List

What fixes it

  • 1.6.78praisonaiagents, pipGitHub
  • 1.6.78PraisonAICVE List
  • 1.6.78praisonaiagents, PyPIOSVpip install "praisonaiagents>=1.6.78"

A fixed version on one release line is not the upgrade target for every line. Check your exact version and any vendor backports.

Description

Summary

PraisonAI gates dangerous tools (file writes, deletes, shell/code execution) behind an interactive approval prompt. The first approval of a tool is cached for the remainder of the run and silently reused for all later invocations of that tool with arbitrary, unreviewed arguments.

Root cause

ApprovalRegistry.is_already_approved (src/praisonai-agents/praisonaiagents/approval/registry.py, around line 181) returns True whenever the tool name is present in a per-run context set. The cache is keyed on tool name only — arguments are not part of the key.

approve_sync / approve_async (around lines 224-226 / 278-279) short-circuit on that cache before the approval backend is consulted.

clear_approved (around lines 186-187) is the only routine that clears the cache, but it is never invoked in the shipped library (only in tests). The cache persists for the entire agent run and is inherited by child tasks via contextvars.

Critical-tier tools (execute_command, execute_code) are exempt from the cache. But high-risk tools like write_file are not.

Proof of concept

from praisonaiagents.approval.registry import ApprovalRegistry
from praisonaiagents.approval.protocols import ApprovalDecision, ApprovalRequest

class CountingBackend:
    def __init__(self): self.prompts = []
    def request_approval_sync(self, request):
        self.prompts.append((request.tool_name, dict(request.arguments)))
        return ApprovalDecision(approved=True, reason="human approved")

backend = CountingBackend()
reg = ApprovalRegistry()
reg.set_backend(backend)
reg.add_requirement("write_file", "high")

d1 = reg.approve_sync("agent", "write_file", {"path": "/tmp/safe.txt", "content": "hi"})
# Human prompted — approves a benign write

d2 = reg.approve_sync("agent", "write_file", {"path": "/etc/crontab", "content": "* * * * * root evil"})
# NO prompt — auto-approved from cache

assert len(backend.prompts) == 1
assert d2.reason == "Already approved in context"

Negative control: execute_command (critical) re-prompts on every call — 2 prompts for 2 calls.

Impact

A write_file approval for a benign path authorizes every later write_file call in the session with arbitrary arguments. A model steered by malicious input can write to sensitive locations with no further human prompt.

Suggested fix

  • Include arguments in the approval cache key, or re-prompt on argument change.
  • Expire the cache per-call or per-turn.
  • Do not inherit the cache into child tasks.

Text from GitHub Advisory Database

Affected versions 54

  • praisonaiagents, pip<= 1.6.77GitHub
  • PraisonAIaffected: all versions before 1.6.78CVE List
  • PraisonAIunaffected: 1.6.78CVE List
  • praisonaiagents, PyPIfrom first release, fixed in 1.6.78OSV
  • praisonaiagents, PyPI0.0.1OSV
  • praisonaiagents, PyPI0.0.10OSV
  • praisonaiagents, PyPI0.0.100OSV
  • praisonaiagents, PyPI0.0.101OSV
  • praisonaiagents, PyPI0.0.102OSV
  • praisonaiagents, PyPI0.0.103OSV
  • praisonaiagents, PyPI0.0.104OSV
  • praisonaiagents, PyPI0.0.105OSV
  • praisonaiagents, PyPI0.0.106OSV
  • praisonaiagents, PyPI0.0.107OSV
  • praisonaiagents, PyPI0.0.108OSV
  • praisonaiagents, PyPI0.0.109OSV
  • praisonaiagents, PyPI0.0.11OSV
  • praisonaiagents, PyPI0.0.110OSV
  • praisonaiagents, PyPI0.0.111OSV
  • praisonaiagents, PyPI0.0.112OSV
  • praisonaiagents, PyPI0.0.113OSV
  • praisonaiagents, PyPI0.0.114OSV
  • praisonaiagents, PyPI0.0.115OSV
  • praisonaiagents, PyPI0.0.116OSV
  • praisonaiagents, PyPI0.0.117OSV
  • praisonaiagents, PyPI0.0.118OSV
  • praisonaiagents, PyPI0.0.119OSV
  • praisonaiagents, PyPI0.0.12OSV
  • praisonaiagents, PyPI0.0.120OSV
  • praisonaiagents, PyPI0.0.121OSV
  • praisonaiagents, PyPI0.0.122OSV
  • praisonaiagents, PyPI0.0.123OSV
  • praisonaiagents, PyPI0.0.124OSV
  • praisonaiagents, PyPI0.0.125OSV
  • praisonaiagents, PyPI0.0.126OSV
  • praisonaiagents, PyPI0.0.127OSV
  • praisonaiagents, PyPI0.0.128OSV
  • praisonaiagents, PyPI0.0.129OSV
  • praisonaiagents, PyPI0.0.13OSV
  • praisonaiagents, PyPI0.0.130OSV
  • praisonaiagents, PyPI0.0.131OSV
  • praisonaiagents, PyPI0.0.132OSV
  • praisonaiagents, PyPI0.0.133OSV
  • praisonaiagents, PyPI0.0.134OSV
  • praisonaiagents, PyPI0.0.135OSV
  • praisonaiagents, PyPI0.0.136OSV
  • praisonaiagents, PyPI0.0.137OSV
  • praisonaiagents, PyPI0.0.138OSV
  • praisonaiagents, PyPI0.0.139OSV
  • praisonaiagents, PyPI0.0.14OSV
  • praisonaiagents, PyPI0.0.140OSV
  • praisonaiagents, PyPI0.0.141OSV
  • praisonaiagents, PyPI0.0.142OSV
  • praisonaiagents, PyPI0.0.143OSV

References 5