Ruflo MCP bridge flaw handed out shells and AI keys; a patch won’t undo poisoning

Ruflo's self-hosted Docker stack exposed an unauthenticated MCP bridge that gave attackers a shell, every provider API key and write access to the agents' learning store. The fix shipped in July, the CVE only now. What 3.16.3 changed, what it left open, and how to check and clean your host.

Christopher Ort
By i10X News Desk · Reviewed by Christopher Ort · 5 min read
Share
Open server cabinet with a glowing terminal window and a cracked shield in front of a cluster of connected agent nodes
Image: AI-generated, i10X
On this page
  1. One request to a shell, then to the agents' memory
  2. Who is really at risk
  3. What 3.16.3 changed, and what it left for later
  4. Check your host in five minutes
  5. If it was reachable: clean up, not just upgrade
  6. What is still open

Ruflo, the open source agent orchestration platform from GitHub developer ruvnet that began life as Claude Flow, has disclosed a maximum severity hole in the MCP bridge of its self-hosted Docker stack. Advisory GHSA-c4hm-4h84-2cf3 (CVE-2026-59726, CVSS 10.0) says the bridge answered tool calls on POST /mcp from anyone, while the shipped Compose file published both the bridge and its MongoDB database on every network interface. Version 3.16.3 fixes it. That release has been on npm since 1 July, 146 days before the advisory and the CVE went public on 24 November.

One request to a shell, then to the agents’ memory

In the old default setup, a caller needed no token to list the bridge’s tools and then invoke terminal_execute, which Ruflo’s own MCP backend serves through the devtools group that was switched on out of the box. The result is a shell as the node user inside the bridge container. From there the attacker can print the OpenAI, Google, OpenRouter and Anthropic keys that Compose passes in, start swarms that run on the victim’s bill, and read the chat history in MongoDB, which took connections from outside without any password. The project had actually put terminal_execute on a blocklist, but the maintainers’ design record shows that list was only consulted in the autopilot chat flow, never on the /mcp routes an attacker would use.

What lifts this above a typical exposed dev server is the learning store. With the agentdb_pattern-store tool, an intruder can plant a “pattern” in AgentDB that Ruflo later uses to guide its agents, so code produced for every user of that instance can carry the attacker’s logic. The maintainers’ ADR-166 is blunt that installing the patched image does not remove such entries. It also describes how the researcher’s proof of concept survived a restart: a preloaded script plus Docker’s restart: unless-stopped policy brought the backdoor back after the main process was killed.

Eli Ainhorn of Noma Security is credited with the report. According to the ADR it arrived on 30 June with an eight step exploit and a video, described as working against a default deployment on AWS EC2. The fix was merged as pull request 2521 the next day.

Who is really at risk

The bug sits in the self-hosted chat stack (chat UI, MCP bridge, nginx, MongoDB) that you start with docker compose up from the repository’s ruflo folder, or with the package’s docker:up script. Developers who only run Ruflo as a local MCP server inside Claude Code over stdio are not the scenario the advisory describes; the ADR quotes the report as saying the CLI defaults to localhost, though the maintainers still list confirming that as an open item.

The project itself is big. The repository has 82,367 stars, and npm counted 62,301 downloads of ruflo, 102,666 of @claude-flow/cli and 12,809 of claude-flow in the week to 23 November. The advisory names only the ruflo package, but the 3.16.3 release shipped all three in lockstep under the same version, and today all three sit at 3.80.6. Downloads measure CLI users, not Docker deployments, and nobody has published a count of reachable bridges.

What 3.16.3 changed, and what it left for later

We unpacked the npm tarballs of 3.16.2 and 3.16.3, compared the bridge code with the 3.16.3 release notes and read the current Compose file on the main branch:

LayerBefore 3.16.3From 3.16.3
Bridge bindAll interfaces, no host argument127.0.0.1 unless MCP_BIND_HOST is set; public bind without MCP_AUTH_TOKEN aborts at start
AuthenticationNoneBearer token, compared in constant time, when a token is set
terminal_executeReachable on /mcpOff unless MCP_ENABLE_TERMINAL=true, checked in executeTool for every route
MongoDBPort 27017 on all interfaces, no authPublished on 127.0.0.1 only, --auth, root password required to boot
ContainerWritableRead-only root filesystem with tmpfs
Keys in child processesFull environment copiedStill the full environment (scoped keys deferred)
CORSWildcardAllowlist possible via MCP_CORS_ORIGIN, default still wildcard

The last two rows matter for anyone who exposes the bridge on purpose. In the 3.16.3 code every spawned tool backend still receives a copy of the whole environment, including all provider keys, and the pull request lists per-backend key scoping as follow-up work. A token keeps strangers out; it does not shrink what a compromised tool process can see. Until today there was also no CVE for scanners such as npm audit or Dependabot to match, so the July release note was the only warning.

Check your host in five minutes

  • Run docker ps --format '{{.Names}} {{.Ports}}'. An entry like 0.0.0.0:3001->3001 or 0.0.0.0:27017->27017 means the old defaults. On the host, ss -ltnp | grep -E ':(3001|27017)\b' should show only 127.0.0.1.
  • From a second machine, test your own server: curl -s -X POST http://YOUR_HOST:3001/mcp -H 'Content-Type: application/json' -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'. A tool list means it is open; 401 means a token is in place.
  • Do not trust ufw alone. On many Linux hosts Docker writes its published ports into iptables ahead of ufw rules, so a deny rule for 3001 may never apply. Use the cloud security group or bind to 127.0.0.1.
  • Upgrade to 3.16.3 or later and pull the repository’s current docker-compose.yml. It now refuses to start without MONGO_INITDB_ROOT_PASSWORD and, for public use, MCP_AUTH_TOKEN. The official MongoDB image only creates that root user on an empty data directory, so with an old volume, confirm the chat UI can still log in.

If it was reachable: clean up, not just upgrade

  • Rotate the OpenAI, Google, OpenRouter and Anthropic keys and look through provider usage for runs you did not start.
  • Rebuild from a clean image instead of restarting, and check docker inspect for an unexpected NODE_OPTIONS preload. The ADR names /app/beacon.js as the file the proof of concept dropped.
  • Copy the AgentDB file (.swarm/memory.db in the Ruflo working directory) before touching it, then list stored patterns with npx ruflo memory list --namespace pattern. Look for entries nobody on your team wrote, especially ones that tell agents to add network calls, telemetry or “compliance” code. If you cannot tell, restore a copy from before the stack went online.
  • Check MongoDB for unknown users and for altered or missing collections.

Agent servers that trust whoever can reach them keep turning up on our MCP security tracker; earlier tonight it was the DBHub database server, whose HTTP transport should not face the network either. Stacks that nobody rebuilds are their own risk, as the MCPhantom research on deprecated servers showed. Ruflo adds a twist: a break-in that keeps shaping the agents’ output after the door is shut.

What is still open

The advisory does not mention exploitation in the wild, and there is no public figure on how many default stacks were reachable between the first release of the bridge and July. It is also unclear whether the per-backend key scoping has shipped in a later version. We will update this article if Ruflo or Noma Security publish more detail.

Christopher Ort

Christopher Ort

Christopher Ort is the editor of i10X News at i10x.ai. He has worked hands-on with AI tools, models and agent workflows for years and leads i10X’s coverage of AI launches, funding and research. He is the author of “The Style Penalty”, an SSRN study on how frontier AI models judge AI-written CVs, covered by heise online and t3n.

Editor's picks

  1. Ternary Bonsai 2.5 27B: A 5.9 GB Local Agent Model With Near-FP16 Tool Scores
  2. Dell Books $60.2 Billion in AI Orders as Its AI Server Backlog Hits $132 Billion
  3. Skills over MCP Arrives in Claude: What Server Skills Change for Your Agents
  4. Ruflo MCP bridge flaw handed out shells and AI keys; a patch won’t undo poisoning
  5. DBHub MCP server hit by 9.8 zero-day: crafted SQL can beat its access check