Skip to content
OnlyProjects
BCA · Cyber SecurityFor educational purposes only
Code included

Suricata IDS Baseline Tuning & Alert-Triage Dashboard for a College Lab Network (Python/MySQL)

Baseline a Suricata sensor on your own lab network, cut the false positives, and prove every tuning decision with before/after numbers

Mapped to your syllabusUniversity of Madras CBCS 2023-24 · 320S61 Mini Project (Professional Competency Skill) · Semester 6

Overview

1 min read

LabNet Sentry is an advanced, measurement-driven study of an intrusion detection system in a college teaching lab — deployed, baselined, tuned and re-tested on lab-owned virtual machines, with written permission and an instructor present for the controlled test traffic.

A Suricata sensor on an Ubuntu gateway VM watches the isolated lab segment; week one captures a baseline of what a default ruleset shouts on ordinary lab traffic (student browsing, lab exercises, software updates). Because every byte of test traffic in the lab is generated by the student, every alert can be labelled honestly — the expected scan alerts during the controlled window are true positives, everything else is noise — turning "false positive" from an opinion into a measurable ratio.

A Python pipeline tails Suricata's eve.json and batch-inserts alerts into MySQL (with rule and host dimension tables); a Flask dashboard shows alert volume, top rules, top talkers and the false-positive ratio before and after tuning. The tuning workbench applies the three standard levers from NIST SP 800-94 — thresholds, suppressions and rule selection — each versioned and reversible, and never a rule deletion that silently drops detection coverage.

The final deliverable is a before/after table proving noise fell, coverage held (a controlled port scan between lab VMs still fires the same signatures), and every suppressed rule is justified in writing. Python, MySQL, web technology and data-structures work map onto the University of Madras CBCS courses; Suricata and Wireshark are standard, legal, lab-safe tooling for defensive monitoring.

Relevant for
Tamil Nadu
Level
Advanced · 6 weeks · solo
Common at
University of Madras, Bharathiar University, University of Kerala
Updated
Nov 2026

Syllabus alignment

University of Madras · CBCS 2023-24

320S61 · Mini Project (Professional Competency Skill) · Semester 6 · 2 credits · 40 + 60

Subjects this project applies
  • 120C1A Python
  • 320C5B RDBMS
  • 320C5C Web Technology
  • 220C3A Data Structures
How it is evaluated

See your department's project guidelines.

Also fits: Bharathiar University 2023-24, Kerala University FYUGP 2024, GGSIPU 4-year BCA 2024.

What's in the box

11 parts · 5 free · 2 previewed · 4 unlock for ₹2,000

Problem & synopsis

6 min read

Problem statement

College teaching labs generate exactly the traffic that makes a default IDS unusable: scanner exercises, packet-crafting assignments, DHCP churn and broadcast storms, all on flat subnets. Deploy a stock Suricata ruleset there and it produces thousands of alerts a day, almost none of which are real incidents — and an alert stream nobody reads is worse than no sensor, because it creates the appearance of monitoring without the substance. The literature and NIST SP 800-94 agree that IDPS tuning is essential, yet it is almost never taught: students learn rule syntax but not how to baseline a network, classify alerts against ground truth, or prove that a tuning change did not silently destroy detection coverage. The college needs a repeatable, measurable tuning procedure for its own lab network — one that captures a baseline, labels alerts against controlled test traffic, reduces the false-positive ratio with versioned, reversible changes, and verifies after every pass that the signatures that matter still fire.

Synopsis

Abstract

An intrusion detection system (IDS) is only as useful as its signal: an untuned sensor buries real events under thousands of false alarms — most IDS deployments fail from noise, not from missing signatures. This project runs the full deploy → baseline → tune → verify lifecycle on a Suricata sensor guarding a realistic fictional college teaching lab (Cauvery Institute of Technology), with every claim reported as a before/after measurement.

Introduction

CERT-In's advisories ask institutions to detect and monitor, but a college lab is hostile to a default IDS: packet-crafting exercises, DHCP churn, broadcast traffic and vulnerability-scanner labs all look exactly like attacks. The result is the classic failure NIST SP 800-94 warns about: analysts drown in alerts and stop reading them. Tuning is not an optional chore; it is the core operational skill of defensive monitoring.

Existing System

  • The lab has no sensor at all: incidents are discovered by accident, if at all.
  • Where an IDS is demonstrated in class, it runs on default settings for one lecture and is switched off — nothing baselined, nothing measured.
  • Security teaching covers signature syntax but not operations: nobody shows students how to judge a true positive or reduce noise without losing coverage.
  • Limitations: no baseline traffic profile, no alert archive, no metrics, no defensible tuning policy.

Proposed System

  • An isolated lab deployment: Suricata on an Ubuntu gateway VM inspecting only the lab segment — no personal devices, no production network, and a signed permission note.
  • A one-week baseline of stock-ruleset alerts on unmodified traffic: alerts per hour, unique signature IDs, top talkers.
  • A ground-truth labelling scheme made possible by the closed lab: every alert is expected (it fires during controlled scan windows between two lab VMs) or unexpected, so the false-positive ratio FP / (TP + FP) is computed, not guessed.
  • A Python ingestion pipeline that tails eve.json and batch-inserts events into MySQL with rule and host dimension tables.
  • A Flask triage dashboard: alert volume, top rules, top talkers, FP ratio per iteration, CSV export.
  • A tuning workbench applying thresholds, suppressions and rule selection — versioned, reversible changes, never deleting a rule the verification scan proves still needed.
  • Controlled verification after each pass: a documented port scan and a benign replay rerun; detection coverage must hold while noise falls.

Feasibility Study

  • Technical: Suricata, Wireshark, Python 3, MySQL and Flask are free and run on one lab PC with two VMs; the event pipeline is plain JSON parsing — a data-structures exercise, not a research problem. Everything maps to CBCS courses: Python (120C1A), RDBMS (320C5B), Web Technology (320C5C), Data Structures (220C3A).
  • Economic: ₹0 licence cost; the lab hardware already exists.
  • Operational & legal: the sensor watches only lab-owned VMs on an isolated segment, test traffic runs with the instructor's knowledge, and the report carries a signed permission note — defensible because its boundaries are written down.

Objectives

  1. 01Deploy a Suricata sensor on an Ubuntu gateway VM that inspects only the isolated college lab segment, with HOME_NET and interfaces correctly scoped and documented.
  2. 02Capture a one-week baseline of stock-ruleset alerts on ordinary lab traffic and produce a noise profile: alerts per hour, unique signature IDs, top rules and top talkers.
  3. 03Build a Python pipeline that tails eve.json, parses every event and batch-inserts alerts into MySQL with rule and host dimension tables.
  4. 04Label every alert as expected or unexpected against the controlled traffic calendar, and compute the false-positive ratio FP / (TP + FP) per tuning iteration.
  5. 05Apply versioned, reversible tuning changes — thresholds, suppressions and rule selection — and record the justification for each suppressed or thresholded signature.
  6. 06Build a Flask dashboard showing alert volume, top rules, top talkers and FP-ratio trend across iterations, with CSV export.
  7. 07Verify after each pass that detection coverage holds: the controlled port scan and benign replay must trigger the same signature set as the baseline.
  8. 08Document the whole procedure as a repeatable runbook the lab can re-use every semester.

Scope

In scope

  • One isolated lab segment (two VMs plus the gateway sensor); no production or personal devices.
  • Baseline capture, alert labelling, FP-ratio computation, three tuning iterations, verification scans.
  • Python ingestion pipeline, MySQL alert store with dimensions, Flask triage dashboard, CSV export.
  • Controlled test traffic: a documented port scan between two lab VMs and a benign traffic replay, run with the instructor present.
  • Versioned Suricata configuration and rules with an undo path; a written runbook.

Out of scope (v1)

  • Inline prevention (IPS mode with drops) — the sensor stays detect-only; dropping packets in a teaching lab breaks the lab itself.
  • TLS-inspection or deep payload analysis; encrypted traffic is treated as metadata (flows, TLS handshake fields).
  • Multi-sensor or multi-campus deployment, and any link to the college's real network operations.
  • Machine-learning alert classification (listed as future scope); the labelling here is rule-based and calendar-driven by design.
  • Real-time paging or mobile alerts — the dashboard is intentionally post-hoc triage.

Methodology

The study follows a six-week iterative, measurement-driven loop structured around the IDPS lifecycle in NIST SP 800-94 (deploy → baseline → tune → verify), with each iteration closing on numbers rather than impressions.

WeekPhaseActivitiesDeliverable
1Deploy & baselineInstall Suricata on the gateway VM; scope HOME_NET; capture 5 days of stock-ruleset alerts; profile noiseBaseline report: alerts/hour, unique SIDs, top rules
2Profile & labelBuild ingestion pipeline into MySQL; label every baseline alert expected/unexpected against the traffic calendarLabelled alert corpus + FP ratio for the stock ruleset
3Tune I — scope & thresholdsCorrect HOME_NET, add threshold and rate-filter entries for the noisiest 10 signatures; version the configTuning change log v1 + re-measured FP ratio
4Tune II — suppressionsSuppress signatures that fire only on legitimate lab tooling, each with a written justification; keep a revert pathTuning change log v2 + FP ratio
5Verify & dashboardControlled port scan + benign replay; assert expected signatures still fire; complete the Flask dashboardCoverage verification table + working dashboard
6Evaluate & documentFinal before/after comparison, runbook, report and viva packResults chapter + repeatable runbook

Measurement discipline: every claim in the report cites a query against the alert store (for example, "alerts/hour fell from 1,842 to 210 while the scan signatures in the verification table still fired"), and the numbers the student reports are their own run's values — the runbook shows exactly how to reproduce them. Testing approach: golden-file tests for the JSON parser (valid, malformed and truncated lines), a fixed replay capture whose expected alert counts are asserted, integration tests for batch inserts, and a manual black-box pass over every dashboard view.

Architecture & tech stack

3 diagrams · 6 technologies · 2 min read

  • Python 3
  • Suricata (IDS)
  • MySQL
  • Flask
  • HTML/CSS/JavaScript
  • Wireshark

LabNet Sentry has four parts: the sensor, the pipeline, the store and the dashboard — plus the tuning workbench that acts on the sensor.

  1. Sensor — Suricata on an Ubuntu 22.04 gateway VM, running in IDS mode on the lab-facing interface, with eve.json as its single output and HOME_NET scoped to the lab subnet.
  2. Pipeline — a Python 3 ingestor tails eve.json (handling rotation and truncated lines), filters for alert events, enriches each with the rule message and host labels, and flushes batch inserts to MySQL every five seconds inside one transaction.
  3. Store — MySQL 8 with a fact table of alerts and two dimension tables (rules, hosts), a traffic-calendar table for labelling, and a tuning-change table recording every configuration edit.
  4. Dashboard — Flask serving HTML/CSS/JavaScript with charts (volume over time, top rules, FP-ratio trend) and CSV export; the tuning workbench writes versioned config snapshots with an undo command.
  5. Controlled traffic generator — a documented script that runs the port scan and benign replay between lab VMs and stamps the calendar, making labelling mechanical.
flowchart LR
  LM["Lab VMs (isolated segment)"] -->|"mirrored traffic"| SEN["Suricata sensor on Ubuntu gateway VM"]
  SEN -->|"eve.json"| ING["Python ingestor: tail, parse, batch"]
  CTG["Controlled traffic generator: scan + benign replay"] --> LM
  CTG -->|"stamps window"| CAL[("traffic calendar")]
  ING --> DB[("MySQL 8: alerts, rules, hosts, changes")]
  LAB["Labelling job: expected vs unexpected"] --> DB
  TW["Tuning workbench: thresholds, suppressions (versioned)"] -->|"config snapshots"| SEN
  DB --> DASH["Flask dashboard + CSV export"]

ER diagram

erDiagram
  RULE_DIM ||--o{ ALERT : "classifies"
  HOST_DIM ||--o{ ALERT : "is source or dest of"
  ALERT }o--|| TEST_WINDOW : "falls in"
  TUNING_CHANGE ||--o{ ALERT : "precedes"

  ALERT {
    int id PK
    datetime timestamp
    string sid FK
    string srcIp FK
    string destIp FK
    string category
    bool expected
  }
  RULE_DIM {
    string sid PK
    string message
    string category
    bool active
  }
  HOST_DIM {
    string ip PK
    string role
    bool labOwned
  }
  TEST_WINDOW {
    int id PK
    datetime startAt
    datetime endAt
    string trafficType
  }
  TUNING_CHANGE {
    int id PK
    datetime appliedAt
    string changeType
    string targetSid
    string justification
  }

Study design

flowchart TD
  A["Deploy sensor, scope HOME_NET"] --> B["Baseline: 5 days stock ruleset"]
  B --> C["Label alerts via traffic calendar"]
  C --> D["Tune I: scope + thresholds"]
  D --> E["Verify: controlled scan still fires"]
  E --> F["Tune II: justified suppressions"]
  F --> G["Verify again + measure FP ratio"]
  G --> H["Dashboard, results, runbook"]

The FP ratio after each iteration is a single SQL join: alerts inside a test window count as expected; everything outside it counts as unexpected, and the ratio unexpected / total becomes the noise metric the report tracks from baseline to final.

Modules

6 modules

  1. Module 01

    Sensor Deployment & Baseline Capture

    Installs and scopes Suricata: the lab-facing interface, HOME_NET set to the lab subnet and no more, eve.json output with alert and flow records, and log rotation. The baseline phase runs the stock ruleset for five days and produces the noise profile — alerts per hour, unique signature IDs, top ten rules — using SQL queries against the store, so every number in the report has a query behind it.

  2. Module 02

    Alert Ingestion Pipeline

    A Python 3 ingestor that tails eve.json, tolerating log rotation and half-written lines by tracking byte offsets and skipping malformed records into a dead-letter file. Alert events are enriched with the rule message from RULE_DIM and host labels from HOST_DIM, then flushed to MySQL in batches of 500 inside a single transaction, keeping insertion cost trivial even at thousands of alerts per hour.

  3. Module 03

    Labelling & Metrics Engine

    Marks each alert expected or unexpected by joining its timestamp against TEST_WINDOW — the calendar the controlled traffic generator stamps for every scan and replay. It then computes the metrics per tuning iteration: alerts/hour, unique SIDs, expected/unexpected counts and the false-positive ratio unexpected / total. Hash maps built during the data-structures coursework make the per-SID counting a single pass.

  4. Module 04

    Tuning Workbench

    Applies the three levers from NIST SP 800-94 in order of preference: threshold and rate-filter entries for bursty-but-legitimate traffic, suppressions for signatures that fire only on known lab tooling, and rule selection to disable categories the lab does not need. Every change is a row in TUNING_CHANGE with a justification string, a config snapshot and an undo command — no signature is ever deleted outright.

  5. Module 05

    Verification Harness

    A scripted check that runs after each tuning pass: the controlled port scan between the two lab VMs and the benign traffic replay execute inside stamped windows, and the harness asserts that the expected signature set — the scan-detection SIDs — still fires while the noise metrics improve. This is the module that makes the tuning defensible: coverage is proven, not assumed.

  6. Module 06

    Triage Dashboard & Reports

    A Flask application serving the triage views: alert volume over time with test windows shaded, top rules and top talkers, per-iteration FP-ratio trend, and a drill-down from any chart to the underlying alerts. Every view exports CSV, and the results chapter's before/after tables are generated directly from these exports so the report and the dashboard can never disagree.

Slides

12 slides · titles free · bullets, notes and the .pptx unlock

  1. Slide 1

    LabNet Sentry — Suricata IDS Baseline Tuning & Alert-Triage Dashboard

  2. Slide 2

    The Problem: A Sensor Nobody Reads

  3. Slide 3

    Why This Is Possible Ethically

  4. Slide 4

    Proposed Study

  5. Slide 5

    Objectives

  6. Slide 6

    Lab Environment & Architecture

  7. Slide 7

    Database Design

  8. Slide 8

    The Tuning Loop

  9. Slide 9

    Demo

  10. Slide 10

    Results (Before / After)

  11. Slide 11

    Testing & Reproducibility

  12. Slide 12

    Conclusion & Future Scope

Bullets, speaker notes and the .pptx · ₹2,000

The titles above are the real outline. The rest is what you present from.

Unlock for ₹2,000

Viva questions & answers

3 of 17 answered free · 14 unlock

Read each answer, close it, and say it in your own words. Your viva will ask. Now you'll know.

  1. 01Concept

    What is the difference between signature-based and anomaly-based detection, and which does Suricata use?

    Signature-based detection matches traffic against known patterns written as rules, so it is precise and explainable but blind to genuinely novel behaviour; anomaly-based detection models what normal looks like and flags deviations, catching the unknown but generating more false positives. Suricata is primarily signature-based with a large community ruleset, which is exactly why my project concentrates on tuning: the signatures are good, but their noise on a specific network must be measured and managed.

  2. 02Concept

    What is eve.json and why did you build the pipeline around it?

    Eve.json is Suricata's structured JSON event log — one record per event, with alert, flow, TLS and other record types, each self-describing with timestamps and metadata. I built the pipeline on it because parsing structured JSON is far more reliable than screen-scraping the fast.log text format: the fields I need for the store (signature ID, source, destination, timestamp) are typed, stable and documented in the Suricata manual.

  3. 03Concept

    IDS or IPS — why did you run Suricata in detection-only mode?

    An IPS sits inline and can drop or reject packets; an IDS observes a copy and only alerts. In a teaching lab, prevention mode would break the very exercises the lab exists for — a dropped scan assignment looks identical to a network fault — and inline placement adds a single point of failure. Detection-only also keeps the ethics simple: the sensor records, it never interferes, and my verification harness needs alerts, not blocks.

+14 more questions, with answers

Try the free ones out loud first. Your examiner will not accept “it's in the PPT”.

Source code & how to run

7 steps · complete source code · unlocks with the project

Unlocks with the project · ₹2,000

7 steps · source code zip

Prerequisites, install, seed data and tests, written for demo day. Plus the complete source.

Unlock for ₹2,000

READMEFIRST

277 words · unlocks with the project

What to change before it goes anywhere near a submission. Skipping it is how the demo fails live.

Unlocks with the project · ₹2,000

277 words · ~1 min read

The checklist of things to rename, re-seed and re-think so the project reads as yours.

Unlock for ₹2,000

Instructions

377 words · unlocks with the project

How to study it, adapt it and walk your examiner through it, step by step.

Unlocks with the project · ₹2,000

377 words · ~2 min read

Report structure, formatting rules and the submission checklist your department will grade.

Unlock for ₹2,000

References

10 sources

  1. NIST Special Publication 800-94 — Guide to Intrusion Detection and Prevention Systems (IDPS)
  2. Suricata User Guide (official documentation)
  3. Suricata — Eve JSON output documentation
  4. Snort — the reference open-source IDS/IPS and ruleset ecosystem
  5. Wireshark — official documentation and user guide
  6. Flask — official documentation
  7. MySQL 8.0 Reference Manual
  8. Indian Computer Emergency Response Team (CERT-In) — advisories and guidelines
  9. Richard Bejtlich, The Practice of Network Security Monitoring: Understanding Incident Detection and Response, No Starch Press, 2013
  10. Michael S. Collins, Network Security Through Data Analysis, 2nd ed., O'Reilly Media, 2017

Cite this bundle

OnlyProjects. (2026). Suricata IDS Baseline Tuning & Alert-Triage Dashboard for a College Lab Network (Python/MySQL): BCA Cyber Security project bundle [Educational resource]. https://onlyprojects.online/projects/bca-cyber-suricata-ids-tuning-lab-network

Future scope

1 min read

  • Anomaly-assisted labelling: a lightweight statistical model that flags alerts whose features deviate from the labelled history, reducing manual labelling as the corpus grows.
  • Grafana front-end over the same MySQL store for labs that want an operations-grade view alongside the teaching dashboard.
  • Multi-sensor federation: a second sensor on the hostel-lab segment with cross-sensor correlation in the store.
  • TLS metadata triage: SNI/JA3-style fingerprint fields from Suricata's TLS records added to the host dimensions for encrypted-traffic awareness without decryption.
  • Semester-over-semester comparison: archived baselines that let the lab show whether its traffic profile and tuning hold across student batches.
  • Campus SOC bridge: a documented, permissioned export of the tuned ruleset and FP-ratio history to the college's real IT team, closing the loop between teaching and operations.

Keep browsing

Same degree, same syllabus slot, different idea. Pick the one your guide will actually approve.

BCACode included

Web Development

Smart Hostel Management System

Room allocation, complaints and mess billing without the register

  • Next.js
  • TypeScript
  • Node.js
  • +3

intermediate8 wk2 students