红队行动中的Rust武器化。
我在武器化 Rust 用于植入开发及一般攻击性操作方面的实验。
mingw 工具链,不过某些库可能无法在其他操作系统上成功编译。| 文件 | 描述 |
|---|---|
| Allocate_With_Syscalls | 直接使用 ntapi 库中的 NTDLL 函数 |
| Create_DLL | 创建 DLL 并弹出一个消息框,Rust 对 DLL 的支持并不完整,由于 Rust DLL 没有 main 函数,可能出现异常情况 |
| DeviceIoControl | 打开驱动句柄并执行 DeviceIoControl |
| EnableDebugPrivileges | 在当前进程中启用 SeDebugPrivilege |
| Shellcode_Local_inject | 通过指针强制转换,直接在本进程中执行 Shellcode |
| Execute_With_CMD | 通过 Rust 传递命令来执行 cmd |
| ImportedFunctionCall | 从 dbghelp 导入 minidump 并执行 |
| Kernel_Driver_Exploit | 针对简单缓冲区溢出的内核驱动漏洞利用 |
| Named_Pipe_Client | 命名管道客户端 |
| Named_Pipe_Server | 命名管道服务端 |
| PEB_Walk | 动态解析和调用 Windows API |
| Process_Injection_CreateThread | 使用 CreateThread 向运行中的进程注入 |
| Process_Injection_CreateRemoteThread | 使用 CreateRemoteThread 向远程进程注入 |
| Process_Injection_Self_EnumSystemGeoID | 使用 EnumSystemsGeoID API 调用来运行 shellcode 的自注入器。 |
| Unhooking | 挂钩解除 |
| asm_syscall | 通过汇编获取 PEB 地址 |
| base64_system_enum | Base64 编解码字符串 |
| http-https-requests | 忽略证书检查的 HTTP/S GET/POST 请求 |
| patch_etw | 修补 ETW |
| ppid_spoof | 伪造创建进程的父进程 |
| tcp_ssl_client | 忽略证书检查的 SSL TCP 客户端(编译需要安装 openssl 和 perl) |
| tcp_ssl_server | TCP 服务端,带端口参数(编译需要安装 openssl 和 perl) |
| wmi_execute | 执行 WMI 查询以获取主机上的 AV/EDR |
| Windows.h+ Bindings | 该文件包含 Windows.h 的结构体,以及完整的自定义 LDR、PEB 等(微软未正式文档化)。在文件顶部添加 include!("../bindings.rs"); |