2021-08-02 14:15:51 +00:00
|
|
|
import sys
|
|
|
|
sys.path.append('/filters-maker')
|
|
|
|
|
2021-08-17 04:50:53 +00:00
|
|
|
import os
|
2021-08-02 11:57:36 +00:00
|
|
|
import crawler
|
2021-10-18 13:56:39 +00:00
|
|
|
import maker
|
2021-08-02 11:57:36 +00:00
|
|
|
|
2021-08-07 02:35:17 +00:00
|
|
|
incoming = "/reprwiki/Private-build/ucate/domains.txt"
|
2021-08-02 15:06:42 +00:00
|
|
|
excluded = "/repros/Resources/excluded.txt"
|
2021-08-07 03:19:38 +00:00
|
|
|
rpz_locat = "/reprwiki/Private-build/ucate/rpz.txt"
|
2021-08-08 04:41:13 +00:00
|
|
|
hosts_locat = "/reprwiki/Private-build/ucate/hosts.txt"
|
2021-08-12 04:19:36 +00:00
|
|
|
abp_locat = "/reprwiki/Private-build/ucate/adblock.txt"
|
2021-11-05 14:38:29 +00:00
|
|
|
unb_locat = "/reprwiki/Private-build/ucate/unbound.conf"
|
|
|
|
dnq_locat = "/reprwiki/Private-build/ucate/dnsmasq.conf"
|
2021-08-20 08:05:33 +00:00
|
|
|
Version = "UCATE"
|
2021-08-17 05:07:33 +00:00
|
|
|
os.makedirs('/reprwiki/Private-build/ucate',exist_ok=True)
|
2021-08-02 11:57:36 +00:00
|
|
|
|
2021-10-01 08:06:28 +00:00
|
|
|
UCATE_SOURCE = [
|
2021-10-01 08:05:12 +00:00
|
|
|
'https://badmojr.github.io/1Hosts/Pro/rpz.txt',
|
|
|
|
'https://github.com/minoplhy/filters/releases/download/filters-build/Adguard-dns_rpz.txt',
|
|
|
|
'https://github.com/minoplhy/filters/releases/download/filters-build/Adguard-cname-tracker_rpz.txt',
|
|
|
|
'https://github.com/minoplhy/filters/releases/download/filters-build/Adguard-cname-original_rpz.txt',
|
|
|
|
'https://github.com/minoplhy/filters/releases/download/filters-build/stevenblack-f_rpz.txt',
|
|
|
|
'https://github.com/minoplhy/filters/releases/download/filters-build/someonewhocares_rpz.txt',
|
|
|
|
'https://github.com/minoplhy/filters/releases/download/filters-build/hostsVN-all_rpz.txt',
|
|
|
|
'https://urlhaus.abuse.ch/downloads/rpz/',
|
|
|
|
'https://github.com/minoplhy/filters/raw/main/Resources/blocked.txt',
|
2021-10-02 06:24:58 +00:00
|
|
|
'https://gitlab.com/quidsup/notrack-blocklists/raw/master/notrack-blocklist.txt',
|
2021-11-07 11:10:51 +00:00
|
|
|
'https://github.com/DandelionSprout/adfilt/raw/master/Alternate%20versions%20Anti-Malware%20List/AntiMalwareDomains.txt',
|
|
|
|
'https://block.energized.pro/basic/formats/filter'
|
2021-10-01 08:05:12 +00:00
|
|
|
]
|
|
|
|
|
2021-08-03 06:53:40 +00:00
|
|
|
crawler.clear_old_files(incoming)
|
2021-10-01 08:19:26 +00:00
|
|
|
crawler.download_group_filters(UCATE_SOURCE ,incoming)
|
2021-08-17 04:46:16 +00:00
|
|
|
crawler.filtering(incoming)
|
|
|
|
crawler.filteringcon(incoming)
|
|
|
|
crawler.killingdup(incoming)
|
2021-10-02 03:55:29 +00:00
|
|
|
crawler.IP_URL_FILTERING(incoming)
|
2021-08-17 04:46:16 +00:00
|
|
|
crawler.excluded(excluded, incoming)
|
|
|
|
crawler.blankremover(incoming)
|
|
|
|
crawler.sort(incoming)
|
2021-11-15 02:21:38 +00:00
|
|
|
UCATEline = maker.linecounter(incoming)
|
2021-10-18 13:56:39 +00:00
|
|
|
maker.RPZBlocklist(excluded, incoming, rpz_locat ,Version)
|
|
|
|
maker.HOSTBlocklist(excluded, incoming, hosts_locat ,Version)
|
|
|
|
maker.ABPBlocklist(excluded, incoming, abp_locat ,Version)
|
|
|
|
maker.UNBOUNDBlocklist(excluded, incoming, unb_locat ,Version)
|
|
|
|
maker.DNSMASQBlocklist(excluded, incoming, dnq_locat ,Version)
|
|
|
|
maker.DOMAINBlocklist(excluded, incoming ,Version)
|
2021-08-17 04:46:16 +00:00
|
|
|
|
|
|
|
incoming = "/reprwiki/Private-build/veneto/domains.txt"
|
|
|
|
excluded = "/repros/Resources/excluded.txt"
|
|
|
|
rpz_locat = "/reprwiki/Private-build/veneto/rpz.txt"
|
|
|
|
hosts_locat = "/reprwiki/Private-build/veneto/hosts.txt"
|
|
|
|
abp_locat = "/reprwiki/Private-build/veneto/adblock.txt"
|
2021-11-05 14:38:29 +00:00
|
|
|
unb_locat = "/reprwiki/Private-build/veneto/unbound.conf"
|
|
|
|
dnq_locat = "/reprwiki/Private-build/veneto/dnsmasq.conf"
|
2021-08-20 08:05:33 +00:00
|
|
|
Version = "VENETO"
|
2021-08-17 05:07:33 +00:00
|
|
|
os.makedirs('/reprwiki/Private-build/veneto',exist_ok=True)
|
2021-08-17 04:46:16 +00:00
|
|
|
|
2021-10-01 08:06:28 +00:00
|
|
|
VENETO_SOURCE = [
|
2021-10-01 08:05:12 +00:00
|
|
|
'https://blokada.org/mirror/v5/exodusprivacy/standard/hosts.txt',
|
|
|
|
'https://github.com/crazy-max/WindowsSpyBlocker/raw/master/data/hosts/spy.txt',
|
|
|
|
'https://energized.pro/extensions/xtreme/formats/rpz.txt',
|
2021-11-13 03:37:51 +00:00
|
|
|
'https://blocklistproject.github.io/Lists/alt-version/ads-nl.txt',
|
|
|
|
'https://curben.gitlab.io/malware-filter/phishing-filter-agh.txt',
|
2021-11-14 09:26:32 +00:00
|
|
|
'https://curben.gitlab.io/malware-filter/pup-filter-agh.txt',
|
|
|
|
'https://phishing.army/download/phishing_army_blocklist_extended.txt'
|
2021-10-01 08:05:12 +00:00
|
|
|
]
|
|
|
|
|
2021-08-17 04:46:16 +00:00
|
|
|
crawler.clear_old_files(incoming)
|
2021-10-01 08:19:26 +00:00
|
|
|
crawler.download_group_filters(VENETO_SOURCE ,incoming)
|
2021-08-02 14:38:00 +00:00
|
|
|
crawler.filtering(incoming)
|
|
|
|
crawler.filteringcon(incoming)
|
|
|
|
crawler.killingdup(incoming)
|
2021-10-02 03:55:29 +00:00
|
|
|
crawler.IP_URL_FILTERING(incoming)
|
2021-08-02 15:33:14 +00:00
|
|
|
crawler.excluded(excluded, incoming)
|
2021-08-08 17:00:53 +00:00
|
|
|
crawler.blankremover(incoming)
|
2021-08-03 12:03:57 +00:00
|
|
|
crawler.sort(incoming)
|
2021-11-15 02:21:38 +00:00
|
|
|
VENETOline = maker.linecounter(incoming)
|
2021-10-18 13:56:39 +00:00
|
|
|
maker.RPZBlocklist(excluded, incoming, rpz_locat ,Version)
|
|
|
|
maker.HOSTBlocklist(excluded, incoming, hosts_locat ,Version)
|
|
|
|
maker.ABPBlocklist(excluded, incoming, abp_locat ,Version)
|
|
|
|
maker.UNBOUNDBlocklist(excluded, incoming, unb_locat ,Version)
|
|
|
|
maker.DNSMASQBlocklist(excluded, incoming, dnq_locat ,Version)
|
|
|
|
maker.DOMAINBlocklist(excluded, incoming ,Version)
|
2021-08-20 08:05:33 +00:00
|
|
|
|
|
|
|
excluded = "/repros/Resources/excluded.txt"
|
2021-08-20 08:27:05 +00:00
|
|
|
os.makedirs('/reprwiki/Private-build/Allowlist',exist_ok=True)
|
2021-08-20 08:05:33 +00:00
|
|
|
Version = "Allowlist"
|
|
|
|
rpz_locat = "/reprwiki/Private-build/Allowlist/rpz.txt"
|
|
|
|
abp_locat = "/reprwiki/Private-build/Allowlist/adblock.txt"
|
|
|
|
domains_locat = "/reprwiki/Private-build/Allowlist/domains.txt"
|
2021-11-15 02:21:38 +00:00
|
|
|
ALLOWLISTline = maker.linecounter(excluded)
|
2021-10-18 13:56:39 +00:00
|
|
|
maker.RPZAllowlist(excluded, rpz_locat ,Version)
|
|
|
|
maker.ABPAllowlist(excluded, abp_locat ,Version)
|
|
|
|
maker.DOMAINAllowlist(excluded ,domains_locat ,Version)
|
2021-08-20 08:05:33 +00:00
|
|
|
|
2021-08-27 05:52:57 +00:00
|
|
|
import version
|
2021-08-17 07:21:49 +00:00
|
|
|
het = "/repros/version.md"
|
2021-11-15 02:59:04 +00:00
|
|
|
addition = "\n# Rule Counter \nUCATE : " + str(UCATEline) +"\nVeneto : " + str(VENETOline) + "\nAllowlist : " + str(ALLOWLISTline)
|
2021-11-15 02:21:38 +00:00
|
|
|
version.build(het, addition)
|