The DNS response substitution service allows changing the IP addresses returned by the DNS server for specific domain names. This allows influencing DNS server responses by overriding IP addresses in server replies for certain types of DNS queries specified in the service settings.
This service is effective for controlling client DNS queries and redirecting them to alternative IP addresses. It is particularly useful when you need to direct the user to a different resource than the one requested.
vi test.txt google.com A 192.0.2.1 example.com AAAA 2001:db8:85a3::8a2e:370:7334 *.fb.com A 203.0.113.5
dns2dic
utility to convert the text file into a binary format understandable by DPI:cat test.txt | dns2dic test.bin
cp test.bin /var/lib/dpi/dns.bin
fdpi_ctrl load profile --service 19 --profile.name test_193 --profile.json '{ "dns_list" : "/var/lib/dpi/dns.bin" }'
max_profiles_serv19
— setting for the maximum number of profiles. The default is 32.
Command format:
fdpi_ctrl [command] --service 19 [options list] [login or vchannel]
Enabling the service:
fdpi_ctrl load --service 19 --profile.name test_193 --login test #or fdpi_ctrl load --service 19 --profile.name test_193 --vchannel 1
Disabling the service:
fdpi_ctrl del --service 19 --profile.name test_193 --login test #or fdpi_ctrl del --service 19 --profile.name test_193 --vchannel 1