Created
February 22, 2016 11:24
-
-
Save k0nsl/24df25f24f42a66aeceb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
touch /usr/local/etc/unbound/conf/malwaredomains.conf | |
mv /usr/local/etc/unbound/conf/malwaredomains.conf /dev/null | |
curl -o /root/malwaredomains.txt https://mirror.cedia.org.ec/malwaredomains/justdomains | |
cat /root/malwaredomains.txt | while read DOMAINS | |
do | |
echo local-zone: \"${DOMAINS}.\" static | |
echo local-data: \"${DOMAINS}. IN A 127.0.0.1\" | |
done > /usr/local/etc/unbound/conf/malwaredomains.conf | |
#the below is just a ugly way to remove useless entry on line #1 and #2 | |
sed -i '1d' /usr/local/etc/unbound/conf/malwaredomains.conf | |
sed -i '1d' /usr/local/etc/unbound/conf/malwaredomains.conf |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment