Skip to main content

AI-powered phishing detector for URLs and emails

Project description

Phishing Detector

Detecteur de phishing base sur le Machine Learning et la Programmation Orientee Objet en Python. Detecte les URLs et emails de phishing en temps reel depuis nimporte ou dans le terminal.

Installation via PyPI (recommande)

pip install isphishing
isphishing-setup
isphishing

Installation via GitHub

Linux / Mac

git clone https://github.com/f3d4yn/phishing-detector.git
cd phishing-detector
chmod +x install.sh
./install.sh
source ~/.bashrc

Windows

git clone https://github.com/f3d4yn/phishing-detector.git
cd phishing-detector
install.bat

Redemarre le terminal apres installation puis tape : isphishing

Performance des modeles

Deux modeles specialises sont utilises : un pour les URLs et un pour les emails.

Modele URL

Metrique Score
Exactitude 92.33%
Precision 93.87%
Rappel 90.57%
F1 Score 92.19%
ROC AUC 97.85%

Modele Email

Metrique Score
Exactitude 98.17%
Precision 97.69%
Rappel 98.67%
F1 Score 98.18%
ROC AUC 99.82%

Entraine sur 663 766 echantillons (564 970 URLs + 98 796 Emails)

Architecture POO

  • BaseInput : Classe abstraite (ABC)
  • EmailInput : Heritage + validate()
  • URLInput : Heritage + extract_domain()
  • FeatureExtractor : Extraction de 38 features (URL + texte)
  • MLModel : XGBoost (2000 arbres, early stopping)
  • PhishingDetector : Orchestrateur principal + whitelist
  • ThreatReport : Score + Label + Raisons
  • AlertSystem : Alertes colorees + Logs JSON

Fonctionnalites

  • Detection d URLs et emails de phishing en temps reel
  • Deux modeles XGBoost specialises (URL et Email)
  • 38 features extraites par analyse (longueur URL, entropie domaine, mots suspects, etc.)
  • Whitelist de domaines et expéditeurs de confiance
  • Logs JSON automatiques des alertes detectees
  • Interface terminal coloree

Lancer les tests

source venv/bin/activate
python -m unittest discover tests/

Reentrainer le modele

Les datasets ne sont pas inclus dans le depot.

  1. Telecharge les datasets sur Kaggle :

    • URLs : Web Page Phishing Detection Dataset
    • Emails: Phishing Email Dataset
  2. Place-les dans data/ :

    • data/all_urls.csv
    • data/all_emails.csv
  3. Lance l entrainement :

    python train.py
    

    Deux modeles seront generes :

    • models/model_url.pkl
    • models/model_email.pkl

Auteurs

Habib Ilyas et Boukyod Abdessamad Module : Programmation Avancee (Python POO)

PyPI

https://pypi.org/project/isphishing/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

isphishing-2.0.3.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

isphishing-2.0.3-py3-none-any.whl (17.3 kB view details)

Uploaded Python 3

File details

Details for the file isphishing-2.0.3.tar.gz.

File metadata

  • Download URL: isphishing-2.0.3.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for isphishing-2.0.3.tar.gz
Algorithm Hash digest
SHA256 d2b57f815d265cf4173a47268ea0fe187391024f55c32b3877b08af906271ca7
MD5 608fa2bc9419a9d206e54336641df1ce
BLAKE2b-256 4f9cdd3a318fa6348563c7918caee11cf31f5ac83952197527ef12c2989cd027

See more details on using hashes here.

File details

Details for the file isphishing-2.0.3-py3-none-any.whl.

File metadata

  • Download URL: isphishing-2.0.3-py3-none-any.whl
  • Upload date:
  • Size: 17.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for isphishing-2.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 ff7c4e3b2fc20ea426359b96654b307a8b40b4cc5cf66a47d85e4aa72d16ff8c
MD5 20d80cee5c13007f83ea3ad14f6ba9d6
BLAKE2b-256 89c066d99be81b3df18ca5471fd2fc36ac1bbd34e820e6142ae5f6ccf873d0bd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page