Generates a host list of first-party trackers for ad-blocking.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

14 lines
552 B

  1. #!/usr/bin/env bash
  2. function log() {
  3. echo -e "\033[33m$@\033[0m"
  4. }
  5. # Resolve the CNAME chain of all the known subdomains for later analysis
  6. log "Compiling subdomain lists..."
  7. pv subdomains/*.list | sort -u > temp/all_subdomains.list
  8. # Sort by last character to utilize the DNS server caching mechanism
  9. pv temp/all_subdomains.list | rev | sort | rev > temp/all_subdomains_reversort.list
  10. ./resolve_subdomains.py --input temp/all_subdomains_reversort.list --output temp/all_resolved.csv
  11. sort -u temp/all_resolved.csv > temp/all_resolved_sorted.csv