Iron Cannon

Iron Cannon

An MCP-powered compliance copilot for SaaS stacks, enabling structured audit workflows including stack detection, module wiremapping, implementation directives, code verification, and security/infrastructure/legal readiness gates.

Category
访问服务器

README

Iron Cannon

An MCP-powered compliance copilot for SaaS stacks — especially Next.js / Cloudflare Workers + D1 + Stripe + Resend.

Iron Cannon gives AI agents (and humans) a structured audit workflow: detect the stack, generate a module wiremap, ship implementation directives, verify code patterns, and gate production / infrastructure / legal readiness. It runs locally as a Cloudflare Worker dev server and exposes tools over the Model Context Protocol (HTTP JSON-RPC).

Portfolio note: This project was dogfooded on real Cloudflare + Stripe apps but is paused before production SaaS launch. It is a strong demonstration of MCP tool design, rules engines, and agent guardrails — not a hosted compliance certification product.


What it does

Tier Tools Purpose
Pro T01–T08 Stack discovery, wiremap, module directives, snippet verification, drift & recovery
Armor T09–T11 Security surfaces, infra checklists (cache, rate limits, stress testing)
IronClad T12–T14 Legal obligation map + spot-check verification

Design philosophy: Iron Cannon is two modes in one product:

  • Copilot — rich checklists and sequencing (high trust)
  • Judge — pass/fail gates only after deliberate code snippets and verified modules (medium trust)

Architecture

┌─────────────────┐     HTTP /mcp      ┌──────────────────────┐
│  Cursor / CLI   │ ◄──────────────► │  apps/mcp-worker     │
│  (MCP client)   │   JSON-RPC 2.0   │  (Cloudflare Worker) │
└─────────────────┘                  └──────────┬───────────┘
                                                │
                                     ┌──────────▼───────────┐
                                     │  @ironcannon/mcp-core │
                                     │  T01–T14 tool runtime │
                                     └──────────┬───────────┘
                                                │
              ┌─────────────────────────────────┼─────────────────────────┐
              │                                 │                         │
     @ironcannon/compose              @ironcannon/compare          @ironcannon/verify
     (tier redaction)                 (pattern matching)           (stack completeness)

Rules engine data lives under docs/engine/ as JSON specimens (fixtures, obligations, catalogs). npm run build:worker-bundle packs them into packages/mcp-core/src/generated/ for the Worker.


Quick start (local MCP)

Prerequisites

  • Node.js 20+
  • npm

1. Install & build

git clone https://github.com/DillonRich/Iron_Cannon.git
cd Iron_Cannon
npm install
npm run build:worker-bundle

2. Verify the engine

npm run g2:audit          # package + smoke tests (HTTP optional)
npm run portfolio:preflight   # scan for accidental live secrets

3. Start the MCP server

npm run ironcannon:serve

Server listens at http://127.0.0.1:8787 (/health, /mcp, /tools).

4. Connect Cursor (or any MCP client)

Copy mcp-config.example.json into your Cursor MCP settings and adjust paths per Cursor docs. Use one server URL with different x-ironcannon-tier headers (pro, armor, ironclad).

Toggle the MCP server off/on after starting ironcannon:serve.


CLI workflows

# Audit an external project (T01–T03 local, prints wiremapAttestation)
npm run ironcannon -- audit "C:/path/to/your-app"

# Golden path smoke (reference app)
npm run ironcannon -- ref-stack
npm run ironcannon -- ref-golden

# Full tiered harness (Pro → Armor → IronClad)
npm run ironcannon -- full

# Dogfood bundle: audit + fixture regression + MCP envelope test
npm run ironcannon:dogfood -- "C:/path/to/your-app"

# Single module verify
npm run ironcannon -- verify M12-stripe-webhook ./path/to/snippet.ts

Set tier: IRON_CANNON_TIER=armor npm run ironcannon -- ...


Agent workflow (summary)

  1. T01 analyze_project_stack — detect frontend, compute, DB, Stripe/Resend
  2. T02 validate_stack_completeness — missing secrets / config hints
  3. T03 generate_system_wiremap — module chain + wiremapAttestation token
  4. T04 get_module_directives — per-module implementation guidance (+ snippetHint for verify-heavy modules)
  5. T05 verify_module_compliance — must pass real code snippets (notAudited if empty)
  6. Armor: T09–T11 security + infrastructure gates
  7. IronClad: T12–T14 legal obligation map (T13 optional snippet verify)

Pass wiremapAttestation from T03 on all T04/T05/T11 calls.


Project layout

Path Description
packages/mcp-core/ Core MCP tool runtime (T01–T14)
packages/compose/ Tier-based response redaction
packages/compare/ Pattern / obligation compare engine
packages/verify/ Stack completeness checks
apps/mcp-worker/ Cloudflare Worker HTTP surface
scripts/ CLI (ironcannon.mjs), build, test harnesses
docs/engine/ Rules JSON, fixtures, obligation index (not markdown)
examples/golden-reference-app/ Minimal reference stack for T01–T05

Testing

npm run g2:audit                 # recommended smoke gate
npm run planning:guardian-retest # pattern equivalence fixtures
npm run g2:golden-full           # full Pro + Armor + IronClad path
npm run planning:user-journey    # 121 behavioral scenarios (slower)

Known limitations (honest)

  • Stack coverage is strongest for Cloudflare Workers/Pages + Stripe + Resend — not universal.
  • T05 / T11 judge mode requires deliberate snippets and verifiedModules — not unattended certification.
  • Hosted deploy (Cloudflare production, D1 platform DB, Vectorize) is scaffolded but not required for local MCP.
  • Legal (IronClad) outputs checklists and heuristics — not legal advice.

Security

See SECURITY.md. Dev-only API keys in docs/engine/phase1/fixtures/api-keys.dev.json are fake local tokens (ic_dev_*). Do not commit real .env files.


License

GNU AGPL v3 — see LICENSE. You may run this locally for audits and contribute improvements; if you offer this software as a network service, AGPL copyleft applies.


Author

Built as a portfolio project demonstrating MCP server design, structured agent guardrails, and compliance-oriented tooling for modern SaaS infrastructure.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选