# Lighthouse 代码覆盖率浏览插件

> 面向 IDA Pro 和 Binary Ninja 的代码覆盖率浏览插件，载入原生程序的执行轨迹，并在反汇编器的各个视图中为已执行代码着色，无需符号或源码。覆盖率总览按函数列出覆盖情况；组合命令行可用逻辑运算符组合已载入的覆盖率集合，用于比较多次运行的差异、筛选函数或跳转到指定地址；覆盖率交叉引用则显示批量载入的众多集合中哪些执行过某个基本块。它可读取 DynamoRIO drcov 日志、模块+偏移、绝对地址和 Tenet 轨迹，能生成简单的 HTML 覆盖率报告，并附带可输出 drcov 兼容日志的原型 Intel Pin 工具和 Frida 脚本。

- 类型：工具
- 目标：二进制
- 类别：调试与动态分析
- 关联：基础工具
- 来源复核于：2026-10-19
- 收录于：2026-10-29
- 原始资源：<https://github.com/gaasedelen/lighthouse>
- 一手来源：<https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/README.md>
- 目录页面：<https://awesomerea.org/zh/resources/lighthouse/>
- 记录 JSON：<https://awesomerea.org/resources/lighthouse/record.json>
- 英文版：[English](https://awesomerea.org/resources/lighthouse/index.md)

## 使用条件与局限

- 审阅时的版本为 v0.9.3，于 2024-02-05 发布，属于维护性版本，加入了完整的 drcov v3 支持和 Binary Ninja／PySide6 修复；所审阅的 master 分支提交即该标签。develop 分支领先九个提交，包含 2025–2026 年针对 IDA 9.x、9.2 和 9.3 的兼容性修复以及 0.9.4 开发版本号，均未发布。
- 需要 IDA Pro 7 或更高版本（IDA 接口层遇到 IDA 6 会停止加载），或 Binary Ninja；README 称通过插件管理器安装支持 v3.5 及以上版本，IDA 则需将 plugins 文件夹复制到用户插件目录。README 称它是跨 Windows、macOS 和 Linux 的 Python 2/3 插件，无第三方依赖。在 Binary Ninja 中只能为线性视图、图视图和 IL 视图着色，不支持反编译输出。
- 覆盖率需针对使用者自己的目标另行采集：覆盖率 README 介绍了 DynamoRIO drcov、仓库附带的 CodeCoverage pintool（原型；发布版附有针对 Pin 3.30 的 Windows 构建，macOS 和 Linux 用户需基于自行下载的 Intel Pin 编译），以及实验性的 frida-drcov.py，其 README 建议主要用于移动应用。绝对地址轨迹必须与数据库的地址空间一致，无法映射的地址会被丢弃；模块+偏移轨迹中其他模块的命中不会载入。
- Lighthouse 及贡献的 pintool 均采用 MIT 许可。打开覆盖率总览时会查询 GitHub 发布 API 以检查新版本。

## 一手来源

1. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/README.md>
2. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/coverage/README.md>
3. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/coverage/pin/README.md>
4. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/coverage/frida/README.md>
5. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/plugins/lighthouse/util/disassembler/ida_api.py#L12-L14>
6. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/plugins/lighthouse/reader/parsers/tenet.py>
7. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/plugins/lighthouse/util/update.py>
8. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/binjastub/plugin.json>
9. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/LICENSE>
10. <https://github.com/gaasedelen/lighthouse/blob/562595be9bd99e8a5dfef6017d608467f5706630/coverage/pin/LICENSE>
11. <https://github.com/gaasedelen/lighthouse/releases/tag/v0.9.3>
12. <https://github.com/gaasedelen/lighthouse/compare/master...develop>

## 同分区更多条目：原生二进制

- [BinAbsInspector 二进制漏洞静态扫描工具](https://awesomerea.org/zh/resources/binabsinspector/index.md) · 工具
- [VulHunt 社区版漏洞挖掘框架](https://awesomerea.org/zh/resources/vulhunt/index.md) · 工具
- [BinSync 协同逆向插件](https://awesomerea.org/zh/resources/binsync/index.md) · 工具
- [class-dump Objective-C 头文件生成工具](https://awesomerea.org/zh/resources/class-dump/index.md) · 工具
- [Lucid Hex-Rays 微码浏览器](https://awesomerea.org/zh/resources/lucid-microcode-explorer/index.md) · 工具
- [r2dec radare2 反编译插件](https://awesomerea.org/zh/resources/r2dec/index.md) · 工具

## 关于此条目

说明已依据一手来源复核。
原创说明采用 MIT 许可；外部项目、论文与素材保留各自的权利和许可。
