I am configuring my lancache server and would like to use the DNS function to enable it.
I have verified that the server is reachable when I specify the IP:
However, when I don't specify the IP, and let the router decide, I get this:
I have my Windows PC Ethernet adapter settings as follows to try to force the usage of the DNS server:
Any ideas? I have tried a combination of each of the three DNS fields in LAN/WAN/DHCP. Let me know what I'm missing.
I will provide any log/command outputs on request.
From what I can see, you have only set the DNS servers for IPv4 communication.
For IPv6, you can distribute DNS servers via DHCPv6.
I guess that would be the list dns option in /etc/dhcp.
For devices that don't listen to DHCPv6, you could set the router's IPv6 DNS server in use to the address you want.
The firewall rule in the screenshot should also have little effect in my opinion, since this device is specified as the destination of the packet.
This would only intercept packets that send DNS queries to the router itself.
I think the destination zone should rather be wan or equivalent because you want a redirect rule to the router.
Do you think that would impact my command prompt results?
edit: I also don't want to have to do this whenever making use of the cache. This is for LAN setting and asking people to change settings would defeat the ease of use.
but if you want to have all clients, even guests, capable of accessing it, you'll need to do more.
since IPv6 and DoH/DoT is a thing, you'll need to force the clients to use your DNS, by stopping all external DNS access.
except for the fw rule, which works for the regular DNS calls, you need to use the BanIP package
to block known DoH and DoT servers.
what does the ipconfig say on your windows host(s) ?
The use case would be for anyone on LAN accessing Steam/battlenet servers to redirect to the lancache instead because the games will be stored there. I do not care to change the normal DNS browsers use.
With that being said, can the browser still manipulate the overall DNS for what I'm trying achieve?
This is my ipconfig of a windows PC on LAN:
Policy for lan zone is to accept everything. You can change the rule to deny the port 53 for ipv6 family.
However it would add some delay to all queries that try from ipv6 first.
You'd better advertise the ipv6 address of the lancache server.
Enabling IPv6 on the DNS server box has weird results. Initiating a game download will start with the lancache, but after 20-45 seconds it stops using the lancache and uses the internet. I can no longer download from steamcache.
I made the following changes:
Used the Dynamic IPv6 address of the lancache DNS server (how do I assign a static IPv6 address?):
root@FriendlyWrt:~# for IPV in 4 6
do
uci -q delete firewall.doh${IPV%4}_fwd
uci set firewall.doh${IPV%4}_fwd="rule"
uci set firewall.doh${IPV%4}_fwd.name="Deny-DoH"
uci set firewall.doh${IPV%4}_fwd.src="lan"
uci set firewall.doh${IPV%4}_fwd.dest="wan"
uci set firewall.doh${IPV%4}_fwd.dest_port="443"
uci set firewall.doh${IPV%4}_fwd.proto="tcp udp"
uci set firewall.doh${IPV%4}_fwd.family="ipv${IPV}"
uci set firewall.doh${IPV%4}_fwd.ipset="doh${IPV%4} dest"
uci set firewall.doh${IPV%4}_fwd.target="REJECT"
done
uci commit firewall
/etc/init.d/firewall restart
The fw4 firewall does not appear to be loaded, try fw4 flush to delete all rules.