7Bharanidaran/Custom-Network-IDS-Using-Suricata

GitHub: 7Bharanidaran/Custom-Network-IDS-Using-Suricata

一个基于 Suricata 的自定义网络入侵检测系统,通过自定义规则检测 ICMP、HTTP 和 SSH 流量并生成告警日志。

Stars: 0 | Forks: 0

# 使用 Suricata 的自定义网络 IDS ## 概述 本项目演示了如何在 Kali Linux 上使用 Suricata 8.0.5 实现自定义的网络入侵检测系统 (IDS)。通过创建自定义规则来监控和检测 ICMP、HTTP 和 SSH 流量,并通过 Suricata 日志生成和分析警报。 ## 目标 * 了解入侵检测系统 (IDS) 的基础知识。 * 部署和配置 Suricata。 * 创建自定义检测规则。 * 生成网络流量并观察警报。 * 分析 Suricata 生成的日志。 ## 使用的工具 * Kali Linux * Suricata 8.0.5 * Ping * Curl * SSH * Nano Editor ## 自定义规则 ### ICMP 检测 ``` alert icmp any any -> any any (msg:"ICMP Ping Detected"; sid:1000001; rev:1;) ``` ### SSH 检测 ``` alert tcp any any -> any 22 (msg:"SSH Connection Detected"; sid:1000002; rev:1;) ``` ### HTTP 检测 ``` alert http any any -> any any (msg:"HTTP Request Detected"; sid:1000003; rev:1;) ``` ## 流量生成 ### ICMP 流量 ``` ping 8.8.8.8 ``` ### HTTP 流量 ``` curl http://example.com ``` ### SSH 流量 ``` ssh localhost ``` ## 结果 Suricata 成功检测到了: * ICMP Ping 流量 * HTTP 请求 * SSH 连接 警报被记录在: ``` /var/log/suricata/fast.log ``` 示例警报: ``` [**] [1:1000001:1] ICMP Ping Detected [**] [**] [1:1000003:1] HTTP Request Detected [**] ``` ## 项目结构 ``` Custom-Network-IDS-Using-Suricata │ ├── README.md ├── rules │ └── local.rules ├── screenshots │ ├── 01_suricata_installed.png │ ├── 02_custom_rules.png │ ├── 03_configuration_test.png │ ├── 04_suricata_running.png │ └── 05_alerts_generated.png ``` ## 结论 本项目演示了如何使用 Suricata 作为网络入侵检测系统 (IDS) 来监控网络流量。成功实现了自定义规则以检测 ICMP、HTTP 和 SSH 活动,提供了使用行业标准网络安全工具的实践经验。
标签:Metaprompt, Suricata, 入侵检测系统, 安全数据湖, 现代安全运营, 网络安全, 网络流量分析, 隐私保护