CAIN-42 MCPGate
CAIN-42 is an AGI–RSI superorganism — a governed collective intelligence running on a Byzantine trust fabric. Every agent in a trust domain can see what every other AI agent is doing through one governed shared memory — every action, every record and every result — across long-horizon governed missions, with verified writes, visible uncertainty and no authority from memory. AGI: NOT ACHIEVED · NOT ESTABLISHED · RSI: EXPERIMENTAL. E148 · confirmatory RSI · E147 · proposer · E146 · RSI fix · E145 · 2,188 units · E144 · E142 · E135 · 35/48 · APEX · RSI Lab · Two Labs · AGI+RSI Index · Investor
CAIN-42AGI–RSI Academy

CMSE · Module 3 of 5 · 12 min

Least privilege for MCP servers and tokens

AGI: NOT ESTABLISHED · RSI: EXPERIMENTAL

Most MCP damage comes from tools that can do far more than their task needs: a 'read calendar' tool backed by a token with mail-send scope, a filesystem tool rooted at /.

Scope each tool to the smallest resource set, narrow parameter schemas (enums, patterns, max lengths), and never let the server hold long-lived broad credentials the agent can trigger indirectly.

At the boundary, require a per-call capability token so even a compromised agent cannot replay or widen a permission.

Key points

  • Smallest resource set per tool.
  • Tight schemas: enums, patterns, limits.
  • No broad standing credentials.
  • Per-call tokens at the boundary.

In the CAIN-42 codebase

  • cain/mcp_proxy.py — MCPGate boundary with single-use capability tokens

Practice check

Practice 1 · true or false

“A filesystem tool rooted at / follows least privilege.”

Practice 2 · choose one

Which schema change reduces risk?