srlabs/ziggy

GitHub: srlabs/ziggy

一个面向 Rust 项目的多 fuzzer 并行管理工具,通过统一调度 AFL++、honggfuzz 等引擎并共享语料库来提升漏洞发现效率。

Stars: 81 | Forks: 11

# `ziggy` [![构建状态](https://static.pigsec.cn/wp-content/uploads/repos/2026/05/f3ae5dd93a160909.svg)](https://github.com/srlabs/ziggy/actions/workflows/ci.yml) [![Crates.io](https://img.shields.io/crates/v/ziggy.svg)](https://crates.io/crates/ziggy) [![Docs.rs](https://img.shields.io/docsrs/ziggy)](https://docs.rs/ziggy) `ziggy` 是一个为 Rust 项目设计的 fuzzer 管理器,其构建目的是: - 使用共享 corpus 并行启动不同的 fuzzer - 创建和监控持续 fuzzing 的 pipeline ## 功能特性 - 🤹 并行处理不同的 fuzzing 进程([honggfuzz](https://github.com/google/honggfuzz)、[AFL++](https://github.com/aflplusplus/aflplusplus)) - 🗃️ 所有 fuzzer 共享一个 corpus - 🤏 轻松的 corpus 最小化 - 📊 深入的监控 - 🎯 轻松生成覆盖率报告 - 😶‍🌫️ 支持 Arbitrary trait 未来将包含的功能: - 🐇 集成 [LibAFL](https://github.com/aflplusplus/libafl) - 📨 通过 bash hook 通知新的 crash ## 使用示例 首先,运行以下命令安装 `ziggy` 及其依赖项: ``` cargo install --force ziggy cargo-afl honggfuzz ``` 以下是该工具的帮助输出: ``` $ cargo ziggy A multi-fuzzer management utility for all of your Rust fuzzing needs 🧑‍🎤 Usage: cargo ziggy Commands: build Build the fuzzer and the runner binaries fuzz Fuzz targets using different fuzzers in parallel run Run a specific input or a directory of inputs to analyze backtrace minimize Minimize the input corpus using the given fuzzing target cover Generate code coverage information using the existing corpus plot Plot AFL++ data using afl-plot add-seeds Add seeds to the running AFL++ fuzzers triage Triage crashes found with CASR - currently only works for AFL++ stability Analyze harness stability by detecting non-deterministic code paths clean Remove generated artifacts from the target directory help Print this message or the help of the given subcommand(s) Options: -h, --help Print help -V, --version Print version ``` 要创建一个 fuzzer,只需将 `ziggy` 添加为依赖项即可。 ``` [dependencies] ziggy = { version = "1.7.0", default-features = false } ``` 然后,在你的 `main` 中使用 `fuzz!` 宏来创建一个 harness。 ``` fn main() { ziggy::fuzz!(|data: &[u8]| { println!("{data:?}"); }); } ``` 有关文档完善的 fuzzer 示例,请参阅 [url 示例](./examples/url/)。 ## `output` 目录 在你启动 fuzzer 之后,你会在 `output/` 目录中看到以下几项内容: - `corpus` 目录,包含完整的 corpus - `crashes` 目录,包含 fuzzer 检测到的所有 crash - `timeouts` 目录,包含 fuzzer 检测到的所有超时/挂起 - `logs` 目录,包含 fuzzer 的日志文件 - `afl` 目录,包含 AFL++ 的输出 - `honggfuzz` 目录,包含 Honggfuzz 的输出 - `queue` 目录,由 ziggy 用于将项从 AFL++ 传递给 Honggfuzz ## 覆盖率 根据你现有的共享 corpus 生成 HTML 覆盖率报告: ``` cargo ziggy cover ``` 报告入口将位于 ziggy 的 `output` 目录下的 `.//coverage/index.html`。 可以使用 `-o ` 选项将其更改为 `/index.html`。 你可以选择不同的输出格式,或指定自定义的输入 corpus: ``` cargo ziggy cover \ -i path/to/corpus \ # custom input corpus directory -t html \ # navigable source-level report (default) -t text \ # same folder structure as html, but plain-text summaries -t json \ # machine-readable per-file data -t lcov # standard tracefile for CI tools like Codecov ``` ## 战利品展示 [CVE-2026-24116](https://www.cve.org/CVERecord?id=CVE-2026-24116) 是通过使用 wasmi 进行差分 fuzzing 在 wasmtime 中发现的
标签:AFL++, CASR, DevSecOps, Fuzzing, honggfuzz, LibAFL, Rust, Rust安全, 上游代理, 代码安全, 可视化界面, 多fuzzer管理, 安全测试, 攻击性安全, 模糊测试引擎, 测试工具, 漏洞枚举, 网络流量审计, 覆盖率, 语料库管理, 通知系统