Skip to main content
Glama
README.md
# sauron

[![CI](https://github.com/yousifnazhat/sauron/actions/workflows/ci.yml/badge.svg)](https://github.com/yousifnazhat/sauron/actions/workflows/ci.yml)
[![Python 3.11+](https://img.shields.io/badge/python-3.11%2B-blue)](https://pypi.org)
[![PyPI](https://img.shields.io/pypi/v/sauron-vault)](https://pypi.org/project/sauron-vault/)
[![License: Apache-2.0](https://img.shields.io/badge/license-Apache--2.0-green)](LICENSE)
[![Tests: 31](https://img.shields.io/badge/tests-31_passing-brightgreen)](tests/)

**Your tradecraft should compound. Your agents should stay disciplined.**

Keep your executor — ARTEX, Cairn, Strix, HexStrike, anything. Sauron is the memory and the discipline layer they don't have: a compounding technique vault, an in-code authorization gate, evidence-enforced findings, a research-ingestion pipeline, and a honeypot detector for your agents.

## Why

Every agentic pentest framework dies with the project it ran. Your executor's findings live in a database; your technique knowledge lives nowhere. The two field-documented gaps in the entire agentic-pentest space are (a) no cross-engagement compounding memory and (b) no in-code authorization enforcement — the 2026 field survey calls in-code scope checking "largely open ground," and Elastic Security Labs' source review of five frameworks found *"none of the five frameworks enforces authorization in code by default."* sauron ships exactly those two layers, executor-agnostic, over MCP.

## Quickstart

```bash
pipx install sauron
sauron init ~/vault --demo        # scaffold + two live-fetched seed entries
cd ~/vault
claude mcp add sauron -- sauron mcp serve
```

Then in Claude Code (or Codex, or any MCP client):

```text
> record the authorization gate: target lab.example, scope *.example,
  basis "owned lab", type coordinated-disclosure
> gate status                          # complete: true
> ingest paper 2611.16744              # arXiv source-fetch, never prose
> triage P-002 --decision promote --method-name "Visual Prompt Injection"
> log finding ... --evidence recon/nmap.out
> close                                # dedup, backlinks, redaction lint
```

## Setups

Sauron makes **zero LLM calls** (your agent client owns the model — any provider) and bundles **no executors** (bring whatever you run, or start with nothing):

- **Laptop only** — works day one: vault, gate, discipline, passive OSINT.
- **Kali attack box — recommended** — all target-facing traffic from a dedicated box, tools co-located. See `SETUP.md`.
- **Kali + executor add-ons** — Decepticon, Strix, HexStrike, ARTEX pointers; sauron wraps them. See `SETUP.md`.

## The fleet loop (v0.2)

```
gate record (4 fields) → start-engagement --surface <s>
  → engagement_plan: corpus-driven items, stage × state filtered
  → run-dispatch: items go to the executor fleet (direct/decepticon/artexsafe)
  → coverage gate REFUSES close while items are untested (return-to-untested)
  → close: dedup + cross-executor delta report + redaction lint
```

The lethality delta: ARTEX and Cairn replan from state × model-baseline knowledge; sauron replans from state × **your compounded corpus**. Executors never receive open-ended goals — each gets one bounded, method-note-derived item.

## What it enforces

- **Authorization gate** — 4 fields (target, scope, basis, engagement type), blocked-until-complete, archived audit trail. Findings refuse to log without it.
- **Evidence-per-finding** — `log_finding` rejects findings without an on-disk evidence artifact. No evidence, no finding.
- **Status verbs** — Reported / Vendor-confirmed / Public. "Patched" without written vendor sign-off is rejected by the lint.
- **Redaction lint** — close aborts while live secrets (Stripe keys, AWS keys, JWTs, private keys) remain in findings.
- **Deception check** — a pre-action honeypot detector: canary-registry match, imperative instructions, unprotected locations, sink-directed credentials, chain-isolated discoveries. A honeypot is prompt injection authored by the blue team; your agents should call `deception_check` before using any discovered credential or path.

## Tools

CLI: `init`, `ingest paper|advisory`, `gate record|status|clear`, `triage`, `log-finding`, `close`, `deception check`, `mcp serve`. MCP: the same 9 operations as tools for any agent client.

## License

Apache-2.0.