
HackBrowserData v1.2.0
提取和解密浏览器数据,支持多种数据类型,可在多种操作系统(macOS、Windows、Linux)上运行。
HackBrowserData
HackBrowserData 是一款命令行工具,用于解密并导出浏览器数据(密码、历史记录、Cookie、书签、信用卡、下载历史、localStorage、sessionStorage 和扩展程序)。它支持 Windows、macOS 和 Linux 上最流行的基于 Chromium 的浏览器和 Firefox,以及 macOS 上的 Safari。
它还可以跨机器和跨操作系统解密数据:在源主机上导出主密钥,然后在任意其他主机上离线解密数据副本——即使分析主机所在的操作系统无法运行该浏览器(参见跨主机解密)。
免责声明:本工具仅用于安全研究。用户需对使用本工具所产生的一切法律及相关责任负责。原作者不承担任何法律责任。
支持的数据类别
| 类别 | 基于 Chromium | Firefox | Safari |
|---|---|---|---|
| 密码 | ✅ | ✅ | ✅ |
| Cookie | ✅ | ✅ | ✅ |
| 书签 | ✅ | ✅ | ✅ |
| 历史记录 | ✅ | ✅ | ✅ |
| 下载 | ✅ | ✅ | ✅ |
| 信用卡 | ✅ | - | - |
| 扩展程序 | ✅ | ✅ | ✅ |
| LocalStorage | ✅ | ✅ | ✅ |
| SessionStorage | ✅ | - | - |
支持的浏览器
在 macOS 上,部分基于 Chromium 的浏览器需要当前用户密码才能解密。
在 macOS 26.4 或更高版本上,密码解密可能会失败。
| 浏览器 | Windows | macOS | Linux |
|---|---|---|---|
| Chrome | ✅² | ✅ | ✅ |
| Chrome Beta | ✅² | ✅ | ✅ |
| Chromium | ✅ | ✅ | ✅ |
| Edge | ✅² | ✅ | ✅ |
| Brave | ✅² | ✅ | ✅ |
| Opera | ✅ | ✅ | ✅ |
| OperaGX | ✅ | ✅ | - |
| Vivaldi | ✅ | ✅ | ✅ |
| Yandex | ✅ | ✅ | - |
| CocCoc | ✅² | ✅ | - |
| Arc | ✅ | ✅ | - |
| DuckDuckGo³ | ✅ | - | - |
| Browser from Vought³ | ✅ | - | - |
| QQ³ | ✅ | - | - |
| 360 Speed X³ | ✅ | - | - |
| 360 Speed³ | ✅ | - | - |
| DC³ | ✅ | - | - |
| Sogou³ | ✅ | - | - |
| Firefox | ✅ | ✅ | ✅ |
| Safari¹ | - | ✅ | - |
¹ Safari 需要“完全磁盘访问权限”;如果提取结果为空,请在“系统设置 → 隐私与安全性 → 完全磁盘访问权限”中启用该权限。
² 在 Windows 上,解密 Chromium 127+ 的 Cookie(Chrome / Chrome Beta / Edge / Brave / CocCoc)需要使用通过
make build-windows构建的 App-Bound Encryption 载荷——请参阅下方的从源码构建。³ 这些浏览器仅在 Windows 上发布,但其数据可在任何操作系统上解密:使用
archive提取文件,使用dumpkeys导出密钥,然后在 macOS 或 Linux 上使用restore进行解密——请参阅跨主机解密。
快速开始
安装
HackBrowserData 的安装非常简单,只需下载适用于你系统的发行版并运行二进制文件即可。
在某些情况下,此安全工具会被 Windows Defender 或其他杀毒软件视为病毒而无法执行。代码全部开源,你可以自行修改并编译。
从源码构建
需要 Go 1.20+。
git clone https://github.com/moonD4rk/HackBrowserData
cd HackBrowserData
go build ./cmd/hack-browser-data/
跨平台构建
# For Windows (standard build, no Chromium 127+ ABE cookie support)
GOOS=windows GOARCH=amd64 go build ./cmd/hack-browser-data/
# For Linux
GOOS=linux GOARCH=amd64 go build ./cmd/hack-browser-data/
带 App-Bound Encryption 的 Windows 构建(可选)
Chrome / Chrome Beta / Edge / Brave / CocCoc 127+ 使用 App-Bound Encryption 保护 cookie。解密这些 cookie 需要一个小型 C 载荷——推荐使用 Zig(0.13+)作为 C 工具链(Makefile 会调用 zig cc)。如果绕过 make payload,MinGW-w64 的 gcc 也可以手动构建这些源文件。
# 1. Install Zig
brew install zig # macOS
scoop install zig # Windows (scoop)
# or download from https://ziglang.org/download/
# 2. Build the payload (outputs internal/abe/payload/abe_extractor_amd64.bin)
make payload
# 3. Build hack-browser-data.exe with the ABE payload embedded
make build-windows
生成的 hack-browser-data.exe 包含对 Chromium 127+ 的完整 ABE cookie 解密功能。
用法
$ hack-browser-data -h
hack-browser-data decrypts and exports browser data from Chromium-based
browsers, Firefox, and Safari on Windows, macOS, and Linux.
GitHub: https://github.com/moonD4rk/HackBrowserData
Usage:
hack-browser-data [flags]
hack-browser-data [command]
Available Commands:
archive Pack decryption-relevant profile files into a zip for cross-host restore
dump Extract and decrypt browser data (default command)
dumpkeys Export Chromium master keys as JSON for cross-host decryption
help Help about any command
list List detected browsers and profiles
restore Decrypt copied profile data using exported master keys
version Print version information
Flags:
-b, --browser string target browser: all|chrome|firefox|edge|... (default "all")
-c, --category string data categories (comma-separated): all|password,cookie,... (default "all")
-d, --dir string output directory (default "results")
-f, --format string output format: csv|json|cookie-editor (default "json")
-h, --help help for hack-browser-data
--keychain-pw string macOS keychain password (visible in ps and shell history)
--keychain-pw-stdin read the macOS keychain password from the first line of stdin
-p, --profile-path string custom profile dir path, get with chrome://version
-v, --verbose enable debug logging
--zip compress output to zip
Use "hack-browser-data [command] --help" for more information about a command.
dump - 提取并解密浏览器数据(默认)
在不带子命令的情况下运行 hack-browser-data 会默认执行 dump。