# Lock down ruflo MCP bridge defaults (CVE-2026-59726)

> Raise npm ruflo to 3.16.3+, bind MCP to loopback, require a bearer token, and rotate exposed keys.

Source: https://fullbytedeveloper.com/blog/lock-down-ruflo-mcp-bridge-defaults
Published here: 2026-11-26

GHSA-c4hm-4h84-2cf3 rates unauthenticated RCE in the ruflo MCP bridge default docker-compose deployment as Critical, CVSS 3.1 10.0. The CVE id is CVE-2026-59726. The npm floor is ruflo 3.16.3. Treat a public MCP bind as laptop RCE for anyone running the old defaults. [1]

Related reading: [Patch Xen Orchestra empty-object login (CVE-2026-133469)](/blog/patch-xen-orchestra-empty-login-bypass), [Update MCP reference server packages](/blog/update-mcp-reference-server-packages) and [MCP Inspector security update check](/blog/mcp-inspector-security-update-check). Browse the [Security topic](https://fullbytedeveloper.com/blog/topic/security).

## Confirm the default bind path

GHSA-c4hm-4h84-2cf3 is titled "Unauthenticated RCE in ruflo MCP bridge default docker-compose deployment." Package: npm `ruflo`. Published July 1, 2026. Affected versions: below 3.16.3. Patched: 3.16.3. [1]

The MCP bridge shipping in `ruflo/docker-compose.yml` exposed `POST /mcp` with no authentication. The docker-compose defaults bound the bridge and MongoDB to all interfaces. Combined, an unauthenticated network attacker could invoke `tools/call` to `terminal_execute` inside the bridge container, obtain a shell as node (uid 1000), read every provider API key from the container env, spawn attacker-controlled swarms on the victim's keys, and persist a poisoned pattern into the AgentDB learning store. [1]

The tool blocklist that mentions `terminal_execute` was enforced only in the autopilot flow. `POST /mcp` and `POST /mcp/:group` bypassed it. [1]

## Raise ruflo to the floor

```bash
npm view ruflo version
npm install ruflo@3.16.3
```

Confirm you are on 3.16.3 or newer before you bring the stack back up. The advisory's patched versions field is 3.16.3. [1]

## Apply the ADR-166 default locks

The advisory lists the fix work under ADR-166 Phase 1-3 (branch `security/adr-166-mcp-bridge-rce`, PR #2521):

- Bind loopback by default; fail-closed on public-bind opt-in without `MCP_AUTH_TOKEN`
- Bearer auth middleware (timing-safe compare)
- Server-side executeTool gate for `terminal_execute` (`MCP_ENABLE_TERMINAL=true` opt-in)
- MongoDB `--auth` on by default; `MONGO_INITDB_ROOT_PASSWORD` required to boot
- read_only container plus tmpfs
- CORS allowlist wiring
- CI regression locks

Do not re-open `0.0.0.0` without a bearer token. Keep terminal tools opt-in. [1]

## Contain an already-exposed instance

Operators of any exposed instance must, per the advisory:

1. Firewall `:3001` and `:27017` immediately
2. Rotate OPENAI / GOOGLE / OPENROUTER / ANTHROPIC keys
3. Audit the AgentDB pattern store for injected `agentdb_pattern-store` entries and purge poisoned patterns
4. Audit MongoDB for tampering

A patched redeploy alone does not undo poisoning. [1]

Send this to anyone who ran `docker compose up` on an AI coding tool stack and assumed the MCP port stayed private.

## Sources

1. [GitHub advisory GHSA-c4hm-4h84-2cf3 (Unauthenticated RCE in ruflo MCP bridge)](https://github.com/ruvnet/ruflo/security/advisories/GHSA-c4hm-4h84-2cf3)
2. [ruflo repository](https://github.com/ruvnet/ruflo)
