daem0nc0re/VectorKernel

GitHub: daem0nc0re/VectorKernel

一个面向 Windows 内核模式 Rootkit 技术研究的 PoC 合集,涵盖进程隐藏、令牌窃取、权限提升、键盘记录、DLL 注入等多种经典内核攻击手法的独立演示模块。

Stars: 435 | Forks: 67

# VectorKernel 用于内核模式 Rootkit 技术研究或教育的 PoC。 目前主要针对 Windows 操作系统。 所有模块仅支持 x64 系列 64 位操作系统。 ## 环境 所有模块均在 Windows 11 x64 中进行了测试。 要测试驱动程序,测试机可以使用以下选项: 1. [启用测试签名驱动程序的加载](https://learn.microsoft.com/en-us/windows-hardware/drivers/install/the-testsigning-boot-configuration-option) 2. [设置内核模式调试](https://learn.microsoft.com/en-us/windows-hardware/drivers/debugger/setting-up-kernel-mode-debugging-in-windbg--cdb--or-ntsd) 每个选项都需要禁用安全启动。 ## 模块 每个项目目录中的 README.md 提供了详细信息。 所有模块均在 Windows 11 中进行了测试。 | 模块名称 | 描述 | | :--- | :--- | | [BlockImageLoad](./BlockImageLoad/) | 使用 Load Image Notify Callback 方法阻止驱动程序加载的 PoC。 | | [BlockNewProc](./BlockNewProc/) | 使用 Process Notify Callback 方法阻止新进程的 PoC。 | | [CreateToken](./CreateToken/) | 使用 `ZwCreateToken()` API 获取完全特权 SYSTEM token 的 PoC。 | | [DropProcAccess](./DropProcAccess/) | 使用 Object Notify Callback 降低进程句柄访问权限的 PoC。 | | [ElevateHandle](./ElevateHandle/) | 使用 DKOM 方法提升句柄访问权限的 PoC。 | | [FileDirHide](./FileDirHide/) | 隐藏文件/目录的 PoC。 | | [GetFullPrivs](./GetFullPrivs/) | 使用 DKOM 方法获取完全特权的 PoC。 | | [GetKeyStroke](./GetKeyStroke/) | 使用内核驱动程序记录键盘操作的 PoC。 | | [GetProcHandle](./GetProcHandle/) | 从内核模式获取完全访问权限进程句柄的 PoC。 | | [InjectLibrary](./InjectLibrary/) | 使用 Kernel APC Injection 方法执行 DLL 注入的 PoC。 | | [MemRead](./MemRead/) | 读取任意进程内存的 PoC。 | | [ModHide](./ModHide/) | 使用 DKOM 方法隐藏已加载内核驱动程序的 PoC。 | | [ProcHide](./ProcHide/) | 使用 DKOM 方法隐藏进程的 PoC。 | | [ProcProtect](./ProcProtect/) | 操纵受保护进程的 PoC。 | | [QueryModule](./QueryModule/) | 执行检索内核驱动程序加载地址信息的 PoC。 | | [StealToken](./StealToken/) | 从内核模式执行 token 窃取的 PoC。 | ## TODO 未来将添加更多 PoC,尤其是关于以下内容: * Notify callback * Filesystem mini-filter * Network mini-filter ## 推荐参考资料 * [Pavel Yosifovich, **_Windows Kernel Programming, 2nd Edition_** (Independently published, 2023)](https://leanpub.com/windowskernelprogrammingsecondedition) * [Bruce Dang, Alexandre Gazet, Elias Bachaalany, and Sébastien Josse, **_Practical Reverse Engineering: x86, x64, ARM, Windows Kernel, Reversing Tools, and Obfuscation_** (Wiley Publishing, 2014)](https://www.amazon.com/Practical-Reverse-Engineering-Reversing-Obfuscation/dp/1502489309) * [Greg Hoglund, and Jamie Butler, **_Rootkits : Subverting the Windows Kernel_** (Addison-Wesley Professional, 2005)](https://www.amazon.com/Rootkits-Subverting-Windows-Greg-Hoglund/dp/0321294319) * [Bill Blunden, **_The Rootkit Arsenal: Escape and Evasion in the Dark Corners of the System, 2nd Edition_** (Jones & Bartlett Learning, 2012)](https://www.amazon.com/Rootkit-Arsenal-Escape-Evasion-Corners/dp/144962636X) * [Pavel Yosifovich, Mark E. Russinovich, Alex Ionescu, and David A. Solomon, **_Windows Internals, Part 1: System architecture, processes, threads, memory management, and more, 7th Edition_** (Microsoft Press, 2017)](https://www.microsoftpressstore.com/store/windows-internals-part-1-system-architecture-processes-9780735684188) * [Andrea Allievi, Mark E. Russinovich, Alex Ionescu, and David A. Solomon, **_Windows Internals, Part 2, 7th Edition_** (Microsoft Press, 2021)](https://www.microsoftpressstore.com/store/windows-internals-part-2-9780135462409) * [Matt Hand, **_Evading EDR - The Definitive Guide to Defeating Endpoint Detection Systems_** (No Starch Press, 2023)](https://nostarch.com/evading-edr)
标签:0day挖掘, APC注入, API接口, C/C++, DKOM, DLL注入, KMDF, meg, Network, PoC, Ring0, Rootkit, UML, WDM, Windows内核, Zeek, 中高交互蜜罐, 事务性I/O, 令牌伪造, 信息安全, 内核回调, 内核安全, 内核态, 内核驱动, 协议分析, 子域名枚举, 安全测试, 安全防御绕过, 对象回调, 恶意软件开发, 攻击性安全, 数据展示, 文件隐藏, 暴力破解, 权限提升, 流量审计, 白帽子, 系统安全, 红队, 网络协议, 网络可见性, 网络安全, 网络安全监控, 进程隐藏, 键盘记录, 隐私保护, 驱动开发