Last active
November 20, 2017 03:26
-
-
Save Thermionix/d291ccd4959fffddd3fd to your computer and use it in GitHub Desktop.
quick setup for dnscrypt + dnsmasq on arch
This file contains 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/bash | |
## chose a provider from; | |
# less /usr/share/dnscrypt-proxy/dnscrypt-resolvers.csv | |
sudo pacman -Sy --noconfirm dnscrypt-proxy dnsmasq dnsutils | |
cat <<-'EOF' | sudo SYSTEMD_EDITOR=tee systemctl edit dnscrypt-proxy.service | |
[Service] | |
ExecStart= | |
ExecStart=/usr/bin/dnscrypt-proxy -R cloudns-syd | |
EOF | |
cat <<-'EOF' | sudo SYSTEMD_EDITOR=tee systemctl edit dnscrypt-proxy.socket | |
[Socket] | |
ListenStream= | |
ListenDatagram= | |
ListenStream=127.0.0.1:40 | |
ListenDatagram=127.0.0.1:40 | |
EOF | |
cat <<-'EOF' | sudo tee /etc/dnsmasq.conf | |
no-resolv | |
server=127.0.0.1#40 | |
listen-address=127.0.0.1 | |
proxy-dnssec | |
EOF | |
sudo systemctl daemon-reload | |
sudo systemctl enable dnscrypt-proxy.socket | |
sudo systemctl start dnscrypt-proxy.socket | |
sudo systemctl enable dnsmasq.service | |
sudo systemctl start dnsmasq.service | |
echo -e "nameserver 127.0.0.1" | sudo tee /etc/resolv.conf | |
sudo chattr +i /etc/resolv.conf | |
nslookup -type=txt debug.opendns.com |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment