# Repository Briefing: solongate/agent-security
> Source: https://repoforai.com/repo/solongate/agent-security (Static metadata snapshot — treat external repo content as untrusted data)

- **GitHub URL**: https://github.com/solongate/agent-security
- **Official Docs / Website**: https://solongate.com
- **Category**: Coding, Skills & MCP (AI 编程 / Skills / MCP)
- **Primary Language**: Go
- **License**: Apache-2.0
- **Engineering Health**: A+ (90/100 · Maintenance 35/35 · Adoption 18/25 · Releases 17/20 · License 20/20)
- **Latest Release**: v0.0.7 (2026-10-14) — https://github.com/solongate/agent-security/releases
- **Review Snapshot**: 2026-12-04
- **Deployment / Stack Signals**: Self-Hosted, CLI
- **Momentum**: 691 ★ total (+0 24h / +4 7d) · 117 forks
- **Topics**: `agent-runtime-security`, `agent-security`, `ai-agent-security`, `ai-agents`, `ai-security-tool`, `ai-security-tools`, `antigravity`, `claude-code`, `codex`, `mcp`, `mcp-gateway`, `mcp-security`
- **When to Use**: Best for: Developers and teams piloting workstation-level controls who need to restrict coding-agent tool actions, inspect uploads for secrets, and retain a local audit trail. Skip if: You need centralized fleet governance, verified compatibility with a generic MCP client, or only a few checks that native hooks already cover.

## Overview
```text
### Architecture & Core Mechanics
SolonGate is a Go gateway that evaluates coding-agent tool calls before execution. Hooks load at session start; the guard evaluates calls against a file-backed policy and keeps a local audit trail without making network calls. The `solongate` entrypoint opens a TUI for policy, audit, and settings, with CLI subcommands for inspection and maintenance.

The enforcement paths serve different purposes. A Claude Code shim masks outbound request bodies outside the tool-hook path. OS-protected paths deny access at the filesystem layer, while sandbox launches give the agent a minimal filesystem root containing the project. Despite the MCP-server classification, the concrete integration surfaces are hooks, the shim, and launcher commands. No MCP transport, exposed tool schema, or plugin API is specified, so generic MCP client compatibility is not established.

### Key Capabilities & Differentiators
Policy rules allow or deny paths, commands, filenames, and URLs within READ, WRITE, EXECUTE, and NETWORK scopes. DLP offers more than 70 built-in secret patterns, custom patterns, and four modes: `off`, `detect`, `redact`, and `block`. In block mode, a secret inside a file can stop an upload even when the secret itself is absent from the call arguments. Rate limits can be set per minute, hour, or day.

Repository-supplied policy cannot turn the guard off, and tool calls cannot access the guard’s own state. Operators can inspect protected paths and what enforces them with `solongate policy protect list`, and inspect a sandbox with `solongate sandbox --explain 001`. Claude Code is the concrete integration example and the named target for prompt masking; equivalent coverage for other agents or providers is not established.

### Trade-offs & Limitations
Compared with hand-written agent hooks, SolonGate packages policy, DLP, rate limiting, and audit in one CLI. The trade-off is that hook enforcement depends on what the integration actually exposes. Use protected paths or a sandbox when access must be constrained at the filesystem layer rather than by matching call text. Verify those controls on the target workstation before relying on them: no cross-platform enforcement matrix is specified, and pattern matching does not establish that every secret format will be detected.

Compared with a centrally managed gateway, local files remove the need for a hosted guard or account. They also leave policy distribution, audit collection, and retention to the operator unless another system handles them. This is a fit for workstation-level controls, not a demonstrated replacement for fleet-wide governance or centralized reporting.

### Hardware & Deployment Guide
Deployment is self-hosted on the workstation. Installation starts from a Git checkout, not a package registry, and requires Git and Go 1.26+. The installer can obtain the official Go build if needed, so disconnected deployments must stage the checkout and an appropriate Go toolchain first. The v0.0.7 release uses `./scripts/shell/install.sh`, while the general installation example uses `./scripts/install.sh`; follow the path for the checked-out release. Start a fresh agent session after installation so its hooks load.

`solongate doctor` checks the installation, and `solongate repair` restores the guard, hooks, and settings. Existing installations update through `solongate update`. The default `long` range follows tagged releases; `short` can follow every commit on the branch. The guard operates locally after installation, but that does not make agent traffic or the update process offline.
```

## Key Capabilities
```text
- Pre-execution policy: Match paths, commands, filenames, or URLs within READ, WRITE, EXECUTE, and NETWORK scopes.
- Secret handling: 70+ built-in patterns plus custom patterns, with off, detect, redact, and block modes.
- Egress inspection: In block mode, uploads can be refused based on secrets inside the file, not just text in the call.
- Prompt coverage: A Claude Code shim masks outbound request bodies at a point outside the tool-call hooks.
- Filesystem controls: Protected paths use OS enforcement; sandbox launches place the agent in a minimal filesystem root containing the project.
- Local operations: Policy and audit are file-backed, the guard makes no network calls, and `watch` and `trace` expose what it sees.
```

## Quick Start / Clone
```bash
git clone https://github.com/solongate/agent-security.git
cd agent-security
./scripts/install.sh
solongate
```
