
Intelligent Phishing Detection System ๐
An end-to-end ML-powered solution for securing networks against phishing attacks.
A complete end-to-end Machine Learning project that detects phishing websites using supervised learning.
It features a clean pipeline architecture, experiment tracking with MLflow & DagsHub, containerized packaging, and cloud-ready deployment.
๐งญ Problem Statement
Phishing websites impersonate trusted brands to steal credentials and financial data. Rule-based filters struggle against fast-evolving attacks and novel domains.
Why AI solves this:
Learns patterns from large URL & page-level features (not just static rules).
Generalizes to previously unseen phishing sites.
Continuously improves with tracked experiments and retraining.
๐ฆ Dataset
Name: Phishing Website Detection Dataset
Format: CSV
Features: 30+ web attributes (e.g., URL length, SSL state, domain age)
Target Variable:
Result-1: Phishing1: Legitimate๐ Project Structure (Main Skeleton)
This is the main structure; the production codebase contains additional modules/configs beyond this outline.
๐งฑ Features & Stack
Feature Technology Used Data Handling
pandas, numpy, MongoDB Modeling scikit-learn (LogReg, RF), xgboost Tracking & Versioning MLflow (local/remote), DagsHub Pipeline Architecture Modular, OOP-based Deployment (API Service) app.py service, Dockerized, cloud-ready Model Evaluation Accuracy, Precision, Recall, F1-Score, ROC-AUC๐๏ธ Infrastructure (Live Diagram)
Workflow Overview
Storage: AWS S3 (data, artifacts, models)
Tracking: MLflow (experiments, metrics) + DagsHub (remote tracking)
Deployment: Docker image โ AWS ECR โ AWS EC2 (serving)
Automation: GitHub Actions for CI/CD (build, test, tag, push)
Observability: Custom
logger/ + exception/ modules๐ Live Pipeline Diagram
Loading
๐ ML Pipeline Stages
Data Ingestion
Data Validation (schema, nulls, ranges)
Data Transformation (feature engineering, scaling/encoding)
Model Training (Logistic Regression, XGBoost, Random Forest)
Model Evaluation (metrics + artifacts logged to MLflow)
Model Pushing (saved locally and/or to AWS S3)
Loading
๐ MLflow Integration
Each pipeline step logs parameters, metrics, and artifacts to MLflow.
Runs can be tracked:
Locally โ
mlruns/ folderRemotely โ DagsHub (via MLflow env vars)
Facilitates model comparison, reproducibility, and rollbacks.
๐งช Model Performance (Illustrative)
Model Accuracy Precision Recall F1-Score ROC-AUC Logistic Regression 91% 90% 89% 89% 0.93 XGBoost 94% 93% 92% 92% 0.96 Random Forest 96% 95% 96% 95% 0.98
Why Recall matters:
โ ๏ธ Missing a phishing site (false negative) is riskier than a false positive.
๐ Random Forest was chosen for the best Recall/F1 balance.
๐งฐ How to Run
๐ Remote Tracking (DagsHub)
Set MLflow environment variables for remote tracking
Skip
mlflow ui when using DagsHubโ๏ธ Cloud & Deployment (Optional API)
Artifacts & Models: stored in AWS S3
Container Image: built with Docker, pushed to AWS ECR
Serving: pull & run on AWS EC2
CI/CD: automated with GitHub Actions
API:
networksecurity/app.py exposes inference endpoints๐ฎ Future Improvements
โ
Explainability (SHAP) โ feature contribution & analyst trust
โ
Streamlit Dashboard โ live insights & SOC analyst workflows
โ
Threat Intel Feeds โ enrich predictions (OpenPhish / PhishTank)
โ
LLM-assisted Triage โ natural language rationale for SOC teams
โ
Unit & Integration Tests โ higher coverage & reliability
โ
Infra as Code โ Terraform + AWS Secrets Manager
๐ค Author
Adebayo Gabriel โ ML Engineer (AI ร Cybersecurity)
๐ Links
โก This is more than a modelโit's a production-minded AI system for real-world network security.
1 like ยท 10 views ยท Sep 1, 2025
Created an ML system to detect phishing websites using supervised learning.