In some topologies, it is required to DNS reply traffic from a DNS server so that the querying host will think that a certain DNS entry (example smtp.company.com) is resolvable to a different IP address than the one written in the database of the DNS server.
The feature has a global on/off switch, in the
objects_5_.C file, called
fw_dns_xlation (by default set to false). When it is set to true, the regular NAT Rule Base is used to determine how to change the DNS packets.
The regular NAT rules used to NAT the internal servers will suffice. There is no need to define special NAT rules in addition to the regular ones defined.
To enable the
fw_dns_xlation property, perform on the SmartCenter server:
- Close all SmartConsole clients connected to the SmartCenter server.
- Open the GuiDBedit utility and and connect to the SmartCenter server.
- Find the
- Change the value of this property to true. Click OK.
- Select File -> Save All.
- Open the SmartDashboard and re-install the Security Policy on the Security gateway.
From this point on, the Security gateway will NAT the DNS data, according to the NAT Rule Base.
You must also enable the DNS protocol protection for UDP in the IPS (formerly, SmartDefense). To enable this protection:
For the Security Gateway R70:
- Open the IPS tab in the SmartDashboard.
- Go to the Protections -> By Protocol -> Application Intelligence -> DNS view.
- Open the ‘DNS – General Settings’ Protection Details.
- Click Edit.
- Verify that either the ‘UDP only’ or ‘Both TCP and UDP’ checkbox is selected.
For all other versions:
- Open the SmartDefense tab in the SmartDashboard.
- Go to the Application Intelligence -> DNS -> Protocol Enforcement view.
- Verify that the ‘UDP protocol enforcement’ checkbox is selected.
- The manual rules for network objects or Automatic NAT Static rules for host objects must be used. This feature does not work with Automatic NAT Static rules of network objects.
- Traffic will be modified based on the destination address of the NAT rules without considering the source of the traffic.
- The feature does not work for a DNS zone transfer (used to synchronize DNS databases between to internal DNS servers).
- The feature does not work for DNS queries over TCP.
- The Security gateway must be between the querying host and the DNS server.
- On Security Gateway R70, DNS traffic cannot be accelerated when using this feature.
If the “NAT for DNS payload” option is enabled and the “UDP DNS protocol enforcement” protection is disabled on at least one of SmartDefense/IPS profiles, the Security Policy installation will succeed but the following warning will appear:
“You enabled NAT on DNS payload, please make sure that DNS UDP protocol enforcement defense is enabled on the desired gateway.”