This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to do transparent DNAT of DNS queries?

Here is the scenario:

- XG 135 

- all clients get DNS settings via DHCP pointing them to the domain controller which does DNS

- domain controller resolves its DNS queries to the XG

- XG resolves DNS queries via my ISP DNS server and 8.8.8.8 as fallback

 

I would like to create a rule which grabs every DNS query going to to through the WAN to be pointed to the XG itself, basically a protection in case someone manages to change his DNS to an external DNS server. Not sure where and how this rule should be created. Any hints?



This thread was automatically locked due to age.
Parents
  • Hello,

    Unfortunately, this cannot be done at present on the XG.  You can find a feature request here:

    ideas.sophos.com/.../32116999-user-dnat-rules

  • Unbelievable. 

     

    In this case, can someone help me create a workaround? 

     

    Currently the XG has the following settings: Administration => Device Settings =>All zones except WAN have DNS checked. 

    I think this means that clients from every zone except WAN is allowed to use the XG as their DNS server, right? 

     

    I think I could create a workaround with 2 rules: 

    a) allow DNS traffic from the XG to ANY

    b) block DNS traffic from ANY to ANY

     

    Since the rules are being applied in order this should stop anyone changing their own DNS settings so rather than transparently making them use the DNS of my choice I simply disallow the use of any other DNS. 

     

    I'm just not sure how to create rule a) as I don't know how to select the XG as the source device. Do I need to create a new source IP and use the XG's LAN IP?

  • Hi,

    Alternatively why not create a block rule at the top to stop any external DNS access.

    How many LANs are configured on your XG?

    You would not need a rule to allow the XG to access the external DNS because the access is from the external interface which in controlled by firewall rules (my opinion).

    Ian

     

    deleted incorrect suggestion.

Reply
  • Hi,

    Alternatively why not create a block rule at the top to stop any external DNS access.

    How many LANs are configured on your XG?

    You would not need a rule to allow the XG to access the external DNS because the access is from the external interface which in controlled by firewall rules (my opinion).

    Ian

     

    deleted incorrect suggestion.

Children