An AI-powered Intrusion Detection System (IDS) built using Python, Streamlit, and Scikit-learn that analyzes network traffic logs and classifies sessions as Normal or Suspicious.
- Upload network log CSV files
- Machine learning-based intrusion detection
- Displays attack probability for every session
- Classifies traffic into:
- ✅ Normal
⚠️ Suspicious
- Interactive web interface using Streamlit
- Python
- Streamlit
- Pandas
- Scikit-learn
- Joblib
Intrusion-detection/
│
├── app.py
├── requirements.txt
├── intrusion_pipeline.pkl
├── sample_input.csv
├── README.md
└── screenshots/
Clone the repository:
git clone https://github.com/AsjadAbbas995/Intrusion-detection.gitGo into the project directory:
cd Intrusion-detectionInstall dependencies:
pip install -r requirements.txtStart the Streamlit application:
streamlit run app.pyThe application will open in your browser.
The uploaded CSV should contain the same feature columns used during model training.
Example:
| session_id | feature_1 | feature_2 | ... |
|---|
The application generates:
- Attack Probability
- Prediction
Example:
| Attack Probability | Prediction |
|---|---|
| 0.95 | Suspicious |
| 0.12 | Normal |
The application uses a pre-trained Scikit-learn pipeline stored as:
intrusion_pipeline.pkl
The model predicts the probability that a network session is malicious.
- Python 3.10+
- Streamlit
- Pandas
- Scikit-learn
- Joblib
Install all dependencies using:
pip install -r requirements.txt- Real-time packet monitoring
- Multiple ML model comparison
- Threat severity scoring
- Visualization dashboard
- Explainable AI (SHAP/LIME)
- Database logging
- REST API integration
Asjad Abbas
Cybersecurity Student | AI & Machine Learning | Penetration Testing