Skip to content

Commit

Permalink
Add reference tests.json for blocklists.
Browse files Browse the repository at this point in the history
  • Loading branch information
not-a-rootkit committed Jan 15, 2025
1 parent e2b32c2 commit 96e74f9
Showing 1 changed file with 122 additions and 22 deletions.
144 changes: 122 additions & 22 deletions malicious-site-protection/tests.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,138 @@
{
"setName": {
"name": "name of the set",
"desc": "description of the set",
"phishingDetectionTests": {
"name": "Should block phishing pages",
"desc": "All browser platforms should block pages in the phishing datasets, and not block pages not in the dataset.",
"tests": [
{
"name": "name of the particular test",
"yourCustomField": "input",
"expectSomething": "output",
"name": "phishing wildcard regex test",
"siteURL": "https://malicious.example.com/all/paths/should/match/phishing",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension",
"ios-browser",
"android-browser",
"macos-browser",
"windows-browser"
"safari-extension"
]
},
{
"name": "phishing wildcard regex test 2",
"siteURL": "https://malicious.example.com/all/other/paths/should/match/phishing/too",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "multiple path phishing match",
"siteURL": "https://phishing-site.com/download/transaction/safety/check",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "multiple subdomain phishing match",
"siteURL": "https://stealing.your.data.co.uk/loading/login/connect/alert/download/information/your/transaction",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "phishing wildcard and subdomain regex test",
"siteURL": "https://impersonating-gov-uk.co.uk/login/protect/account/account/data/account/urgent/service/install/support",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "exclusively not in phishing dataset",
"siteURL": "https://not-in-dataset.com/anything.html",
"expectedAction": "allow",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "hash match in malware dataset, but not regex",
"siteURL": "https://impersonating-gov-uk.co.uk/path/not/in/dataset",
"expectedAction": "allow",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
}
]
},
"anotherSet": {
"name": "name of the set",
"desc": "description of the set",
"malwareDetectionTests": {
"name": "Should block malware pages",
"desc": "All browser platforms should block pages in the malware datasets, and not block pages not in the dataset.",
"tests": [
{
"name": "name of the particular test",
"yourCustomField": "input",
"expectSomething": "output",
"name": "malware wildcard regex test",
"siteURL": "https://drive-by-attack.com/anything.html",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "malware wildcard regex test 2",
"siteURL": "https://drive-by-attack.com/anything/else/should/match/too",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "multiple path malware match",
"siteURL": "https://malicious.example.com/login/safe/urgent/notification",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "multiple subdomain malware match",
"siteURL": "https://stealing.your.data.co.uk/loading/login/connect/alert/download/information/your/transaction",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "malware wildcard and subdomain regex test",
"siteURL": "https://danger.malware.distribution.com/support/confirm/safety/login/notification/password/password/information/information",
"expectedAction": "block",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "exclusively not in malware dataset",
"siteURL": "https://not-in-dataset.com/anything.html",
"expectedAction": "allow",
"exceptPlatforms": [
"web-extension",
"safari-extension"
]
},
{
"name": "hash match in malware dataset, but not regex",
"siteURL": "https://danger.malware.distribution.com/path/not/in/dataset",
"expectedAction": "allow",
"exceptPlatforms": [
"web-extension",
"safari-extension",
"ios-browser",
"android-browser",
"macos-browser",
"windows-browser"
"safari-extension"
]
}
]
Expand Down

0 comments on commit 96e74f9

Please sign in to comment.