Hereβs a professional README.md for your Insider Threat Monitor project. It includes:
- π Installation Steps
- πββοΈ How to Run
- βοΈ Dependencies
- πΌοΈ Screenshots with Descriptions
- π οΈ Code Customization Guide
# Insider Threat Monitor
> **Detect and analyze insider threats in real-time using Windows Event Logs (`.evtx`).**
This tool parses `.evtx` files, detects suspicious activities, and provides a web-based dashboard for monitoring login patterns, critical events, and detected threats.
---
## π Table of Contents
1. [Overview](#overview)
2. [Installation](#installation)
3. [How to Run](#how-to-run)
4. [Dependencies](#dependencies)
5. [Screenshots](#screenshots)
6. [Customization](#customization)
---
## π― Overview
The **Insider Threat Monitor** is designed to:
- Parse Windows Security Event Logs (`security.evtx`).
- Detect suspicious activities like after-hours logins, mass file access, and USB device usage.
- Provide a user-friendly dashboard with real-time alerts and analytics.
### Key Features:
- π **Authentication**: Secure admin login with default credentials (`admin / admin123`).
- π **Dashboard**: Real-time stats and charts.
- π¨ **Alerts**: Detailed list of detected threats.
- π **Live Feed**: Real-time event streaming.
---
## π Installation
### 1. Clone the Repository
```bash
git clone https://github.com/yourusername/Insider-Threat-Monitor.git
cd Insider-Threat-Monitor
python -m venv venv
venv\Scripts\activate # Windows
source venv/bin/activate # macOS/Linux
pip install -r requirements.txt
Ensure you have a valid .evtx
file in data/security.evtx
.
python core/log_parser.py data/security.evtx data/events.csv
python core/alert_engine.py
python app.py
Open: http://localhost:5001
Package | Purpose |
---|---|
Flask | Web framework |
pandas | Data processing |
Evtx | Parse .evtx logs |
Flask-Login | Authentication |
Install all dependencies via:
pip install -r requirements.txt

- Default Credentials:
admin / admin123
- Secure authentication ensures only authorized users can access sensitive data.

- Stats at a Glance:
- Total Events
- Users
- Critical Events
- Login Activity Chart: Shows non-zero hours with login activity.

- Detailed Alerts: Lists suspicious activities with timestamps, risk levels, and descriptions.
- High-risk events are highlighted for quick action.

- Real-time Updates: Displays ongoing events as they occur.
- Risk Levels: Indicates severity for each event.
Edit app.py
:
USERS = {
'admin': {
'password': 'new_password', # Change this!
'id': 1
}
}
Edit config/rules.json
:
{
"after_hours_window": [2, 5], # After-hours detection window
"file_access_threshold": 50, # Threshold for mass file access
"critical_event_ids": [4624, 4663, 4664, 4688],
"alert_emails": [],
"description": "Detection rules for insider threat monitoring",
"version": "1.0"
}
In core/alert_engine.py
, add new rules under generate_alerts()
.
Edit dashboard/static/style.css
for custom styling.
MIT License Β© 2025 Your Name
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, subject to the following conditions...
Pull requests are welcome! For major changes, please open an issue first.
Deploy to:
- Docker
- Heroku
- AWS Elastic Beanstalk