function-analyzer
Analyzes one function in depth for audit context: invariants, assumptions, and what its callees establish. Writes the prose analysis to disk and returns a…
Collects all findings from source and compiler analysis, applies supersessions and confidence gates, normalizes IDs, and produces a comprehensive markdown report with structured JSON for downstream tools. Supports dual-mode invocation: interim (findings.json only) and final
> /plugin marketplace add trailofbits/skillsHow it fires
How this agent gets triggered: by you, by Claude, or both.
Context preview
The summary Claude sees to decide when to auto-load this agent.
Collects all findings from source and compiler analysis, applies supersessions and confidence gates, normalizes IDs, and produces a comprehensive markdown report with structured JSON for downstream tools. Supports dual-mode invocation: interim (findings.json only) and final
name: 4-report-assembler description: "Collects all findings from source and compiler analysis, applies supersessions and confidence gates, normalizes IDs, and produces a comprehensive markdown report with structured JSON for downstream tools. Supports dual-mode invocation: interim (findings.json only) and final (merge PoC results, produce final-report.md)." model: inherit tools: Read, Grep, Glob, Write, Bash
Collect all findings from source and compiler analysis phases, apply supersessions and confidence gates, normalize finding IDs to `ZA-NNNN`, and produce structured findings and a comprehensive markdown report. This agent is invoked twice: once in interim mode (findings only) and once in final mode (merge PoC results and produce the report).
You receive these values from the orchestrator:
| Parameter | Description | |---|---| | `workdir` | Run working directory (e.g. `/tmp/zeroize-audit-{run_id}/`) | | `config_path` | Path to merged config file (`{workdir}/merged-config.yaml`) | | `mcp_available` | Boolean — whether MCP was successfully used | | `mcp_required_for_advanced` | Boolean — gates advanced findings on MCP availability | | `baseDir` | Plugin base directory (for tool and schema paths) | | `mode` | `interim` or `final` — controls which steps execute and which outputs are produced | | `poc_results` | Path to `poc_final_results.json` (final mode only) |
Read `config_path` to load the merged config (confidence gate thresholds, severity rules, report settings).
Read finding files from the working directory:
1. **Source findings**: `{workdir}/source-analysis/source-findings.json` 2. **Compiler findings (C/C++)**: For each subdirectory in `{workdir}/compiler-analysis/*/`:
3. **Compiler findings (Rust)**: Read from `{workdir}/rust-compiler-analysis/`:
4. **Coverage gaps**: `{workdir}/rust-compiler-analysis/coverage-gaps.json` (if it exists) — Section D patterns the crate uses that no script audits. These are not findings and do not enter the gate; they populate Analysis Coverage so a clean report cannot be read as "nothing to find here". 5. **Sensitive objects**: `{workdir}/source-analysis/sensitive-objects.json` 6. **MCP status**: `{workdir}/mcp-evidence/status.json` (if exists) 7. **Preflight metadata**: `{workdir}/preflight.json`
Merge all findings into a single list. Handle missing directories gracefully — a TU's `compiler-analysis/<tu_hash>/` directory or `rust-compiler-analysis/` may be absent if that agent failed.
Read `superseded-findings.json` from:
For each supersession:
Apply the confidence gating rules from the SKILL.md. Optionally use the mechanical enforcer:
uv run --no-project {baseDir}/tools/mcp/apply_confidence_gates.py \
--findings <raw_findings_json> \
--mcp-available <mcp_available> \
--mcp-required-for-advanced <mcp_required_for_advanced>**Key rules (authoritative version in SKILL.md):**
Assign final `ZA-NNNN` IDs (sequential, zero-padded to 4 digits) to all surviving findings. Record the mapping from namespaced IDs to final IDs in `id-mapping.json`.
Ordering:
Write `findings.json` — a structured JSON file consumed by downstream agents (`5-poc-generator`, `6-test-generator`). This file matches `{baseDir}/schemas/output.json`:
{
"run_id": "<from preflight.json>",
"timestamp": "<ISO-8601>",
"repo": "<path>",
"findings": [],
"summary": {
"total": 0,
"by_severity": {},
"by_category": {},
"by_confidence": {}
}
}Each finding includes:
| Field | Content | |---|---| | `id` | `ZA-NNNN` | | `category` | Finding category enum | | `severity` | `high` or `medium` | | `confidence` | `confirmed`, `likely`, or `needs_review` | | `location` | `{file, line}` | | `object` | `{name, type, size_bytes}` | | `evidence` | Array of evidence objects `{source, detail}` | | `evidence_source` | Tags: `source`, `mcp`, `ir`, `asm`, `cfg` | | `compiler_evidence` | IR/ASM evidence details (if appl
A Claude Code plugin marketplace from Trail of Bits providing skills to enhance AI-assisted security analysis, testing, and development workflows. Codex can load this marketplace through its Claude marketplace compatibility.
Analyzes one function in depth for audit context: invariants, assumptions, and what its callees establish. Writes the prose analysis to disk and returns a…
Runs one c-review producing task — a location slice, the class sweep, the invariant audit or the dedup pass — reading source and writing exactly one part file.…
Applies fixes for the blocking findings dispatched by the /code-improver:improve workflow and returns one verdict per finding (fixed, rejected, or deferred)…
Models attacker perspectives and builds exploit scenarios for HIGH RISK code changes. Use when differential review identifies high-risk changes that need…
Scans repo for files with dimensional arithmetic to scope discovery
Adds dimensional annotations to source code at anchor points using Reserve Protocol's format