1rhino2/phantom-stealer
GitHub: 1rhino2/phantom-stealer
这是一个用 Go 编写的 Windows 平台信息窃取工具,专为安全研究与恶意软件分析设计,具备浏览器密码解密、加密钱包窃取及反分析规避等功能。
Stars: 35 | Forks: 6
# Phantom Stealer
(谁能当个英雄把浏览器数据导出功能修好,我受不了 chrome。)
**仅供教育用途**
一个用 Go 编写的 Windows 信息窃取器 / 凭据窃取器,用于安全研究和恶意软件分析。展示了浏览器密码提取、加密钱包窃取、Discord token 抓取以及反分析规避技术。
关键词:stealer, infostealer, password stealer, credential stealer, browser stealer, cookie stealer, discord token grabber, discord stealer, telegram grabber, crypto wallet stealer, metamask stealer, phantom wallet, exodus stealer, chrome password stealer, edge password stealer, brave stealer, windows malware, golang malware, go stealer, rat, trojan, credential harvester, password dumper, DPAPI, token logger, session hijacker, redline stealer alternative, raccoon stealer, vidar stealer, mars stealer, aurora stealer, lumma stealer, stealc, rhadamanthys, mystic stealer, meta stealer, risepro, amadey, formbook, lokibot, azorult, predator stealer, kpot stealer, arkei stealer, oski stealer, research, malware analysis, reverse engineering, security research, red team, penetration testing, offensive security
## 目录
- [免责声明](#disclaimer)
- [功能](#features)
- [目标](#targets)
- [技术概览](#technical-overview)
- [构建](#building)
- [项目结构](#project-structure)
- [检测与防御](#detection--defense)
- [类似项目](#similar-projects)
- [法律声明](#legal-notice)
- [许可证](#license)
## 免责声明
**本软件仅供教育和研究目的提供。**
本项目存在的唯一目的是:
- 向安全研究人员传授凭据窃取技术
- 帮助安全专业人员了解攻击向量
- 协助开发更好的防御措施
- 演示用于合法安全研究的 Windows API 用法
**你需对自己的行为承担全部责任。** 作者不对本软件的滥用承担任何责任。在未经拥有或未获得明确书面许可的系统上使用此工具是**非法**且**不道德**的。
通过下载、复制或使用本软件,你同意:
1. 仅在你拥有或获得书面授权测试的系统上使用它
2. 遵守所有适用的地方法律、州法律、联邦法律和国际法律
3. 作者对任何损害或法律后果不承担任何责任
4. 这仅用于教育目的,以了解威胁并构建防御
**如果你实际上想从他人那里窃取数据——别这么做。寻求帮助。**
## 功能
### 浏览器密码窃取器
- Chrome 密码窃取器 / Chrome 密码解密器
- Edge 密码窃取器 / Edge 密码恢复
- Brave 密码窃取器
- Opera / Opera GX 密码抓取器
- Vivaldi 密码提取
- Firefox 密码解密
- Cookie 窃取器 / 会话劫持者
- 信用卡数据提取
- 自动填充数据抓取器
- 浏览历史记录提取
- DPAPI 解密 / CryptUnprotectData
- 现代版 Chrome 的 AES-GCM 解密
### 加密钱包窃取器
- Exodus 钱包窃取器
- Electrum 钱包抓取器
- Atomic 钱包窃取器
- Coinomi 钱包提取
- Bitcoin Core wallet.dat 抓取器
- Ethereum keystore 窃取器
- Monero 钱包提取
- MetaMask 扩展程序窃取器
- Phantom 钱包抓取器 (Solana)
- Trust Wallet 窃取器
- Coinbase Wallet 抓取器
- Ronin 钱包 (Axie Infinity)
- 支持 40 多种浏览器扩展钱包
### Token 抓取器 / 会话窃取器
- Discord token 抓取器 / Discord token 窃取器
- Discord token 解密器(加密 token)
- Telegram 会话窃取器 (tdata 抓取器)
- Steam 会话窃取器 (SSFN 抓取器)
- Steam config.vdf 提取
### 系统侦察
- 硬件/软件清单
- 网络配置枚举
- 屏幕截图捕获
- 剪贴板监控 / 剪贴板窃取器
- WiFi 密码提取 (netsh)
- 进程枚举
- 已安装软件检测
- 杀毒软件检测
### 反分析 / 规避
- 虚拟机检测 (VMware, VirtualBox, Hyper-V)
- 沙箱检测
- 调试器检测 (IsDebuggerPresent, NtQueryInformationProcess)
- AMSI 绕过 / AMSI 打补丁
- ETW 打补丁
- Windows Defender 排除项
- 反取证技术
### 持久化机制
- 注册表 Run 键持久化
- 启动文件夹持久化
- 计划任务持久化
- WMI 事件订阅持久化
### 数据外泄
- Discord webhook 外泄
- Telegram bot 外泄
- Zip 压缩包创建
- 自动文件整理
## 目标
### 支持的浏览器
Chrome, Chromium, Edge, Brave, Opera, Opera GX, Vivaldi, Yandex, Firefox, Waterfox 等
### 支持的钱包
Exodus, Electrum, Atomic, Jaxx, Coinomi, Guarda, Bitcoin Core, Litecoin Core, Dash Core, Monero, Zcash, Wasabi Wallet, Armory, Bytecoin, Binance
### 浏览器扩展钱包
MetaMask, TronLink, Binance Chain, Coin98, Phantom, Trust Wallet, Coinbase Wallet, Ronin, Keplr, Solflare, Slope, Rabby, OKX Wallet, Petra, Martian, SubWallet, Nami, Eternl 以及 30 多种其他
### 针对的平台
Discord (桌面版 + 浏览器), Telegram Desktop, Steam
## 技术概览
使用纯 Go 编写,依赖极少。使用 Windows API 调用实现:
- DPAPI 解密 (`CryptUnprotectData`)
- 进程枚举
- 注册表操作
- 屏幕截图捕获 (GDI)
### 核心组件:
- **browsers/** - Chromium 密码/Cookie 解密
- **wallets/** - 加密钱包文件提取
- **tokens/** - Discord/Telegram/Steam token 抓取
- **evasion/** - 反分析技术
- **recon/** - 系统信息收集
- **exfil/** - 数据外泄 (Discord/Telegram webhooks)
## 构建
```
# Standard build
go build -o phantom.exe .
# Production build (更小,无 debug symbols)
go build -ldflags "-s -w -H windowsgui" -o phantom.exe .
# With garble for obfuscation (install: go install mvdan.cc/garble@latest)
garble -literals build -ldflags "-s -w -H windowsgui" -o phantom.exe .
```
**要求:**
- Go 1.21+
- Windows(使用 Windows 特定 API)
- 启用 CGO(用于 SQLite)
## 项目结构
```
phantom-stealer/
├── main.go # Entry point
├── config/ # Configuration and targets
├── browsers/ # Browser data extraction
│ └── chromium.go # Chromium-based browser handling
├── wallets/ # Crypto wallet extraction
├── tokens/ # Discord/Telegram/Steam tokens
├── evasion/ # Anti-analysis techniques
├── recon/ # System reconnaissance
├── persist/ # Persistence mechanisms
├── exfil/ # Data exfiltration
└── syscalls/ # Windows API wrappers
```
## 检测与防御
### 如何检测此类恶意软件:
1. 监控注册表 Run 键中的可疑条目
2. 监控浏览器目录中的 SQLite 数据库访问
3. 检测来自非浏览器进程的 DPAPI 调用
4. 监控发往 Discord/Telegram 的 webhook/API 流量
5. 使用基于行为的杀毒软件检测凭据访问模式
### 如何保护自己:
1. 使用密码管理器(浏览器存储的密码易受攻击)
2. 在所有账户上启用 2FA
3. 不要在桌面/文档中存储敏感文件
4. 使用硬件钱包存储加密货币
5. 保持系统更新并安装 EDR/AV 解决方案
6. 对随机可执行文件保持警惕
## 法律声明
本软件按“原样”提供,不提供任何形式的担保。作者:
- 不纵容非法活动
- 不为恶意使用提供支持
- 不对造成的任何损害负责
- 创建此项目仅用于教育目的
**未经授权访问计算机系统是一种犯罪。** 处罚包括:
- **CFAA (美国)**:最高 10 年以上监禁
- **CMA (英国)**:最高 10 年监禁
- 全球各地存在类似法律
如果你非法使用此工具,你最终**一定会**被抓住。现代取证技术非常先进。
## 类似项目
其他你可能发现对比较有用的开源窃取器和安全研究项目:
- Redline Stealer (恶意软件家族 - 用于分析)
- Raccoon Stealer (恶意软件家族 - 用于分析)
- Vidar Stealer (恶意软件家族 - 用于分析)
- Mars Stealer (恶意软件家族 - 用于分析)
- Aurora Stealer (恶意软件家族 - 用于分析)
- Lumma Stealer (恶意软件家族 - 用于分析)
- StealC (恶意软件家族 - 用于分析)
- Rhadamanthys (恶意软件家族 - 用于分析)
- 各种 GitHub 凭据收集研究项目
本项目是从零开始构建的学习练习,并非从任何现有窃取器派生而来。
## 许可证
本项目在 MIT 许可证下获得许可 - 请见下文。
```
MIT License
Copyright (c) 2025
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
```
## 备注
懒得手动添加提交记录,临时发个 GitHub 帖子,哈哈。
这最初是一个学习项目,旨在了解 Windows 内部原理以及窃取器实际的工作方式。我想把它发布在这里,以防其他人发现它对防御性研究有用,或者只是想研究一下代码。
如果你是一名安全研究人员,希望这对你的工作有帮助。如果你试图将其用于实际的恶意目的,请认真重新考虑你的人生选择。
欢迎提交 PR 以进行教育性改进、错误修复,或在防御部分添加更多检测方法。
### 相关主题
malware development, malware programming, windows malware, golang malware development, infostealer source code, stealer source code, password stealer source, credential stealer github, discord token grabber source, crypto stealer source, browser password recovery, DPAPI programming, windows api hacking, red team tools, offensive security tools, penetration testing tools, security research, malware analysis, reverse engineering malware, threat research, cybersecurity research, ethical hacking, bug bounty, ctf tools, windows security research
**记住:能力越大,责任越大。将知识用于正途。**(虽然很老套,但我们必须保持法律上的安全。)
标签:Brave浏览器, Chrome密码, Cookie窃取, DAST, Discord令牌, DPAPI, Edge密码, EVTX分析, Exodus钱包, Golang恶意软件, Go语言, MetaMask, Phantom钱包, Telegram抓取, Windows恶意软件, 云资产清单, 会话劫持, 信息窃取, 凭证转储, 加密货币钱包, 反分析, 安全助手, 安全测试, 密码窃取, 恶意软件, 恶意软件分析, 攻击性安全, 数据展示, 日志审计, 木马, 浏览器密码, 知识库安全, 程序破解, 端点可见性, 红队, 规避技术, 远程访问木马, 逆向工程