How to stop free DNS
-
We are using pfSense 2.3.3. We have configured NAT and forwarding all the traffic towards the Open DNS. Rule is working fine. I have made aliases, where I am trying to store all the free DNS. When my user is using free DNs and if it’s matched to my aliases, the content is being blocked. Every single day someone able to find out a new free DNS from the web and they are able to bypass the firewall rules and becoming nightmare for me. I have stored some around 350 free DNS, and I am able to find out that it’s a tedious and meaningless job. Now it’s my humble request to all of you is that thus it possible that whatever the DNS my user is using ,if it’s match to my pfSense DNS server, then only user could able to access the internet ,otherwise not.
Thanks in advance.
![nat 6.png](/public/imported_attachments/1/nat 6.png)
![nat 6.png_thumb](/public/imported_attachments/1/nat 6.png_thumb) -
Whack a mole is not best way to do anything. If you do not want people to use other than your own, etc.. Just block all dns and only allow the dns you want to use - this would be a much shorter list ;)
Its hard to understand your rule list without seeing the full picture.. Just allow dns to your pfsense, anything else dest to 53 just redirect.. No need to create the open alias at all.
-
If i dont want users to use their own DNS server, i do this:
https://doc.pfsense.org/index.php/Redirecting_all_DNS_Requests_to_pfSense -
Whack a mole is not best way to do anything. If you do not want people to use other than your own, etc.. Just block all dns and only allow the dns you want to use - this would be a much shorter list ;)
Harder to do in some cases, my Netflix client on my "Smart" TV always uses 8.8.8.8 for DNS regardless of what is set on the TV ;)
If I was that worried I'l use the method GruensFroeschli posted.
-
True if something has dns hard coded and you don't want it to use that dns, then yes you have to hijack/redirect it per the link GruensFroeschli provided.. Which is not whack a mole like the OP is attempting..
From the rules I can see I don't even see his reason for the whack a mole alias.. From the rules I can see if user picked something that was not in the alias it would be blocked.. So why not just use 1 rule redirect all to 53 and be done with it..
"Every single day someone able to find out a new free DNS from the web and they are able to bypass the firewall rules"
He says users are able to bypass? So he must have a any any rule in there somewhere above his access to lan for dns and his block? Really need to see his full rules list to figure out how his users are able to bypass.
-
Have a look at his earlier thread concerning this: https://forum.pfsense.org/index.php?topic=140777.0