PhiUSIIL_cleaned / README.md
asgroi's picture
Create README.md
2e7bd46 verified
---
language:
- en
license: cc-by-4.0
pretty_name: PhiUSIIL Cleaned
task_categories:
- tabular-classification
tags:
- cybersecurity
- phishing
- phishing-detection
- url-classification
- web-security
- benchmark
- tabular
- ai-ready
- lookalike-detection
size_categories:
- 100K<n<1M
---
# PhiUSIIL Cleaned
PhiUSIIL Cleaned is a cleaned and AI-ready version of the original **PhiUSIIL Phishing URL Dataset**, a UCI Machine Learning Repository benchmark for phishing URL classification based on pre-extracted features derived from both URL structure and HTML page source.
The original PhiUSIIL dataset was introduced by Prasad and Chandra (2024) and is designed to detect **visual-similarity phishing attacks** (e.g. homograph, punycode, typosquatting, combosquatting) by combining URL-level signals, HTML-derived signals, and a URL Similarity Index. The original collection covers legitimate and phishing URLs gathered between October 2022 and May 2023 from public sources such as Open PageRank Initiative, PhishTank, OpenPhish and MalwareWorld.
Compared with the original source asset, this release standardizes metadata, removes URL-level duplicates, audits constant and non-finite features, and exports a fully labeled dataset in a stable, memory-mapped, ML-ready format. Each sample is represented as a fixed-length numerical vector of 50 features derived from URL structure and HTML page properties, while the original textual columns (FILENAME, URL, Domain, TLD, Title) are preserved separately as metadata for audit and traceability.
## Original dataset
This dataset is a cleaned derivative of the original PhiUSIIL dataset:
- **Original name:** PhiUSIIL Phishing URL Dataset
- **Original provider:** UC Irvine Machine Learning Repository
- **Original paper:** Prasad, A., & Chandra, S. (2024). PhiUSIIL: A diverse security profile empowered phishing URL detection framework based on similarity index and incremental learning.
- **Original DOI:** https://doi.org/10.1016/j.cose.2023.103545
- **Original project/repository:** https://archive.ics.uci.edu/dataset/967/phiusiil+phishing+url+dataset
Please cite the original PhiUSIIL paper when using this cleaned release in research.
## Files
| File | Description |
|---|---|
| `phiusiil_clean.npz` | Index file with row/feature counts and file references |
| `phiusiil_clean_X.npy` | Feature matrix (`float32`), NumPy `.npy` array, shape `(235370, 50)` |
| `phiusiil_clean_y.npy` | Label vector (`int32`), `0 = phishing`, `1 = legitimate` |
| `phiusiil_clean_metadata.parquet` | Per-sample metadata including URL-related fields and quality flags |
| `canonical_manifest_final.json` | Versioned manifest with checksums and artifact references |
| `phiusiil_cleaned_dataset.ipynb` | Exploration and usage notebook |
## What’s in the dataset?
This cleaned release contains the fully labeled PhiUSIIL phishing URL detection dataset.
### Labeled split
- **235,370 labeled samples**
- **50 numerical features**
- feature dtype: `float32`
- label dtype: `int32`
- labels:
- `0` = phishing
- `1` = legitimate
Final class distribution:
- phishing: 100,520 samples
- legitimate: 134,850 samples
### Feature representation
Samples are not raw URLs alone. Each URL is represented as a **fixed-length numerical feature vector** extracted from URL structure and related web characteristics.
The feature space includes information such as:
- URL length
- domain length
- subdomain statistics
- HTTPS usage
- obfuscation indicators
- special-character ratios
- entropy-like URL properties
- TLD-related statistics
- HTML/page-derived indicators
Examples of retained features include:
- `URLLength`
- `DomainLength`
- `NoOfSubDomain`
- `URLCharProb`
- `TLDLength`
- `TLDLegitimateProb`
- `IsHTTPS`
- `HasTitle`
- `HasFavicon`
- `HasObfuscation`
The original dataset also contained textual/identification fields such as:
- `URL`
- `Domain`
- `TLD`
- `Title`
These fields are preserved in the metadata parquet file but excluded from the numerical ML feature matrix.
## Cleaning summary
This release is the output of a quality-control and standardization pipeline applied to the original PhiUSIIL artifacts.
Main processing steps:
1. **Duplicate removal** using normalized URL comparison
2. **Metadata standardization**
3. **Feature integrity validation**
4. **Missing-value and non-finite auditing**
5. **Label normalization**
6. **Manifest generation** for reproducibility and integrity checks
Summary of the main changes:
- **425 duplicate samples removed**
- **0 constant features dropped**
- **0 rows removed due to NaN/Inf/non-finite values**
- final dataset shape: **235,370 × 50**
No label conflicts were found during duplicate analysis.
## File structure
```text
PhiUSIIL_cleaned/
├── phiusiil_clean.npz
├── phiusiil_clean_X.npy
├── phiusiil_clean_y.npy
├── phiusiil_clean_metadata.parquet
└── canonical_manifest_final.json
```
The `.npz` index stores `_rows` and `_features` for reliable loading.
The feature matrix is stored as a NumPy `.npy` array and can be loaded directly with `np.load(...)`.
## Requirements
To run the quickstart examples, install the minimum required dependencies:
```bash
pip install numpy pandas pyarrow
```
For notebook-based exploration and basic visualization, you may also install:
```bash
pip install jupyter matplotlib seaborn scikit-learn
```
## Quickstart
This example loads the labeled PhiUSIIL Cleaned dataset and checks that features, labels, and metadata are consistent and ready for supervised use.
```python
import numpy as np
import pandas as pd
idx = np.load("phiusiil_clean.npz", allow_pickle=True)
n_rows = int(idx["_rows"])
n_features = int(idx["_features"])
X = np.load("phiusiil_clean_X.npy")
y = np.load("phiusiil_clean_y.npy")
meta = pd.read_parquet("phiusiil_clean_metadata.parquet")
print(
f"Dataset: {X.shape[0]} samples, {X.shape[1]} features | "
f"labels: {y.shape[0]} | metadata columns: {meta.shape[1]}"
)
assert X.shape == (n_rows, n_features)
assert X.shape[0] == len(y) == len(meta)
assert set(np.unique(y)) == {0, 1}
print("Unique labels:", np.unique(y))
print("Metadata columns:", meta.columns.tolist())
print("All checks passed.")
```
## Notebook
The repository also includes an exploration notebook in `.ipynb` format, designed to provide additional context on the cleaned dataset, its structure, and its main analytical use cases.
The notebook can be used to:
- inspect the labeled split and its feature/metadata schema
- explore feature distributions and label balance
- validate dataset consistency end-to-end
- review an example lookalike-domain detection workflow with threshold tuning and operational implications
To open it locally, run:
```bash
jupyter notebook phiusiil_cleaned_dataset.ipynb
```
or, if you use JupyterLab:
```bash
jupyter lab phiusiil_cleaned_dataset.ipynb
```
Make sure to open the notebook from the dataset root directory so that relative file paths resolve correctly.
## Typical use cases
PhiUSIIL Cleaned supports:
- binary phishing-URL detection
- benchmarking of tabular ML pipelines
- feature importance and ablation analysis on URL- vs HTML-derived signals
- lookalike-domain detection (homograph, punycode, typosquatting, combosquatting)
- exploratory data analysis on URL structure and visual-similarity indicators
- threshold-tuning studies for operational deployment of phishing detectors
The accompanying notebook includes dataset loading, exploratory analysis, and example use cases focused on phishing URL classification and feature evaluation.
## Notes and limitations
This is a structured tabular phishing dataset only.
The cleaned release contains engineered numerical URL features rather than raw HTML pages or full web content.
The dataset does not include temporal information and is therefore not intended for temporal phishing analysis.
Results obtained on PhiUSIIL should not be over-generalized to all phishing ecosystems without additional validation.
The dataset is intended for defensive research, benchmarking, and education.
## License
This cleaned release is derived from the original PhiUSIIL dataset. The original PhiUSIIL data files are associated with the CC BY 4.0 License. Please verify that your downstream redistribution and reuse remain aligned with the original source dataset.
## References
If you use this dataset, please cite the original PhiUSIIL publication:
@article{phiusiil2024,
title={PhiUSIIL: A diverse security profile empowered phishing URL detection framework based on similarity index and incremental learning.},
author={Prasad, A., & Chandra, S.},
year={2024},
doi={10.1016/j.cose.2023.103545}
}
## APA:
Prasad, A., & Chandra, S. (2024). PhiUSIIL: A diverse security profile empowered phishing URL detection framework based on similarity index and incremental learning. Computers & Security, 103545. doi: https://doi.org/10.1016/j.cose.2023.103545
## Contacts
Shared by: ACN