iagosantosengineer-ship-it/ip-threat-analyzer

GitHub: iagosantosengineer-ship-it/ip-threat-analyzer

一款面向蓝队与 SOC 的混合 IP 威胁分析工具,结合威胁情报与启发式算法对 IP 地址进行多维度的风险评估与分类。

Stars: 0 | Forks: 0

# 🔍 混合 IP 威胁检测器 一款使用 Python 开发的 **Blue Team** 工具,利用 **Threat Intelligence + 本地启发式分析** 对 IP 地址进行分析和分类。 ## 🧠 目标 本项目模拟 SOC 环境中的真实分析流程,支持: * IP 富化(主机名 / 反向 DNS) * 针对 Threat Intelligence 源的检查 * 基于分数的分类 * 生成结构化日志(NDJSON) ## ⚙️ 功能 * 🔍 **通过 CLI 手动输入 IP** * 🌐 **使用反向 DNS 进行富化** * 🚫 **通过黑名单检测(Feodo Tracker)** * 🧠 **用于识别可疑行为(例如:TOR)的启发式分析** * 📊 **评分和分类系统(BENIGN / SUSPICIOUS / MALICIOUS)** * 🧾 **格式化的 JSON 输出** * 📁 **NDJSON 格式的日志(兼容 SIEM)** ## 🏗️ 架构 ``` ip_checker/ │ ├── main.py ├── blacklist.txt │ ├── core/ │ ├── enrichment.py │ ├── detection.py │ └── scoring.py │ ├── utils/ │ └── logger.py ``` ## 🚀 如何使用 ### 1. 克隆仓库 ``` git clone https://github.com/iagosantosengineer-ship-it/ip-threat-analyzer.git cd ip-threat-analyzer ``` ### 2. 创建虚拟环境 ``` python -m venv venv venv\Scripts\activate ``` ### 3. 安装依赖 ``` pip install -r requirements.txt ``` ### 4. 执行 ``` python main.py ``` ## 📸 使用示例 ### 🔴 可疑 IP(TOR) ``` IP: 185.220.101.1 Hostname: berlin01.tor-exit.artikel10.org Blacklist: NAO Score: 50 Classificação: SUSPICIOUS Motivo: Tor exit node detected (anonymization network) ``` ### 🟢 良性 IP ``` IP: 8.8.8.8 Hostname: dns.google Blacklist: NAO Score: 0 Classificação: BENIGN Motivo: No indicators of compromise detected ``` ## 📊 JSON 示例(输出) ``` { "ip": "185.220.101.1", "hostname": "berlin01.tor-exit.artikel10.org", "blacklisted": false, "score": 50, "classification": "SUSPICIOUS", "reason": "Tor exit node detected (anonymization network)", "timestamp": "2026-03-21 10:58:11" } ``` ## 📁 日志(NDJSON) 事件以 **NDJSON(换行符分隔的 JSON)** 格式存储: ``` {"ip":"185.220.101.1","score":50,"classification":"SUSPICIOUS"} {"ip":"8.8.8.8","score":0,"classification":"BENIGN"} ``` 此格式广泛用于: * SIEM(Splunk, ELK) * 安全 pipeline * 大规模日志摄入 ## 🧠 检测逻辑 评分基于: * 黑名单中的存在情况(Threat Intelligence) * 缺少主机名(弱指标) * TOR 网络识别(高风险) ## 🔒 注意事项 * 并非所有恶意 IP 都在黑名单中 * 启发式分析是对 Threat Intelligence 的补充 * 该工具模拟真实的 SOC 分析 pipeline ## 📌 后续步骤(路线图) * [ ] 支持多个 IP * [ ] 集成 Windows 日志(事件 5156) * [ ] 集成 BlueSentinel 项目 * [ ] 多个 Threat Intelligence 源 ## 👨‍💻 作者 Iago Dos Santos 该项目专注于 **Blue Team / SOC Analyst**。 ## ⭐ 贡献 欢迎随时贡献或提出改进建议。
标签:AMSI绕过, DNS 反查, IP 分析, IP 地址批量处理, NDJSON, Python, SIEM 日志, TOR 检测, 启发式分析, 威胁情报, 威胁检测, 子域枚举, 密码管理, 开发者工具, 恶意评分, 情报丰富, 文档结构分析, 无后门, 网络安全, 逆向工具, 防御绕过, 隐私保护, 黑名单检测