DNS is using port 53
DNS over TLS is using port 853
DNS over HTTPS is using port 443
Please share /ip dns to check if the settings are correct. Once you specify a DoH server, it will be used. Only when the URL has to be resolved, a standard DNS query will be performed once.
I'm not aware of a client with a static dns entry, but i had the conception that if this would be the case, the router would replace this with the DoH.
I also thought the resolving is also done on port 443.
/ip firewall filter
add action=accept chain=input comment="defconf: accept established,related,untracked" connection-state=\
established,related,untracked
add action=drop chain=input comment="defconf: drop invalid" connection-state=invalid
add action=accept chain=input comment="defconf: accept ICMP" protocol=icmp
add action=accept chain=input comment="defconf: accept to local loopback (for CAPsMAN)" dst-address=\
127.0.0.1
add action=drop chain=input comment="defconf: drop all not coming from LAN" in-interface-list=!LAN
add action=accept chain=forward comment="defconf: accept in ipsec policy" ipsec-policy=in,ipsec
add action=accept chain=forward comment="defconf: accept out ipsec policy" ipsec-policy=out,ipsec
add action=fasttrack-connection chain=forward comment="defconf: fasttrack" connection-state=\
established,related disabled=yes hw-offload=yes
add action=accept chain=forward comment="defconf: accept established,related, untracked" connection-state=\
established,related,untracked
add action=drop chain=forward comment="defconf: drop invalid" connection-state=invalid
add action=drop chain=forward comment="defconf: drop all from WAN not DSTNATed" connection-nat-state=!dstnat \
connection-state=new in-interface-list=WAN
add action=drop chain=forward in-interface=Wifi1 out-interface=bridge
add action=drop chain=forward in-interface=Wifi2 out-interface=bridge
add action=drop chain=forward in-interface=Wifi3 out-interface=bridge
add action=drop chain=forward in-interface=Wifi4 out-interface=bridge
add action=drop chain=forward in-interface=Wifi5 out-interface=bridge
/ip firewall nat
add action=masquerade chain=srcnat comment="defconf: masquerade" ipsec-policy=out,none out-interface-list=\
WAN
/ip firewall service-port
set ftp disabled=yes
set tftp disabled=yes
set h323 disabled=yes
set sip disabled=yes
set pptp disabled=yes
/ip service
set ftp disabled=yes
set ssh disabled=yes
set telnet disabled=yes
set www disabled=yes
set winbox address=192.168.77.2/32
set api disabled=yes
set api-ssl disabled=yes
Interception of DNS requests can be handled by the firewall, it would require a (actually 2) dst-nat rules. Both for UDP and TCP. But be aware that when the client uses DoT or DoH, nothing is intercepted.
add action=dst-nat chain=dstnat comment="Make Mikrotik preferred dns server UDP" dst-port=53 protocol=udp to-addresses=[IP of the router] to-ports=53
add action=dst-nat chain=dstnat comment="Make Mikrotik preferred dns server TCP" dst-port=53 protocol=tcp to-addresses=[IP of the router] to-ports=53
Can you share the output of:
/ip dhcp-server network export
Here is the DNS server set for the DHCP server to supply to the clients.
Okay...is it correct that only clients on the 192.168.88.0/24 network should do DNS requests? Perhaps you can give some more insights...as you seem to have 6 segments.
With that setup, on 88 is provisioned 192.168.88.1 and in all the others dynamically the DNS of the RouterOS, if any (94.140.14.49 and 94.140.14.59),
but the device is still free to use DoH, DoT, QUIC, & Co.
Actually no. The setup of the 6 Wifi networks was done to seperate the devices from each other. I used client isolation but thought a seperate subnet wouldn´t hurt.
Blockquote
With that setup, on 88 is provisioned 192.168.88.1 and in all the others dynamically the DNS of the RouterOS, if any.
Whats the implication of this, is it a general problem that the encrypted traffic does not get intercepted?
You'll need to manually configure all the devices that allow it,
but some will still want to use their hardcoded Chinese DNS, 8888/1111, etc.
At most, you can intercept calls to the cleartext DNS only, as much as possible, and redirect them to the router. The router then resolves them via DoH.
But all calls to non-standard DNS ports—DNScrypt, DNS over HTTPS, DNS over TLS, DNS over QUIK, etc.—will still pass.
At most, you can block DoT entirely on the standard port, or block all (know) DoH and DoQ via an address list, but you CANNOT redirect and resolve them.