Ruflo's Default Docker Setup Handed Strangers an Agent Shell, and a Patch Alone Won't Clean a Poisoned Memory Store

A newly published advisory for Ruflo, the open-source agent harness for Claude Code and Codex, details CVE-2026-59726, a CVSS 10.0 flaw in which the default Docker Compose deployment exposed an unauthenticated MCP endpoint that could run shell commands, leak every provider API key and plant instructions in the project's shared learning store. Version 3.16.3 fixes it, but maintainers warn redeploying does not undo poisoning.

A hooded stranger pulls a lit lever inside an unattended open shipping container on a night dock, as dark ink clouds one of the glowing memory jars on its shelf.
A hooded stranger pulls a lit lever inside an unattended open shipping container on a night dock, as dark ink clouds one of the glowing memory jars on its shelf.

Ruflo, an open-source “agent meta-harness” for Claude Code and Codex with more than 82,000 stars on GitHub, has published a critical advisory showing that its default Docker deployment let anyone who could reach it run shell commands, read every AI provider key on the box and quietly rewrite what the system’s agents learn. The bug was fixed months ago; the advisory and its clean-up instructions went public this week.

The GitHub Security Advisory, GHSA-c4hm-4h84-2cf3, was published to the GitHub Advisory Database on November 24, 2026 at 21:01 UTC (November 25, 02:31 IST) and is tracked as CVE-2026-59726. It carries a CVSS 3.1 score of 10.0, the maximum, with a network attack vector, low complexity, no privileges and no user interaction required. It affects the ruflo npm package before version 3.16.3. The credit goes to Eli Ainhorn, a senior AI vulnerability researcher at Noma Security.

One unauthenticated POST

The problem sat in the MCP bridge that ships in ruflo/docker-compose.yml. That bridge exposed a POST /mcp endpoint with no authentication at all, and the compose file bound both the bridge on port 3001 and its MongoDB database on port 27017 to every network interface. According to the advisory, an attacker who could reach the port could call tools/call with the terminal_execute tool and get a shell inside the bridge container as the node user.

The project’s own remediation record, ADR-166, explains why that was possible. The bridge’s only middleware was JSON parsing and a CORS handler that allowed any origin. The devtools tool group, which exposes terminal_execute, was on by default. And spawned backends inherited the full parent environment, including the OpenAI, Google, OpenRouter and Anthropic keys injected by the compose file.

Ruflo’s maintainers had in fact blocklisted terminal_execute, but ADR-166 notes the check was enforced only in the “autopilot” chat flow. The /mcp and /mcp/:group routes never called it. The document describes this as a control that gave “false assurance,” because it guarded the one path an attacker did not need.

Eight steps, from recon to cover-up

The researcher’s proof of concept, which ADR-166 says the report confirmed against a default deployment on AWS EC2, chains eight plain HTTP requests with no credentials. It lists tools, opens a shell, greps the environment for keys, then uses Ruflo’s own swarm_init and agent_spawn tools to launch attacker-controlled agent swarms billed to the victim’s API accounts.

The step that sets this apart from a routine container escape is the fifth. Using the agentdb_pattern-store tool, the attacker writes malicious “compliance” or “best-practice” patterns into AgentDB, the learning store Ruflo uses to steer future outputs. The advisory says such a poisoned pattern “steers future AI outputs for all users of the instance.” In the proof of concept, the goal was generated code that beacons out to the attacker.

The remaining steps dump conversations from the unauthenticated MongoDB, plant a backdoor that survives restarts and wipe shell history.

Fixed in July, disclosed in November

ADR-166 records that the coordinated-disclosure report arrived on June 30, 2026, and that maintainers verified every substantive claim against the source the same day, concluding “The report is accurate.” Version 3.16.3, which contains the fix, was published on GitHub on July 1, 2026. The ADR says the reporter’s name was withheld until an embargo lifted and the CVE went public.

The 3.16.3 changes bind the bridge to 127.0.0.1 by default and make the process refuse to boot on a public interface unless MCP_AUTH_TOKEN is set. They add bearer-token authentication using a constant-time comparison, enforce the terminal_execute gate on every route behind an explicit MCP_ENABLE_TERMINAL=true opt-in, turn on MongoDB authentication with a required root password, make the bridge filesystem read-only and wire in a CORS allowlist. Maintainers chose loopback-by-default over a token-only fix because MCP is meant to be local, with public exposure a deliberate opt-in.

One detail differs between documents. The advisory scores the flaw at 10.0, while the 3.16.3 release notes and ADR-166 estimated about 9.8.

Why upgrading is not the end of it

Maintainers are explicit that operators of any exposed instance must do more than redeploy. The advisory tells them to firewall ports 3001 and 27017 immediately, rotate OpenAI, Google, OpenRouter and Anthropic keys, audit MongoDB for tampering and search the AgentDB pattern store for injected entries. “A patched redeploy alone does NOT undo poisoning,” it states.

ADR-166 also notes its limits: maintainers did not run the proof of concept against any host and did not measure how many live instances were exposed, so there is no public count of affected deployments.

Topics
  • #Ruflo
  • #MCP
  • #AI Agents
  • #Vulnerability
  • #Supply Chain Security
Raj M

Author

Raj M

Contributor

AI Systems Architect is a seasoned technology leader with over 15 years of experience in the IT industry working with Fortune 500 companies. With a solid foundation in multi-agent systems, open-source LLM infrastructure, and enterprise deployment, he excels at building scalable production-grade AI platforms.