Skip to content

Asik08/Secure-Messaging-System

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

12 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Secure Messaging System πŸ”’

A secure end-to-end encrypted messaging platform with real-time security monitoring, anomaly detection, and tamper-proof message/file exchange.
Key Features: AES-GCM Encryption β€’ Brute-Force Protection β€’ HMAC Integrity Checks β€’ ML-Powered Threat Detection.

Features ✨

  • Secure Messaging: Encrypted text/file exchange with SHA-256 checksum validation
  • Multi-Layer Security:
    • PBKDF2-HMAC user authentication
    • Tamper detection via HMAC signatures
    • Automatic file/message deletion after decryption
  • Threat Monitoring:
    • Isolation Forest anomaly detection
    • Random Forest classifier for malicious patterns
    • Real-time alerts for brute-force attacks, data exfiltration, and integrity violations
  • Admin Dashboard: View security logs, threat statistics, and system alerts
# Clone repository
git clone https://github.com/yourusername/secure-messaging-system.git
cd secure-messaging-system

Usage πŸš€

python -m secure_messaging.run

Main Menu Options:

Register User: Strong password policy enforced (8+ chars, mix of cases, symbols)

Send Message: Encrypted text communication

Send File: Secure .txt file transfer only

Check Messages: View/decrypt received items with auto-integrity checks

Admin Security Logs: View threat dashboard (credentials: admin/admin123)

Project Structure πŸ“

.
β”œβ”€β”€ secure_messaging/
β”‚   β”œβ”€β”€ messenger.py          # Core messaging logic
β”‚   β”œβ”€β”€ encryption.py         # AES/HMAC implementation
β”‚   β”œβ”€β”€ authentication.py     # User auth & session management
β”‚   β”œβ”€β”€ security_monitor.py   # Real-time threat detection
β”‚   β”œβ”€β”€ security_model.py     # ML model training/prediction
β”‚   └── logging_manager.py    # Unified logging system
β”œβ”€β”€ models/                   # Pre-trained ML models
β”‚   β”œβ”€β”€ anomaly_detector.joblib
β”‚   └── security_classifier.joblib
β”œβ”€β”€ datasets/                 # Sample security logs
β”‚   β”œβ”€β”€ synthetic_logs.jsonl  # Training data
β”‚   └── test_logs.jsonl       # Evaluation data
β”œβ”€β”€ run.py                    # CLI interface
└── requirements.txt

Dataset & Models πŸ“Š

Included Resources:

synthetic_logs.jsonl: 240 hours of simulated normal/malicious activity

test_logs.jsonl: Validation dataset with labeled anomalies

Pre-trained models (retrain if needed):

python -m secure_messaging.security_model --train

Model Architectures:

Anomaly Detector: Isolation Forest (200 estimators)

Threat Classifier: Random Forest (200 estimators, max_depth=15)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages