Etienne-Moreau1/kql-sentinel-queries

GitHub: Etienne-Moreau1/kql-sentinel-queries

为 Microsoft Sentinel 精心整理的 KQL 查询集合,覆盖身份攻击、威胁情报、端点检测和事件响应等安全运营场景。

Stars: 0 | Forks: 0

# 🛡️ KQL Sentinel 查询 一个为 Microsoft Sentinel 精心整理的 KQL (Kusto Query Language) 查询集合,专注于威胁检测、事件响应和安全运营。 基于真实的 SOC 经验和 Microsoft SC-200 认证备考构建。 ## 👤 关于 **Etienne Moreau** | 支持中心团队负责人 → 有志成为 SOC Analyst 📜 SC-200 | SC-900 | MS-900 | AZ-900 | Security+ | Network+ 🔄 SC-300 准备中 🌐 法/英 双语 | 加拿大,魁北克 [![LinkedIn](https://img.shields.io/badge/LinkedIn-Connect-blue)](https://www.linkedin.com/in/etienne-moreau-136642a9/) ## 📁 仓库结构 kql-sentinel-queries/ ├── identity-attacks/ │ ├── brute-force.kql │ ├── password-spray.kql │ ├── impossible-travel.kql │ └── golden-ticket.kql ├── threat-intelligence/ │ ├── malicious-ip-correlation.kql │ └── threat-intel-signin.kql ├── endpoint/ │ ├── suspicious-process.kql │ └── lateral-movement.kql └── incident-response/ └── aitm-detection.kql ## 🔍 查询分类 ### 🔐 身份攻击 针对 Azure AD / Microsoft Entra ID 的常见基于身份的攻击检测规则。 | 查询 | 描述 | MITRE 战术 | |-------|-------------|--------------| | brute-force.kql | 检测每个用户每小时超过 10 次的失败登录尝试 | Credential Access | | password-spray.kql | 识别针对多个账户且登录失败的 IP | Credential Access | | impossible-travel.kql | 标记在 1 小时内来自 2 个或以上国家/地区的登录 | Initial Access | | golden-ticket.kql | 检测异常的 Kerberos 票据使用情况 | Lateral Movement | ### 🌐 威胁情报 将日志与威胁情报指标进行匹配的关联查询。 | 查询 | 描述 | MITRE 战术 | |-------|-------------|--------------| | malicious-ip-correlation.kql | 将 SigninLogs 与 ThreatIntelligenceIndicator 进行交叉引用 | Initial Access | | threat-intel-signin.kql | 检测来自已知恶意 IP 的登录 | Initial Access | ### 💻 端点 通过 Microsoft Defender for Endpoint 检测设备可疑活动的规则。 | 查询 | 描述 | MITRE 战术 | |-------|-------------|--------------| | suspicious-process.kql | 检测由 Office 应用程序生成的子进程 | Execution | | lateral-movement.kql | 识别 Pass-the-Hash 和横向移动模式 | Lateral Movement | ### 🚨 事件响应 专为主动事件调查和威胁狩猎设计的查询。 | 查询 | 描述 | |-------|-------------| | aitm-detection.kql | 检测 Adversary-in-the-Middle 钓鱼 token 窃取 | ## 🚀 如何使用 1. 打开 **Microsoft Sentinel** 或 **Azure Log Analytics** 2. 导航至 **Logs** 3. 复制并粘贴任意 `.kql` 文件内容 4. 根据您的环境需要,调整时间范围和阈值 ## 📌 示例查询 — 密码喷射检测 ``` SigninLogs | where TimeGenerated > ago(2h) | where ResultType != 0 | summarize DistinctUserCount = dcount(UserPrincipalName), TargetedUsers = make_set(UserPrincipalName) by IPAddress | where DistinctUserCount > 10 | sort by DistinctUserCount desc ``` ## 🛠️ 工具与技术 ![Microsoft Sentinel](https://img.shields.io/badge/Microsoft%20Sentinel-0078D4?style=flat&logo=microsoft&logoColor=white) ![KQL](https://img.shields.io/badge/KQL-Kusto%20Query%20Language-blue) ![Azure](https://img.shields.io/badge/Azure-0078D4?style=flat&logo=microsoft-azure&logoColor=white) ![Defender XDR](https://img.shields.io/badge/Defender%20XDR-00B4D8?style=flat&logo=microsoft&logoColor=white) ## 📈 路线图 - [x] 身份攻击查询 - [x] 威胁情报关联 - [x] 端点检测查询 - [ ] Workbook 模板 - [ ] Automation 规则模板 - [ ] PowerShell IR 脚本 ## 📄 许可证 MIT 许可证 — 欢迎注明出处后自由使用、修改和分享。
标签:AMSI绕过, KQL, Microsoft Sentinel, Modbus, 威胁检测, 安全运营, 扫描框架, 红队行动