-
Notifications
You must be signed in to change notification settings - Fork 0
/
unwind-block
73 lines (66 loc) · 3.27 KB
/
unwind-block
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
#!/bin/sh
# prx -- prx@ybad.name.
# Licence: MIT
#
# Create a list of domains to block with unwind
# with option "block list file.txt"
# usage : unwind-block > file.txt
set -e
HOSTSSRC="
https://adaway.org/hosts.txt
https://raw.githubusercontent.com/blocklistproject/Lists/master/ads.txt
https://raw.githubusercontent.com/blocklistproject/Lists/master/tracking.txt
https://raw.githubusercontent.com/blocklistproject/Lists/master/phishing.txt
"
DOMAINSSRC="
https://v.firebog.net/hosts/Easylist.txt
https://v.firebog.net/hosts/Easyprivacy.txt
https://raw.githubusercontent.com/notracking/hosts-blocklists/master/dnscrypt-proxy/dnscrypt-proxy.blacklist.txt
https://raw.githubusercontent.com/matomo-org/referrer-spam-blacklist/master/spammers.txt
https://raw.githubusercontent.com/nextdns/metadata/master/privacy/affiliate-tracking-domains
https://raw.githubusercontent.com/nextdns/cname-cloaking-blocklist/master/domains
file:///var/db/unwind-block.txt.local
"
ADGUARDSDNS="
https://adguardteam.github.io/AdGuardSDNSFilter/Filters/filter.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/a8_net.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/act-on.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/ad-ebis.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/adobe-experience-cloud-(formerly-omniture).txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/at-internet-(formerly-xiti).txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/commanders-act.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/criteo.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/eulerian.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/geniee.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/gmo-internet-group.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/ingenious-technologies.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/keyade.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/lead-forensics.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/np6.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/oracle-eloqua.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/otto-group.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/pardot.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/tracedock.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/webtrekk.txt
https://raw.githubusercontent.com/AdguardTeam/cname-trackers/master/trackers/wizaly.txt
"
[ "$(id -u)" -ne 0 ] && echo "${0##*/}: need root privileges" && exit 1
(
for h in ${HOSTSSRC}
do
ftp -o- "$h" |
awk '/^0.0.0.0/ || /^127.0.0.1/ && !/0.0.0.0$|localhost$|localdomain$|local$/ {print $2}'
done
for d in ${DOMAINSSRC}
do
ftp -o- "$d" |
sed -e 's/#.*$//g'
done
for a in ${ADGUARDSDNS}
do
ftp -o- "$a" |
awk '/^\|\|/' |
sed -e 's/^||//' -e 's/\^$//'
done
) | sort -u
exit 0