Skip to content
KitploitKITPLOIT
工具博客
提交
工具博客
提交

黑客、渗透测试和网络安全工具,武装您的安全武器库!

Kitploit 是一个黑客、网络安全和渗透测试工具的目录。发现最新的项目更新,查找漏洞、分析系统、自动化测试并加强你的安全。

··订阅源·联系·隐私·© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
BootStomp — BootStomp:一个启动加载器漏洞发现工具 | Kitploit
工具/GitHubGitHub/ucsb-seclab/bootstomp
Android安全漏洞分析漏洞利用模糊测试二进制分析固件分析
GitHubucsb-seclab/bootstomp

BootStomp

BootStomp:一个启动加载器漏洞发现工具

查看仓库
416667年前Kitploit 审核通过

最受欢迎

查看全部 →

发现我们社区最常用的工具。

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享
网站

BootStomp

License

BootStomp 是一个引导加载程序漏洞查找工具。它针对两类不同的漏洞进行检测:内存损坏和状态存储漏洞。更多信息请参考 BootStomp 论文:https://seclab.cs.ucsb.edu/academic/publishing/#bootstomp-security-bootloaders-mobile-devices-2017

要运行 BootStomp 的分析,请阅读以下说明。请注意,BootStomp 适用于为 ARM 架构(32 位和 64 位)编译的引导加载程序,并且结果可能因 angr 和 Z3 的版本而略有不同。这是因为 angr 分析基本块的时间以及 Z3 表达式具体化的结果存在差异。


目录结构

  • analysis:包含不同设备引导镜像的分析结果(例如:IDA idbs 等)。
  • tools:包含可用于处理各种镜像的工具。

前置条件

  • angr (http://angr.io/)

$ pip install angr

  • IDA PRO (https://www.hex-rays.com/products/ida/)
  • IDA 反编译器 (https://www.hex-rays.com/products/decompiler/)

如何运行

使用 Docker 运行 BootStomp

使用 BootStomp 最简单的方式是在 Docker 容器中运行。 docker 文件夹包含相应的 Dockerfile。 以下是使用命令。

root@kitploit:~
cd docker
# 构建 Docker 镜像
docker build -t bootstomp .
# 运行 Docker 镜像(如有需要,请使用适当的选项来持久化更改或共享文件)
docker run -it bootstomp

# 现在你在 Docker 容器内
cd BootStomp
# 对其中一个示例运行 BootStomp 的污点分析
# 这将花费大约 30 分钟
python taint_analysis/bootloadertaint.py config/config.huawei
# 输出的最后一行类似于:
# INFO    | 2017-10-14 01:54:10,617 | _CoreTaint | Results in /tmp/BootloaderTaint_fastboot.img_.out

# 然后你可以使用以下命令“漂亮打印”结果:
python taint_analysis/result_pretty_print.py /tmp/BootloaderTaint_fastboot.img_.out

输出应类似于:

root@kitploit:~
...
17)
===================== Start Info path =====================
Dereference address at: 0x5319cL
Reason: at location 0x5319cL a tainted variable is dereferenced and used as address.
...
Tainted Path 
----------------
0x52f3cL -> 0x52f78L -> 0x52f8cL -> 0x52fb8L -> 0x52fc8L -> 0x52fecL -> 0x53000L -> 0x53014L -> 0x5301cL -> 0x53030L -> 0x53044L -> 0x53050L -> 0x5305cL -> 0x53068L
===================== End Info path =====================
# Total sinks related alerts: 5
# Total loop related alerts: 8
# Total dereference related alerts: 4

手动运行 BootStomp

自动检测污点源和汇聚点

  1. 在 IDA 中加载引导加载程序二进制文件(我们使用了 v6.95)。根据手机 CPU 架构(32 位或 64 位),需要相应的 IDA 版本。
  2. 从菜单栏中,运行 File => Script file => find_taint.py
  3. 输出将出现在引导加载程序所在目录下的 taint_source_sink.txt 文件中。

配置文件

为引导加载程序二进制文件创建一个 JSON 配置文件(参见 config/ 中的示例),其中:

  • bootloader:引导加载程序文件路径
  • info_path:引导加载程序源/日志信息文件路径(即 taint_source_sink.txt)
  • arch:架构位数(可用选项为 32 和 64)
  • enable_thumb:分析时考虑 thumb 模式(需要时)
  • start_with_thumb:以启用 thumb 模式开始分析
  • exit_on_dec_error:如果某些指令无法解码则停止分析
  • unlock_addr:解锁函数地址。此字段仅用于查找不安全的状态存储漏洞。

查找内存损坏漏洞

运行

python bootloadertaint.py 配置文件路径

结果将存储在 /tmp/BootloaderTaint_[引导加载程序名称].out 中,其中 [引导加载程序名称] 是分析的引导加载程序名称。请注意,涉及循环的路径可能会多次出现。

查找不安全的状态存储漏洞

运行

python unlock_checker.py 配置文件路径

结果将存储在 /tmp/UnlockChecker_[引导加载程序名称].out 中,其中 [引导加载程序名称] 是分析的引导加载程序名称。请注意,涉及循环的路径可能会多次出现。

检查结果

要检查 BootStomp 的结果,请使用脚本 result_pretty_print.py,如下所示:

python result_pretty_print.py 结果文件

CVE-2017-2729 的 Exploit

其他参考资料

  • MediaTek MT65x2 的内核和 lk 源码
  • MediaTek 细节:分区和预加载器
  • 逆向工程 Android 的 Aboot
  • 基于 (L)ittle (K)ernel 的 Android 引导加载程序
  • Qualcomm 的 Little Kernel 引导加载程序概述
  • android: arm: bootloader: (L)ittle (K)ernel 如何加载 boot.img
  • Nexus 设备的 BootUnlocker
  • 验证启动
  • 释放我的平板电脑(Android 黑客,软硬件)
  • 如何利用 aboot 的未文档化特性锁定三星下载模式
  • BIOS 和安全启动攻击揭秘
  • Apple iOS 安全指南
  • 调试 HTC 手机引导加载程序
  • HBOOT 调试器
  • 分析 HBOOT
下载工具