AegiLabs security audit agent — runs locally, metered via your AegiLabs key.
Project description
aegi — AegiLabs audit CLI
Runs the AegiLabs security-audit agent on your machine. Your code and targets stay local; only the agent's model calls are routed through the AegiLabs metering proxy using your issued key. Point it at a repo or a URL:
aegi ./path/to/repo # static audit of a code repository
aegi http://localhost:3000 # authorized assessment of a live target
Install
pipx install aegi
Prerequisite: the Claude Code CLI (claude) must be installed — the agent
drives it under the hood. aegi fails fast with a clear message if it's missing.
Configure
You need the Aegi key we issued you. Easiest: just run aegi and paste the
key when prompted — it's stored in ~/.aegi/config.toml and reused after that.
Or set it yourself:
export AEGI_KEY=aegi_live_... # env var
# or ~/.aegi/config.toml:
# key = "aegi_live_..."
# or per-run: aegi --key aegi_live_... ./repo
The proxy URL defaults to AegiLabs' — you don't set it. Precedence for both:
flag → env → ~/.aegi/config.toml.
What each mode does
| Target | Mode | Tools | Notes |
|---|---|---|---|
| a directory | repo | Read/Grep/Glob/Bash (read-only) | secrets, creds, vulnerable deps, injection/authz sinks |
| a URL | url | Bash | active assessment — prompts for authorization first (skip with --yes) |
Detection is automatic: an existing directory → repo; anything starting http(s)://
(or a bare host:port / localhost:port) → url.
Output
Streams progress to the terminal, then writes (stem taken from --out, default aegi-report):
aegi-report.pdf— the branded, client-ready report, compiled from the vendored AegiLabs Typst template (report_assets/). Requirestypston PATH (runaegi doctorfor the install command). Without it, an HTML fallback (aegi-report.html) is written instead.aegi-report.data.json— the structured findings (report-data.jsonschema); the only file you'd edit to tweak wording before sending.aegi-report.transcript.md— the raw agent transcript (audit trail).
Finally prints tokens used against your quota. Reports are Swedish by default (--lang en for English).
Options
aegi <target> [--max-turns N] [--lang sv|en] [--out PATH] [--title T] [--key KEY] [--yes]
| Option | Default | What it does |
|---|---|---|
<target> (required) |
— | What to audit: a directory → static repo audit, or a URL (http(s)://…, or bare host:port) → live assessment. Detected automatically. |
--max-turns N |
30 |
Cap on the agent's reasoning/tool turns. Higher digs deeper but costs more tokens and time; if the cap is hit, the run stops and the report notes it was truncated. Raise it (e.g. 60) for large repos or thorough URL tests. |
--lang sv|en |
sv |
Language the report prose is written in — Swedish or English. |
--out PATH |
aegi-report.pdf |
Where to write the PDF. Its filename stem also names the siblings: <stem>.data.json and <stem>.transcript.md. |
--title T |
per-language default | Title printed on the report cover. |
--key KEY |
prompt / env / config | Use this Aegi key for the run, overriding AEGI_KEY and ~/.aegi/config.toml. Normally unnecessary — the first run prompts for your key and saves it. Handy for one-off runs or scripting. |
--yes |
off | Skip the "are you authorized to test this URL?" confirmation (repo audits never prompt). Only for unattended/scripted runs where you've already confirmed authorization. |
Run aegi doctor to check prerequisites and your key.
Prerequisites
Run aegi doctor any time to check these and get the exact install command for
your OS (it flags what's required vs optional and whether your key is set).
- Claude Code CLI (
claude) — the agent drives it. - Typst (
typst) — compiles the PDF. Optional; HTML fallback otherwise. - Scanners (optional, repo mode) —
gitleaks,osv-scanner,semgrep,trufflehog. Any that are on PATH are run and used to ground findings; install the ones you want. - Python 3.11+.
Notes / limits (v0)
- URL scope is prompt-enforced, not sandboxed — the agent is told to touch only the target host. Treat as a soft guard; only run against targets you're authorized to test. Hard scope enforcement is planned.
- Repo mode runs any installed deterministic scanners (gitleaks, osv-scanner, semgrep, trufflehog) and feeds their real output to the agent as ground truth, then the agent triages and writes the report. With none installed it falls back to a read-only LLM review (CVE claims are then memory-based — install scanners to ground them). Scanners are optional: install the ones you want and they're used automatically.
- Needs Python 3.11+ (uses stdlib
tomllib).
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file aegi-0.1.6.tar.gz.
File metadata
- Download URL: aegi-0.1.6.tar.gz
- Upload date:
- Size: 138.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3389e3087702a7c482118be05b2f1943dd5d9a3176c18dd8cf2301f95bb24c7e
|
|
| MD5 |
ac810a8e9d66bb570db6a82dc059290e
|
|
| BLAKE2b-256 |
3248c13b1d38d55cf7c583a2037ac34f9557336a12ea851986794d01e13a9c90
|
File details
Details for the file aegi-0.1.6-py3-none-any.whl.
File metadata
- Download URL: aegi-0.1.6-py3-none-any.whl
- Upload date:
- Size: 144.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
763d837d5e22fa0aa243673ad1431977bb76db6abef9ee9eeab08c64ea58b459
|
|
| MD5 |
09e0dd50bdbf81dc7ab9cd79f5b8adda
|
|
| BLAKE2b-256 |
a816f93feca92e9997f2e3f0214299218196d90c2a2fc3e52ed0c1b381d265c9
|