# avatar² 多目标固件动态分析编排框架

> 由 EURECOM S3 小组开发的 Python 框架，可协调模拟器、调试器和物理设备，对嵌入式固件进行动态分析。分析脚本先声明目标（如修改版 QEMU、PANDA、Unicorn、gdbserver，或 OpenOCD、J-Link 调试探针），再定义内存布局（其中的内存区间可把访问从一个目标转发到另一个目标）和执行计划。执行过程以及寄存器、内存状态可在目标之间转移，从而让固件在模拟器中运行，同时把外设访问转发给真实设备。

- 类型：工具
- 目标：固件
- 类别：固件工具
- 关联：基础工具
- 来源复核于：2026-10-19
- 收录于：2026-10-19
- 原始资源：<https://github.com/avatartwo/avatar2>
- 一手来源：<https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/README.md>
- 目录页面：<https://awesomerea.org/zh/resources/avatar2/>
- 记录 JSON：<https://awesomerea.org/resources/avatar2/record.json>
- 英文版：[English](https://awesomerea.org/resources/avatar2/index.md)

## 使用条件与局限

- 审阅时最新版本为 1.4.7，于 2022-02-10 上传到 PyPI，对应标签 v1.4.7；GitHub 上没有发布页面。所审阅的 main 分支提交（2024-10-23）比该标签多九个提交，新增了 ARMv7-M 中断转发和硬件运行器插件，并将 Unicorn 固定为 2.0.1.post1。
- 核心部分可用 pip 安装；CI 在 Ubuntu 20.04 上测试 Python 3.7-3.9。目标端点需单独构建：python -m avatar2.installer 或 targets/build_*.sh 脚本会构建 avatar-qemu 分支和 PANDA，构建脚本只为 Ubuntu 20.04 提供；这些脚本会把 restricted 软件源的 deb-src 条目写入 /etc/apt/sources.list，因此 README 建议在虚拟机或容器中构建。另有 Dockerfile 生成脚本，可按所选端点构建镜像。
- 分析需要使用者自有的固件镜像；混合部署还需要可通过 gdbserver、OpenOCD 脚本或 Segger J-Link 探针访问的物理设备。架构定义涵盖 ARM（包括 Cortex-M3 和大端变体）、MIPS 以及 x86/x86-64。内存布局、转发规则和执行计划都由分析者用 Python 编写。
- 采用 Apache-2.0 许可；avatar-qemu 和 PANDA 位于独立仓库，各有其许可。README 列出了介绍、使用或扩展该框架的研究论文。

## 一手来源

1. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/README.md>
2. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/handbook/0x01_intro.md>
3. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/handbook/0x02_targets.md#L67-L155>
4. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/handbook/0x03_memory.md#L31-L45>
5. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/handbook/0x04_execution.md#L113-L165>
6. <https://github.com/avatartwo/avatar2/tree/56a90cfe738886236dcbc3653756bdbdec6aaf92/avatar2/targets>
7. <https://github.com/avatartwo/avatar2/tree/56a90cfe738886236dcbc3653756bdbdec6aaf92/avatar2/archs>
8. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/setup.py>
9. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/.github/workflows/continuous_integration.yml>
10. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/targets/build_qemu.sh>
11. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/CHANGELOG.md>
12. <https://github.com/avatartwo/avatar2/blob/56a90cfe738886236dcbc3653756bdbdec6aaf92/LICENSE>
13. <https://pypi.org/project/avatar2/1.4.7/>

## 同分区更多条目：固件与硬件

- [efiXplorer UEFI 固件分析 IDA 插件](https://awesomerea.org/zh/resources/efixplorer/index.md) · 工具
- [vmlinux-to-elf 内核符号恢复工具](https://awesomerea.org/zh/resources/vmlinux-to-elf/index.md) · 工具
- [Sony-PMCA-RE Sony 数码相机逆向工具](https://awesomerea.org/zh/resources/sony-pmca-re/index.md) · 工具
- [cpu_rec CPU 指令集统计识别工具](https://awesomerea.org/zh/resources/cpu-rec/index.md) · 工具
- [ME Analyzer Intel 引擎与图形固件分析工具](https://awesomerea.org/zh/resources/me-analyzer/index.md) · 工具
- [CHIPSEC 平台安全评估框架](https://awesomerea.org/zh/resources/chipsec/index.md) · 工具

## 关于此条目

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