I installed https-dns-proxy
and out of curiosity I wanted to see if the force dns option was working. I ran tcpdump -n -i eth0 port 53
on the router and saw quite a bit of entries including this one:
23:16:02.962184 IP 192.168.1.140.48117 > 8.8.8.8.53: 36+ A? pushproxy-usa4.eufylife.com. (45)
23:16:02.970043 IP 8.8.8.8.53 > 192.168.1.140.48117: 36 1/0/0 A 18.221.14.3 (61)
This is coming from a smart camera which probably has Google DNS hardcoded. It looks like it successfully made a call and received a response? I thought it should reject or redirect any traffic on port 53 or 853. I do not have Google as one of my DoH resolvers.
My config
root@OpenWrt:/etc/config# cat https-dns-proxy
config main 'config'
option canary_domains_icloud '0'
option canary_domains_mozilla '1'
option dnsmasq_config_update '*'
option force_dns '1'
list force_dns_port '53'
list force_dns_port '853'
option procd_trigger_wan6 '0'
config https-dns-proxy
option bootstrap_dns '1.1.1.1,1.0.0.1'
option resolver_url 'https://cloudflare-dns.com/dns-query'
option listen_addr '127.0.0.1'
option listen_port '5053'
option user 'nobody'
option group 'nogroup'
config https-dns-proxy
option bootstrap_dns '8.8.8.8,8.8.4.4'
option resolver_url 'https://dns.quad9.net/dns-query'
option listen_addr '127.0.0.1'
option listen_port '5054'
option user 'nobody'
option group 'nogroup'
When I run nft list ruleset
I do see these dns related entries which seem related
chain forward_lan {
tcp dport 853 counter packets 67 bytes 5128 jump handle_reject comment "!fw4: ubus:https-dns-proxy[instance1] rule 1"
udp dport 853 counter packets 0 bytes 0 jump handle_reject comment "!fw4: ubus:https-dns-proxy[instance1] rule 1"
...
}
and
chain dstnat_lan {
tcp dport 53 counter packets 0 bytes 0 redirect to :53 comment "!fw4: ubus:https-dns-proxy[instance1] redirect 0"
udp dport 53 counter packets 1039 bytes 83302 redirect to :53 comment "!fw4: ubus:https-dns-proxy[instance1] redirect 0"
}
It appears that the config is right, but why do I still see entries with tcpdump
?