Retrain anomaly_detection on public labelled data (2026-10-13)
Browse files
anomaly_detection/best_model.pkl
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ae7303ba1a3d2d451eccf33a2a30f75bb43c2393d3b1f61bb1d3563255b4e556
|
| 3 |
+
size 381516
|
anomaly_detection/metadata.json
CHANGED
|
@@ -1,23 +1,155 @@
|
|
| 1 |
{
|
| 2 |
-
"
|
| 3 |
-
"trained_at": "2026-05-09T17:11:51.748003",
|
| 4 |
-
"samples": 3600,
|
| 5 |
-
"threat_rate": 0.16666666666666666,
|
| 6 |
-
"accuracy": 0.9027777777777778,
|
| 7 |
-
"f1": 0.7666666666666667,
|
| 8 |
"feature_names": [
|
| 9 |
-
"
|
| 10 |
-
"
|
| 11 |
-
"
|
| 12 |
-
"
|
| 13 |
-
"
|
| 14 |
-
"
|
| 15 |
-
"
|
| 16 |
-
"
|
| 17 |
-
"
|
| 18 |
-
"
|
| 19 |
-
"
|
| 20 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21 |
],
|
| 22 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"model_type": "IsolationForest",
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
"feature_names": [
|
| 4 |
+
"bare_length",
|
| 5 |
+
"host_length",
|
| 6 |
+
"bare_path_length",
|
| 7 |
+
"query_length",
|
| 8 |
+
"host_dots",
|
| 9 |
+
"host_subdomains",
|
| 10 |
+
"host_hyphens",
|
| 11 |
+
"host_digits",
|
| 12 |
+
"host_digit_ratio",
|
| 13 |
+
"host_entropy",
|
| 14 |
+
"host_longest_label",
|
| 15 |
+
"host_vowel_ratio",
|
| 16 |
+
"host_is_ip",
|
| 17 |
+
"host_has_port",
|
| 18 |
+
"host_suspicious_tld",
|
| 19 |
+
"tld_length",
|
| 20 |
+
"has_punycode",
|
| 21 |
+
"path_depth",
|
| 22 |
+
"path_digits",
|
| 23 |
+
"path_entropy",
|
| 24 |
+
"path_longest_token",
|
| 25 |
+
"query_params",
|
| 26 |
+
"query_longest_value",
|
| 27 |
+
"bare_at_symbol",
|
| 28 |
+
"path_double_slash",
|
| 29 |
+
"count_percent",
|
| 30 |
+
"count_equals",
|
| 31 |
+
"count_underscore",
|
| 32 |
+
"count_hyphen_path",
|
| 33 |
+
"count_tilde",
|
| 34 |
+
"bare_special_chars",
|
| 35 |
+
"has_executable_extension",
|
| 36 |
+
"has_script_extension",
|
| 37 |
+
"has_archive_extension",
|
| 38 |
+
"credential_words",
|
| 39 |
+
"is_shortener",
|
| 40 |
+
"has_embedded_url",
|
| 41 |
+
"domain_popularity",
|
| 42 |
+
"is_user_content_host"
|
| 43 |
],
|
| 44 |
+
"uses_scaler": false,
|
| 45 |
+
"training": {
|
| 46 |
+
"rows": 172511,
|
| 47 |
+
"seconds": 1.8,
|
| 48 |
+
"contamination": 0.02
|
| 49 |
+
},
|
| 50 |
+
"holdout": {
|
| 51 |
+
"benign_urls": 43949,
|
| 52 |
+
"benign_flagged": 0.0178,
|
| 53 |
+
"benign_margin_percentiles": {
|
| 54 |
+
"1": -0.0536,
|
| 55 |
+
"5": 0.0815,
|
| 56 |
+
"25": 0.1471,
|
| 57 |
+
"50": 0.1852,
|
| 58 |
+
"75": 0.2061,
|
| 59 |
+
"95": 0.2188
|
| 60 |
+
},
|
| 61 |
+
"malicious_urls": 20000,
|
| 62 |
+
"malicious_flagged": 0.1343,
|
| 63 |
+
"note": "the model never saw malicious URLs; these are how often it calls each kind unusual"
|
| 64 |
+
},
|
| 65 |
+
"known_legitimate": {
|
| 66 |
+
"checked": 24,
|
| 67 |
+
"flagged": [
|
| 68 |
+
{
|
| 69 |
+
"url": "https://accounts.google.com/signin/v2/identifier?continue=https%3A%2F%2Fmail.google.com&service=mail&flowName=GlifWebSignIn",
|
| 70 |
+
"margin": -0.0487
|
| 71 |
+
},
|
| 72 |
+
{
|
| 73 |
+
"url": "https://login.microsoftonline.com/common/oauth2/v2.0/authorize?client_id=4765445b-32c6-49b0-83e6-1d93765276ca&response_type=code&scope=openid",
|
| 74 |
+
"margin": -0.0263
|
| 75 |
+
}
|
| 76 |
+
]
|
| 77 |
+
},
|
| 78 |
+
"gate": {
|
| 79 |
+
"rules": {
|
| 80 |
+
"max_benign_flagged": 0.05,
|
| 81 |
+
"min_malicious_flagged": 0.1,
|
| 82 |
+
"min_ratio": 3.0
|
| 83 |
+
},
|
| 84 |
+
"passed": true,
|
| 85 |
+
"reasons": []
|
| 86 |
+
},
|
| 87 |
+
"name": "anomaly_detection",
|
| 88 |
+
"trained_at": "2026-10-13T22:50:22.856319Z",
|
| 89 |
+
"settings": {
|
| 90 |
+
"benign_sample": 120000,
|
| 91 |
+
"collection_benign_sample": 40000,
|
| 92 |
+
"popular_sample": 60000,
|
| 93 |
+
"phishing_sample": 120000,
|
| 94 |
+
"malware_sample": 30000,
|
| 95 |
+
"attack_benign_sample": 40000,
|
| 96 |
+
"test_fraction": 0.2,
|
| 97 |
+
"max_iter": 300,
|
| 98 |
+
"learning_rate": 0.1,
|
| 99 |
+
"max_leaf_nodes": 31,
|
| 100 |
+
"min_samples_leaf": 20,
|
| 101 |
+
"l2_regularization": 0.0,
|
| 102 |
+
"anomaly_contamination": 0.02,
|
| 103 |
+
"popular_domains": 300000,
|
| 104 |
+
"target_false_positive_rate": 0.02,
|
| 105 |
+
"seed": 42,
|
| 106 |
+
"drop_features": []
|
| 107 |
+
},
|
| 108 |
+
"sources": {
|
| 109 |
+
"domain popularity": {
|
| 110 |
+
"source": "https://tranco-list.eu/download/PYGVJ/1000000",
|
| 111 |
+
"domains": 300000
|
| 112 |
+
},
|
| 113 |
+
"Mitake/PhishingURLsANDBenignURLs": {
|
| 114 |
+
"revision": "1f939bad78f95b470c5d058dfb23c7fce35275b7",
|
| 115 |
+
"rows": {
|
| 116 |
+
"benign": 592095,
|
| 117 |
+
"phishing": 253199
|
| 118 |
+
}
|
| 119 |
+
},
|
| 120 |
+
"bgspaditya/byt-malicious-url-treatment": {
|
| 121 |
+
"revision": "82af40f1d701d03269f777aee09ceed80bb96b1c",
|
| 122 |
+
"rows": {
|
| 123 |
+
"benign": 341830,
|
| 124 |
+
"malware": 18900
|
| 125 |
+
}
|
| 126 |
+
},
|
| 127 |
+
"pirocheto/phishing-url": {
|
| 128 |
+
"revision": "1375d450d4540205ac11781b807249c9509739cd",
|
| 129 |
+
"rows": {
|
| 130 |
+
"train": {
|
| 131 |
+
"legitimate": 3828,
|
| 132 |
+
"phishing": 3735
|
| 133 |
+
},
|
| 134 |
+
"test": {
|
| 135 |
+
"legitimate": 1886,
|
| 136 |
+
"phishing": 1872
|
| 137 |
+
}
|
| 138 |
+
}
|
| 139 |
+
},
|
| 140 |
+
"phl-ldm/tranco_top_million": {
|
| 141 |
+
"revision": "37974646d7107b8789afb486461be81ba719a08a",
|
| 142 |
+
"rows": {
|
| 143 |
+
"landing pages": 149995
|
| 144 |
+
}
|
| 145 |
+
},
|
| 146 |
+
"shengqin/web-attacks": {
|
| 147 |
+
"revision": "631e4ca957612c34d09176ef6ee2e0284b18955f",
|
| 148 |
+
"rows": {
|
| 149 |
+
"attack": 19511,
|
| 150 |
+
"normal": 4785
|
| 151 |
+
}
|
| 152 |
+
}
|
| 153 |
+
},
|
| 154 |
+
"feature_set": "url_features.py, scheme-free and without a leading www."
|
| 155 |
}
|
anomaly_detection/model.pkl
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:d10d6bc1da4a579239ea1485d858b1f6e16331aa5ac8c18391328629d39d75df
|
| 3 |
-
size 513929
|
|
|
|
|
|
|
|
|
|
|
|
anomaly_detection/package_info.json
DELETED
|
@@ -1,23 +0,0 @@
|
|
| 1 |
-
{
|
| 2 |
-
"name": "anomaly_detection",
|
| 3 |
-
"type": "random_forest",
|
| 4 |
-
"version": "1.0.0",
|
| 5 |
-
"accuracy": 0.999,
|
| 6 |
-
"f1_score": 0.9989986620975891,
|
| 7 |
-
"inference_time_ms": 0.00655989646911621,
|
| 8 |
-
"files": {
|
| 9 |
-
"model": {
|
| 10 |
-
"path": "anomaly_detection/model.pkl",
|
| 11 |
-
"checksum": "833a0b8d0d785bdc4ab163b2f2e4a7b9",
|
| 12 |
-
"size_bytes": 513929
|
| 13 |
-
},
|
| 14 |
-
"scaler": {
|
| 15 |
-
"path": "anomaly_detection/scaler.pkl",
|
| 16 |
-
"checksum": "50935889b0c4b5813f2691c7f63bfa4a"
|
| 17 |
-
},
|
| 18 |
-
"metadata": {
|
| 19 |
-
"path": "anomaly_detection/metadata.json"
|
| 20 |
-
}
|
| 21 |
-
},
|
| 22 |
-
"packaged_at": "2026-03-14 21:51:56"
|
| 23 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
anomaly_detection/scaler.pkl
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:b82efc104e16d3b4998b597f8c264e69644b551ab6096e145a7456ee1665e76e
|
| 3 |
-
size 1319
|
|
|
|
|
|
|
|
|
|
|
|