How baranidharan16/sih-email-forensics-full works
MailShield is an email-forensics and threat-response platform. Analysts upload email artifacts through the web workspace; backend analysis parses and scores them, enriches findings with intelligence, and stores investigation evidence. A follow-on advanced pipeline can sandbox suspicious artifacts and produce SOC-oriented results, while the UI exposes cases, alerts, AI assistance, and integrity records. The README documents these capabilities; source excerpts and the SOURCE INDEX substantiate several internal calls. Other unsampled route and integration details are represented only at supported subsystem level.
Main entry points: investigation_service.py Investigation Service · main.py FastAPI Application · pipeline.py Advanced Pipeline · App.tsx MailShield UI
Components 22
Analyst Workspace
- MailShield UI
frontend/src/App.tsx - API Client
frontend/src/api/client.ts
API and Identity
- FastAPI Application
backend/main.py - Auth Routes
backend/routes/auth.py - Session Authorization
backend/utils/auth_deps.py - Analysis Routes
backend/routes/analysis.py - Investigation API
backend/app/api/v1/investigations.py
Forensic Analysis
- Investigation Service
backend/app/services/investigation_service.py - Forensic Engine
backend/app/forensic/engine.py - ML Features
backend/app/ml/features.py - ML Model Provider
backend/app/ml/model_provider.py - AI Fusion
backend/app/ai/fusion.py
Threat Response
- Forensic AI
backend/app/forensic_ai/engine.py - Threat Intelligence
backend/app/intel - Advanced Pipeline
backend/app/advanced/pipeline.py - Sandbox Client
backend/app/sandbox/client.py - Artifact Sandbox
sandbox/sandbox_app/engine.py - SOC, GRC, VAPT
backend/app/advanced
Evidence and Storage
- Integrity Ledger
backend/app/blockchain/ledger.py - Investigation Records
backend/app/models/investigation.py - Relational Database
backend/app/database/session.py
Other components
- SOC Analyst
Connections 26
- SOC Analyst → MailShield UI: uses
README.md - MailShield UI → API Client: requests data
- API Client → FastAPI Application: calls API
frontend/src/api/client.ts - FastAPI Application → Analysis Routes: mounts routes
backend/main.py - FastAPI Application → Investigation API: mounts routes
backend/main.py - FastAPI Application → Auth Routes: mounts routes
backend/main.py - Analysis Routes → Forensic Engine: starts analysis
- Investigation API → Investigation Service: delegates to
- Investigation Service → Forensic Engine: runs analysis
backend/app/services/investigation_service.py - Investigation Service → ML Features: extracts features
backend/app/services/investigation_service.py - Investigation Service → ML Model Provider: uses models
backend/app/services/investigation_service.py - Investigation Service → AI Fusion: fuses findings
backend/app/services/investigation_service.py - AI Fusion → Forensic Engine: uses findings
backend/app/ai/fusion.py - AI Fusion → ML Model Provider: uses models
backend/app/ai/fusion.py - Investigation Service → Threat Intelligence: enriches findings
backend/app/services/investigation_service.py - Investigation Service → Integrity Ledger: anchors evidence
backend/app/services/investigation_service.py - Investigation Service → Investigation Records: persists records
backend/app/services/investigation_service.py - Relational Database → Investigation Records: maps models
backend/app/database/session.py - Auth Routes → Session Authorization: uses authorization
backend/routes/auth.py - Session Authorization → Relational Database: loads sessions
backend/utils/auth_deps.py - Investigation Service → Advanced Pipeline: continues response
backend/app/services/investigation_service.py - Advanced Pipeline → Sandbox Client: requests sandboxing
backend/app/advanced/pipeline.py - Sandbox Client → Artifact Sandbox: submits artifacts
- Advanced Pipeline → SOC, GRC, VAPT: runs assessments
backend/app/advanced/pipeline.py - Advanced Pipeline → Integrity Ledger: anchors report
backend/app/advanced/pipeline.py - MailShield UI → Forensic AI: offers investigation chat