agentic-actions-audito…
Audits GitHub Actions workflows for security vulnerabilities in AI agent integrations including Claude Code Action, Gemini CLI, OpenAI Codex, and GitHub AI…
Mutation-driven test vector generation. Finds implementations of a cryptographic algorithm or protocol, runs mutation testing to identify escaped mutants, then generates new test vectors that deliberately exercise the uncovered code paths. Compares before/after mutation kill
$ npx -y skills add trailofbits/skills --skill vector-forge --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/vector-forgeContext preview
The summary Claude sees to decide when to auto-load this skill.
Mutation-driven test vector generation. Finds implementations of a cryptographic algorithm or protocol, runs mutation testing to identify escaped mutants, then generates new test vectors that deliberately exercise the uncovered code paths. Compares before/after mutation kill
name: vector-forge description: "Mutation-driven test vector generation. Finds implementations of a cryptographic algorithm or protocol, runs mutation testing to identify escaped mutants, then generates new test vectors that deliberately exercise the uncovered code paths. Compares before/after mutation kill rates to prove vector effectiveness. Use when generating cryptographic test vectors, measuring Wycheproof coverage gaps, finding escaped mutants via mutation testing, creating cross-implementation test suites, or improving test vector coverage for crypto primitives."
Uses mutation testing to systematically identify gaps in test vector coverage, then generates new test vectors that close those gaps. Measures effectiveness by comparing mutation kill rates before and after.
uv tool install trailmark # Python snippets: uv run --with trailmark python - (a tool env is not importable)
language with mutation testing support
the implementation
---
| Rationalization | Why It's Wrong | Required Action | |-----------------|----------------|-----------------| | "We have enough test vectors" | Mutation testing proves otherwise | Run the baseline first | | "The implementation's own tests are sufficient" | Own tests often share blind spots with the impl | Cross-impl vectors catch different bugs | | "FFI crates can be mutation tested at the binding layer" | Mutations to wrappers don't affect the underlying impl | Mutate the actual implementation language | | "Timeouts mean the mutation was caught" | Timeouts are ambiguous — could be killed or alive | Resolve timeouts before drawing conclusions | | "All mutants are equivalent" | Most aren't — verify by reading the mutation | Classify each escaped mutant individually | | "Checking valid vectors is enough" | Permissive mutations survive without negative assertions | Assert rejection for every invalid vector | | "Manual analysis is fine" | Manual analysis misses what tooling catches | Install and run the tools |
---
Phase 1: Discovery → Find implementations to test
↓
Phase 2: Harness → Write/adapt test vector harness for each impl
↓
Phase 3: Baseline → Run mutation testing with existing vectors
↓
Phase 4: Escape Analysis → Classify escaped mutants by code path
↓
Phase 5: Vector Gen → Create test vectors targeting escapes
↓
Phase 6: Validation → Re-run mutation testing, compare before/after
↓
Output: Coverage Report + New Test Vectors---
Find implementations of the target algorithm. Look for:
1. **Pure implementations** in high-level languages (Go, Rust, Python) — these are the best mutation testing targets 2. **FFI wrapper crates** — identify these early so you don't waste time mutating wrapper glue code 3. **Reference implementations** — useful for cross-verification but may not be the best mutation targets
For each implementation, note:
| Type | Mutation Value | Example | |------|---------------|---------| | Pure implementation | High | zkcrypto/bls12_381 (Rust), gnark-crypto (Go) | | FFI bindings to C/asm | Low at binding layer | blst Rust crate | | C/C++ implementation | High (use Mull) | blst C library | | Generated code | Medium (mutations may be equivalent) | gnark-crypto generated field arithmetic |
**Key insight:** If an implementation delegates to another language via FFI, you must mutate the *underlying* implementation, not the bindings. For C/C++ underneath Rust/Go/Python, use Mull or similar.
---
For each implementation, create a test harness that:
1. Reads test vectors from JSON files (Wycheproof format recommended) 2. Exercises the implementation's API for each vector 3. Asserts **both acceptance and rejection**:
4. Adds **roundtrip assertions** for valid deserialization vectors: `serialize(deserialize(bytes)) == bytes` 5. Reports pass/fail per vector with test IDs
**Critical:** A harness that only checks valid vectors will miss all permissive mutations (e.g., `&` → `|` in validation). See [references/lessons-learned.md](references/lessons-learned.md) §7.
The harness must be runnable by the mutation testing framework. For most frameworks this means:
The harness must live *inside the implementation's package* so the mutation framework can see it. This usually means:
# Go: add test file to the package being mutated cp wycheproof_test.go /path/to/impl/pac
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.
Audits GitHub Actions workflows for security vulnerabilities in AI agent integrations including Claude Code Action, Gemini CLI, OpenAI Codex, and GitHub AI…
Understand a codebase before looking for bugs in it - what each function assumes, what it guarantees, and what it depends on elsewhere. Use when starting an…
Scans Algorand smart contracts for 11 common vulnerabilities including rekeying attacks, unchecked transaction fees, missing field validations, and access…
Prepares codebases for security review using Trail of Bits' checklist. Helps set review goals, runs static analysis tools, increases test coverage, removes…
Scans Cairo/StarkNet smart contracts for 6 critical vulnerabilities including felt252 arithmetic overflow, L1-L2 messaging issues, address conversion problems,…
Systematic code maturity assessment using Trail of Bits' 9-category framework. Analyzes codebase for arithmetic safety, auditing practices, access controls,…