Resolve WAN as LAN on Turris

From One-Eyed Man Wiki
Revision as of 15:10, 10 August 2023 by Dwrob (talk | contribs) (drafting)
Jump to navigation Jump to search

Making hairpin/loopback/reflection requests on public URLs is not complicated but the information is well hidden from Turris users. (None of this is accessible from the Luci GUI.)

In /etc/config/resolver, you need this stanza:

config resolver 'kresd' option rundir '/tmp/kresd' option log_stderr '1' option log_stdout '1' option keep_cache '1' option include_config '/etc/kresd/custom.conf'

Create the /etc/kresd/custom.conf file.

Fill up custom.conf with "hints":

hints['mon.sous.domaine.fr'] = '192.0.2.118'

Restart the kresd daemon.

Sources:

Sort of useful -- https://wiki.turris.cz/doc/en/public/dns_knot_misc

Totally useless -- https://knot-resolver.readthedocs.io/en/stable/modules-hints.html

Other confused people -- https://forum.turris.cz/t/configure-kresd-to-resolve-a-wan-address-to-a-lan-ip/13597/15