eulaurarien/eulaurarien.sh

23 lines
693 B
Bash
Raw Normal View History

2019-11-10 17:14:25 +00:00
#!/usr/bin/env bash
# Main script for eulaurarien
# Get all subdomains accessed by each website in the website list
2019-11-10 20:59:06 +00:00
./collect_subdomains.py websites.list > subdomains.list
2019-11-10 17:14:25 +00:00
sort -u subdomains.list > subdomains.sorted.list
# Filter out the subdomains not pointing to a first-party tracker
2019-11-10 20:59:06 +00:00
./filter_subdomains.py subdomains.sorted.list > toblock.list
2019-11-10 17:14:25 +00:00
sort -u toblock.list > toblock.sorted.list
# Format the blocklist so it can be used as a hostlist
(
echo "# First party trackers"
2019-11-10 17:29:16 +00:00
echo "# List generated on $(date -Isec) by eulaurarien $(git describe --tags --dirty)"
2019-11-10 17:14:25 +00:00
cat toblock.sorted.list | while read host;
do
echo "0.0.0.0 $host"
done
) > toblock.hosts.list