olawale-sec/home-soc-lab
GitHub: olawale-sec/home-soc-lab
该项目搭建了一个五虚拟机家庭 SOC 实验环境,结合 Splunk SIEM 与 Security Onion 实现威胁检测、事件响应和安全运营实战演练。
Stars: 0 | Forks: 0
# 🔬 家庭安全运营实验室
[](https://splunk.com)
[](https://kali.org)
[](#)
## 🧱 实验室架构
```
┌─────────────────────────────────────────────────────────┐
│ VirtualBox Host │
│ │
│ ┌──────────────┐ ┌──────────────┐ │
│ │ Kali Linux │ │ Windows │ │
│ │ (Attacker) │───▶│ Server 2019 │ │
│ └──────────────┘ │ (Target/AD) │ │
│ └──────┬───────┘ │
│ ┌──────────────┐ │ │
│ │ Ubuntu │ │ logs │
│ │ (Splunk SIEM)│◀──────────┘ │
│ └──────────────┘ │
│ ┌──────────────┐ ┌──────────────┐ │
│ │ Metasploit- │ │ Security │ │
│ │ able (Target)│ │ Onion (IDS) │ │
│ └──────────────┘ └──────────────┘ │
└─────────────────────────────────────────────────────────┘
```
## 🖥️ 虚拟机配置
| 虚拟机 | 操作系统 | 角色 | 内存 |
|---|---|---|---|
| VM1 | Kali Linux 2024 | 攻击者 / 渗透测试 | 4GB |
| VM2 | Windows Server 2019 | 目标 / Active Directory | 4GB |
| VM3 | Ubuntu 22.04 | Splunk SIEM | 6GB |
| VM4 | Metasploitable 2 | 漏洞目标 | 1GB |
| VM5 | Security Onion | 网络 IDS | 4GB |
## 🎯 模拟的攻击场景
### 1. 暴力破解攻击
- **工具:** Kali Linux 上的 Hydra
- **目标:** Windows Server RDP / SSH
- **检测:** Splunk 对 60 秒内 5 次以上失败登录的告警
### 2. 端口扫描与侦察
- **工具:** Nmap
- **目标:** Metasploitable
- **检测:** 触发 Security Onion 的 Snort 规则
### 3. ARP 投毒 (MITM)
- **工具:** Arpspoof + Ettercap
- **检测:** Wireshark 流量异常,Splunk 网络日志告警
### 4. 钓鱼模拟
- **工具:** Social Engineering Toolkit (SET)
- **检测:** 在 Splunk 中进行邮件网关日志分析
## 📊 Splunk 检测规则
```
# 暴力破解检测
index=windows_logs EventCode=4625
| stats count by src_ip, user
| where count > 5
| eval alert="Possible Brute Force"
# Port Scan 检测
index=network_logs
| stats count by src_ip, dest_port
| where count > 50
| eval alert="Port Scan Detected"
# Privilege Escalation
index=windows_logs EventCode=4672
| where Account_Name!="SYSTEM"
| eval alert="Suspicious Privilege Escalation"
```
## 📁 仓库结构
```
home-soc-lab/
├── configs/
│ ├── splunk-alerts/ # Saved search configs
│ └── snort-rules/ # Custom IDS rules
├── attack-scenarios/
│ ├── brute-force/
│ ├── port-scanning/
│ └── arp-poisoning/
├── incident-reports/ # Full IR writeups
├── screenshots/ # Lab evidence
└── README.md
```
## 📋 事件报告
| # | 场景 | 严重程度 | 检测时间 | 解决方案 |
|---|---|---|---|---|
| IR-001 | RDP 暴力破解 | 高 | 2 分钟 | 封禁 IP,重置凭证 |
| IR-002 | 端口扫描 | 中 | 5 分钟 | 在 SIEM 中标记 |
| IR-003 | ARP 投毒 | 高 | 8 分钟 | 网络隔离 |
| IR-004 | 恶意软件执行 | 严重 | 3 分钟 | 隔离 Endpoint |
## 🔧 设置指南
```
# 1. 安装 VirtualBox
sudo apt install virtualbox
# 2. 下载 Splunk(在 targets 上安装 Universal Forwarder)
wget -O splunk.tgz "https://download.splunk.com/..."
# 3. 配置 log forwarding
# 在每个 target 上添加到 inputs.conf:
[WinEventLog://Security]
index = windows_logs
disabled = false
```
*我的网络安全作品集的一部分 — [olawale-sec.github.io](https://olawale-sec.github.io)*
标签:CTI, 安全运营, 库, 应急响应, 扫描框架, 红队行动, 网络安全实验, 虚拟化实验环境