Hello everybody
I've recently installed an autoritative DNS server (Unbound) and OpenVPN server on my VPS and wanted to use them with OpenWrt. After exporting my .ovpn to the router, the VPN tunnel is working fine... my IP changed, but I'm still using my ISP's DNS.
I've made a few research, but I have trouble to determine if the problem come from the server or the router's configuration and how to solve it (the DNS server is working fine)
Here are the different configuration files :
Server.conf (OpenVPN)
local xxx.xxx.xxx
port xxx
proto udp
dev tun
ca ca.crt
cert server.crt
key server.key
dh dh.pem
auth SHA512
tls-crypt tc.key
topology subnet
server 10.8.0.0 255.255.255.0
push "redirect-gateway def1 bypass-dhcp"
ifconfig-pool-persist ipp.txt
push "dhcp-option DNS 127.0.0.1"
keepalive 10 120
cipher AES-256-CBC
user nobody
group nogroup
persist-key
persist-tun
status openvpn-status.log
verb 0
crl-verify crl.pem
explicit-exit-notify
Openvpn client (.ovpn)
client
dev tun
proto udp
remote xxx.xxx.xxx.xxx xxx
resolv-retry infinite
nobind
persist-key
persist-tun
remote-cert-tls server
auth SHA512
cipher AES-256-CBC
ignore-unknown-option block-outside-dns
block-outside-dns
verb 0
-----BEGIN CERTIFICATE-----
xxxxxxx
Unbound.conf server (partial)
interface: 127.0.0.1 interface: ::1 access-control: 10.0.0.0/8 allow access-control: 127.0.0.0/8 allow access-control: 192.168.0.0/16 allow access-control: ::1 allow private-address: 192.168.0.0/16 private-address: 172.16.0.0/12 private-address: 10.0.0.0/8
And the little tutorial I've followed to setup OpenVPN on Openwrt
What can I do to avoid DNS leak ? If you need more information from me (or running some tests), don't hesitate to ask !
Thanks in advance for you help, and have a nice day