I was thinking of adding these(below), but I cannot figure out the format.
'http://pgl.yoyo.org/as/serverlist.php?h … =plaintext'
'http://www.malwaredomainlist.com/hostslist/hosts.txt'
'http://hosts-file.net/.\ad_servers.txt'
'http://sysctl.org/cameleon/hosts.win'
'http://adaway.org/hosts.txt'
Here is a snippet of my code (modified from a pre-existing ad blocking scheme on the forums). It concatenates 3 sources (the pgl.yoyo.org link, the malwaredomainlist link, and a custom file). The output is unique, sorted results that dnsmasq can forward to your pixel server.
MW = malwaredomainlist url
DM_TMP = temp file location
ADS = pgl.yoyo.org url
BL = blacklist file location
DM_BAD = domain list to be blocked
ip2 = pixel server IP address
(wget -qO- $MW | ( grep "127" | grep -v "localhost" ) ) | awk '{ print $2 }' > $DM_TMP
logger -t adblock "wget $MW ..."
# prepend address text and append actual ip address
sed -i "s/^/address=\//;s/$/\/$ip2/" $DM_TMP
logger -t adblock "wget $ADS ..."
wget -qO- $ADS >> $DM_TMP
sed -i -e "s/127\.0\.0\.1/$ip2/" $DM_TMP
# if blacklist file exists concatenate to downloaded file
if [ -f $BL ]; then
logger -t adblock "appending $BL ..."
cat $BL >> $DM_TMP
fi
sort $DM_TMP|uniq > $DM_BAD
rm -f $DM_TMP
Custom blocking $BL file format
address=/domain.to.block/<pixel-server-ip-address>
Gotta love sed syntax. If you add the others, let me know. It shouldn't be too bad to process reasonable lists into this format, I just didn't take the time to do more than the above.