BenmezOthmane/SOC-SOAR

GitHub: BenmezOthmane/SOC-SOAR

一个混合架构的安全运营中心实验平台,将本地 Wazuh/Shuffle/TheHive 与 Azure 云端 Sentinel/Logic Apps 结合,覆盖从攻击模拟到自动响应的完整事件生命周期。

Stars: 0 | Forks: 0

# SOC-SOAR-Lab — 混合安全运营中心 ![状态](https://img.shields.io/badge/Status-In%20Progress-orange?style=flat-square) ![SIEM](https://img.shields.io/badge/SIEM-Wazuh%20%7C%20Microsoft%20Sentinel-blue?style=flat-square) ![SOAR](https://img.shields.io/badge/SOAR-Shuffle%20%7C%20Azure%20Logic%20Apps-purple?style=flat-square) ![云平台](https://img.shields.io/badge/Cloud-Microsoft%20Azure-0089D6?style=flat-square&logo=microsoft-azure) ![虚拟化](https://img.shields.io/badge/Virtualization-VMware%20Workstation%20Player-607078?style=flat-square&logo=vmware) ![成本](https://img.shields.io/badge/Cost-Free%20%2F%20Azure%20Free%20Tier-green?style=flat-square) ![框架](https://img.shields.io/badge/Framework-MITRE%20ATT%26CK-red?style=flat-square) ## 概述 本项目使用混合架构模拟了一个完整的企业级安全运营中心 (SOC),结合了运行在 **VMware Workstation Player** 上的本地开源工具和 **Microsoft Azure 免费层** 服务。 它涵盖了完整的事件生命周期:**攻击模拟 → 检测 → 自动响应 → 备份与恢复**,镜像反映了安全团队在真实组织中的运作方式。 ## 架构 ``` ┌─────────────────────────────────────────────────────────────────────┐ │ HOST MACHINE — Windows 11 (16 GB RAM) │ │ VMware Workstation Player │ │ │ │ ┌──────────────────────────┐ ┌──────────────────────────────┐ │ │ │ Ubuntu 22.04 VM │ │ Windows 10 VM │ │ │ │ (6 GB RAM) │ │ (3 GB RAM) │ │ │ │ │ │ │ │ │ │ ├─ Wazuh SIEM │ │ ├─ Sysmon │ │ │ │ ├─ Shuffle SOAR │◄──┤ ├─ Winlogbeat │ │ │ │ └─ TheHive │ │ └─ Atomic Red Team │ │ │ │ (Docker) │ │ │ │ │ └──────────────┬───────────┘ └──────────────────────────────┘ │ │ │ VMnet8 (NAT) — shared network │ └─────────────────┼───────────────────────────────────────────────────┘ │ ▼ logs + alerts ┌─────────────────────────────────────────────────────────────────────┐ │ MICROSOFT AZURE — Free Tier │ │ │ │ ├─ Microsoft Sentinel (SIEM — cloud identity logs) │ │ ├─ Azure AD (Entra ID) (Identity + Impossible Travel) │ │ ├─ Azure Logic Apps (SOAR Playbooks — cloud) │ │ └─ Azure Blob Storage (Backup Copy 3 — encrypted offsite) │ └─────────────────────────────────────────────────────────────────────┘ ``` ## 实验环境 | 组件 | 工具 | 运行平台 | 内存 | |---|---|---|---| | Hypervisor | VMware Workstation Player | Windows 11 (主机) | — | | SIEM (本地) | Wazuh 4.7 | Ubuntu 22.04 VM | 6 GB | | SOAR (本地) | Shuffle (Docker) | Ubuntu 22.04 VM | 包含 | | 事件管理 | TheHive 5 (Docker) | Ubuntu 22.04 VM | 包含 | | 攻击模拟 | Atomic Red Team | Windows 10 VM | 3 GB | | 日志收集 | Sysmon + Winlogbeat | Windows 10 VM | 包含 | | SIEM (云) | Microsoft Sentinel | Azure 免费层 | — | | 身份认证 | Azure AD (Entra ID) | Azure 免费层 | — | | SOAR (云) | Azure Logic Apps | Azure 免费层 | — | | 备份 (异地) | Azure Blob Storage | Azure 免费层 | — | ### 网络配置 ``` VMnet8 (NAT) — 192.168.80.0/24 ├── Ubuntu VM (Wazuh) → 192.168.80.x └── Windows VM (Target) → 192.168.80.x Both VMs share the same NAT network. Host machine accesses all dashboards via browser. ``` ## 主要特性 - **5 个攻击场景** 映射至 MITRE ATT&CK — 使用 Atomic Red Team 进行模拟 - **自动化 SOAR 剧本** — 从告警到响应不到 60 秒,而手动操作需 15 分钟以上 - **混合 SIEM** — Wazuh 处理本地端点遥测数据;Sentinel 处理云身份日志 - **威胁情报富化** — 每次告警均自动通过 VirusTotal + AbuseIPDB 进行富化 - **3-2-1 备份策略** — 记录的 RTO < 4 小时,RPO < 24 小时 - **完整的事件响应报告** — 时间线、IOC、根本原因、经验教训 ## 技术栈 | 类别 | 工具 | |---|---| | 虚拟化 | VMware Workstation Player | | 主机操作系统 | Windows 11 | | 客户机操作系统 | Ubuntu 22.04 LTS Server, Windows 10 | | 容器化 | Docker + Docker Compose | | 攻击模拟 | Atomic Red Team, Sysmon, Winlogbeat | | SIEM | Wazuh 4.7, Microsoft Sentinel | | SOAR | Shuffle, Azure Logic Apps | | 事件管理 | TheHive 5 | | 威胁情报 | VirusTotal API, AbuseIPDB | | 身份与云平台 | Azure AD (Entra ID), Microsoft Defender | | 备份 | Azure Blob Storage, Bash + Python 脚本 | | 查询语言 | KQL (Kusto Query Language) | ## SOAR 剧本 | 剧本 | 触发器 | 自动响应 | |---|---|---| | 暴力破解响应 | 2 分钟内 5 次以上登录失败 | 禁用账户 + 发送邮件告警 | | IP 威胁情报 | 包含外部 IP 的告警 | VirusTotal + AbuseIPDB 查询 → 若为恶意则阻断 | | 恶意软件检测 | 可疑文件哈希 | 隔离 VM + 创建 TheHive 案例 | | 钓鱼告警 | 可疑电子邮件指标 | 提取 IOC + 富化 + 上报 | | 不可能旅行 | 1 小时内从 2 个不同国家登录 | 吊销 Azure AD 会话 + 强制 MFA | ## 检测规则 — KQL (Microsoft Sentinel) ``` // Brute Force Detection — 5+ failed logins in 2 minutes SigninLogs | where ResultType != "0" | summarize FailedAttempts = count(), IPList = make_set(IPAddress) by UserPrincipalName, bin(TimeGenerated, 2m) | where FailedAttempts >= 5 | project TimeGenerated, UserPrincipalName, FailedAttempts, IPList ``` ## 备份策略 — 3-2-1 ``` Copy 1 — Production (Ubuntu VM) → Live data: Wazuh alerts, configs, Playbooks Copy 2 — Local HDD / external drive → Daily automated backup via cron (bash script) Copy 3 — Azure Blob Storage → Weekly encrypted upload (Python script) ``` | 指标 | 目标 | 状态 | |---|---|---| | RTO (恢复时间目标) | < 4 小时 | ✓ 已记录 | | RPO (恢复点目标) | < 24 小时 | ✓ 已记录 | | 备份加密 | AES-256 (Azure 默认) | ✓ 已启用 | | 备份验证 | 每周完整性检查 | ✓ 已自动化 | ## 项目结构 ``` SOC-SOAR-Lab/ │ ├── README.md ├── LICENSE ├── .gitignore ├── ARCHITECTURE.md │ ├── 01-attack-simulation/ │ ├── README.md │ ├── atomic-tests/ │ │ ├── brute-force.yaml │ │ ├── lateral-movement.yaml │ │ ├── phishing-simulation.yaml │ │ └── impossible-travel.yaml │ └── sysmon/ │ ├── sysmonconfig.xml │ └── winlogbeat.yml │ ├── 02-siem-detection/ │ ├── README.md │ ├── wazuh/ │ │ ├── ossec.conf │ │ └── rules/ │ │ ├── brute-force-rules.xml │ │ ├── lateral-movement-rules.xml │ │ └── malware-detection-rules.xml │ └── sentinel/ │ ├── kql-queries/ │ │ ├── brute-force-detection.kql │ │ ├── impossible-travel.kql │ │ └── malware-hunt.kql │ └── data-connectors-setup.md │ ├── 03-soar-playbooks/ │ ├── README.md │ ├── shuffle/ │ │ ├── brute-force-response.json │ │ ├── phishing-response.json │ │ ├── malware-isolation.json │ │ └── ip-threat-block.json │ └── azure-logic-apps/ │ ├── sentinel-alert-playbook.json │ └── impossible-travel-response.json │ ├── 04-threat-intelligence/ │ ├── README.md │ ├── scripts/ │ │ ├── virustotal-lookup.py │ │ ├── abuseipdb-check.py │ │ └── ioc-enrichment.py │ └── config.env.example │ ├── 05-backup-321/ │ ├── README.md │ ├── scripts/ │ │ ├── local-backup.sh │ │ ├── azure-backup-upload.py │ │ └── backup-verify.sh │ └── schedules/ │ ├── crontab-config.txt │ └── task-scheduler-windows.xml │ ├── 06-incident-response/ │ ├── README.md │ ├── playbook-docs/ │ │ ├── IR-brute-force.md │ │ ├── IR-ransomware.md │ │ └── IR-phishing.md │ └── thehive/ │ ├── case-templates.json │ └── thehive-config.yml │ ├── 07-dashboard-metrics/ │ ├── README.md │ ├── screenshots/ │ ├── metrics-report.md │ └── before-after-automation.md │ └── docs/ ├── setup-guide.md ├── azure-setup.md ├── troubleshooting.md └── diagrams/ ├── architecture.png ├── 321-backup.png └── playbook-flows.png ``` ## MITRE ATT&CK 覆盖范围 | 战术 | 技术 ID | 技术名称 | 场景 | |---|---|---|---| | 初始访问 | T1566 | 钓鱼 | 钓鱼模拟 | | 凭据访问 | T1110 | 暴力破解 | 登录攻击检测 | | 横向移动 | T1021 | 远程服务 | 内部移动检测 | | 防御规避 | T1562 | 破坏防御 | 恶意软件规避模拟 | | 持久化 | T1078 | 有效账户 | 不可能旅行 / 账户滥用 | ## 指标 | 指标 | SOAR 前 | SOAR 后 | |---|---|---| | 平均检测时间 (MTTD) | ~8 分钟 | ~45 秒 | | 平均响应时间 (MTTR) | ~15 分钟 | ~60 秒 | | 需要人工分类的告警 | 100% | ~20% | | 自动封堵的事件 | 0% | ~80% | ## 快速开始 **前置条件:** - 具有 16 GB 内存的 Windows 11 机器 - 100 GB 可用磁盘空间 - [VMware Workstation Player](https://www.vmware.com/products/workstation-player.html) (免费) - [Microsoft Azure 免费账户](https://azure.microsoft.com/free/) **克隆并阅读:** ``` git clone https://github.com/OthmaneBenmezian/SOC-SOAR-Lab.git cd SOC-SOAR-Lab cat docs/setup-guide.md ``` **虚拟机设置概览:** ``` VM 1 — Ubuntu 22.04 Server RAM : 6 GB Disk : 50 GB Network: VMnet8 (NAT) Runs : Wazuh + Shuffle + TheHive (Docker) VM 2 — Windows 10 RAM : 3 GB Disk : 30 GB Network: VMnet8 (NAT) Runs : Sysmon + Winlogbeat + Atomic Red Team ``` ## 安全声明 ## 作者 **Othmane Benmezian** 网络安全分析师 — 蓝队 [![LinkedIn](https://img.shields.io/badge/LinkedIn-Connect-0077B5?style=flat-square&logo=linkedin)](https://linkedin.com/in/othmane-benmezian-685a1b353) [![GitHub](https://img.shields.io/badge/GitHub-Follow-181717?style=flat-square&logo=github)](https://github.com/BenmezOthmane) ## 许可证 本项目基于 MIT 许可证授权 — 详见 [`LICENSE`](./LICENSE)。
标签:AMSI绕过, Azure, Azure Logic Apps, Azure免费层, Cloudflare, IP 地址批量处理, Microsoft Sentinel, MITRE ATT&CK, OISF, Shuffle, SOAR, VMware, Wazuh, Windows 10, 企业级安全架构, 备份与恢复, 威胁检测, 安全实验室, 安全运营中心, 应用安全, 插件系统, 攻击模拟, 无线安全, 日志管理, 本地部署, 混合SOC实验室, 红队行动, 网络安全, 网络映射, 自动化防御, 虚拟化, 请求拦截, 逆向工具, 隐私保护, 驱动签名利用