fuse CLAUDE.md

Project instructions for Fuse, a local firewall that checks shell commands and MCP tool calls before they run. It assigns each command a risk level, from safe to blocked.

In plain words
What is it for?
It is for understanding Fuse's Go project structure, supported platforms, command-classification rules, and development workflow.
Why use it?
It helps prevent an AI agent from running risky commands without the right level of review or approval.

Instructions file

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/php-workx/fuse/claude-md
Clone the repo
git clone --depth 1 https://github.com/php-workx/fuse
Per session 1,647 This file is loaded in full into every session.
When invoked 1,647 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.01647 $0.01647
Opus 5 $0.00823 $0.00823
Sonnet 5 $0.00329 $0.00329
Haiku 4.5 $0.00165 $0.00165

Measured yesterday against content hash bf824e3f3619, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

fuse CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 136 lines

How it starts

The opening of the file, as written. The whole thing — 136 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CLAUDE.md — Fuse

What is Fuse?

Fuse is a local firewall for AI agent commands. It classifies shell commands and MCP tool calls into four decision levels — SAFE, CAUTION, APPROVAL, BLOCKED — and gates execution accordingly. In proxy and run modes, fuse controls execution directly. In hook mode, fuse advises the agent. Everything runs locally with no cloud dependencies.

Tech Stack

  • Language: Go 1.25
  • Build: just (not Make) — see justfile for all targets
  • Platforms: macOS (darwin/arm64, amd64), Linux (linux/amd64, arm64), Windows (windows/amd64, arm64). Windows is fully supported: PowerShell and CMD shell strategy, Console API approval prompts (CONIN$/CONOUT$), Job Object process management, and Windows-native security rules (PowerShell/CMD attack patterns, LOLBins, registry, persistence) are all merged. PowerShell/Batch script inspection is line-oriented (here-strings, splatting, ^ line-continuations are not reconstructed before matching). See specs/done/windows-support-plan.md.
  • Dependencies: Minimal. Pure-Go SQLite (modernc.org/sqlite), shell parser (mvdan.cc/sh), Cobra CLI, YAML. No RPC/cloud SDKs.

Project Layout

cmd/fuse/              Entry point (thin main.go)
internal/
  cli/                 Cobra commands: install, doctor, run, proxy, hook, events, dryrun, enable/disable
  core/                Classification pipeline, normalization, safe-command detection, sanitization
  policy/              Built-in preset rules (git, aws, gcp, k8s, security) + user YAML policy evaluation
  adapters/            Runtime adapters:
    hook.go              Claude Code PreToolUse hook (classify-only)
    native_file_policy.go  Claude native file tool (Read/Write/Edit/MultiEdit) path protection
    codexshell.go        Codex shell MCP server (concurrent JSON-RPC)
    mcpproxy.go          Generic MCP proxy with tool interception
    runner.go            Shell execution wrapper (run mode)
  approve/             Approval lifecycle: HMAC-signed records, TUI prompt via /dev/tty
  config/              YAML config loading, XDG paths
  db/                  SQLite state storage (WAL mode, schema migrations v1-v4, event log)
  inspect/             File inspection for scripts (shell, python, javascript)
  events/              Event types and formatting
  releasecheck/        Shell compatibility release checks (bash/zsh/fish)
testdata/fixtures/     Test fixtures including commands.yaml
specs/                 Technical and functional specifications

Read the full file on GitHub · 136 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 136 lines · 1,647 tokens per session scan A bf824e3f3619

Subscribe to this mod's changes

fuse CLAUDE.md is an instructions file published in the GitHub repository php-workx/fuse (2 stars, last pushed 2d ago), licensed MIT. It adds 1,647 tokens to every session, about $0.0082 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.