diff options
author | Lucas Christian <lucas@lucasec.com> | 2020-10-05 14:35:17 -0500 |
---|---|---|
committer | Lucas Christian <lucas@lucasec.com> | 2020-10-06 11:14:31 -0500 |
commit | e9cac63933ae9ddbb13a64406cff77640ab901dc (patch) | |
tree | f9fb72642db37ebdd685921fa9fef1daee99aca1 /interface-definitions | |
parent | 5accf7227858cde303e0c49f8c36408ef4c5fb93 (diff) | |
download | vyos-1x-e9cac63933ae9ddbb13a64406cff77640ab901dc.tar.gz vyos-1x-e9cac63933ae9ddbb13a64406cff77640ab901dc.zip |
pdns_recursor: T2964: Expose query-local-address to dns config.
In certain split DNS configurations, there is a need for more
fine-grained control over the local address DNS forwarding uses to
issue queries. The current pdns_recursor configuration allows the
recursor to send queries from any available address on the interface
the OS selects for the query, with no option to limit queries to a
particular address or set of addresses.
This commit exposes the `query-local-address` option in
`recursor.conf` to users via the `service` `dns` `forwarding`
`source-address` config node.
If the parameter is unspecified, the default value of 0.0.0.0 (any
IPv4 address) and :: (any IPv6 address) are used to match current
behavior.
Users who want more control can specify one or more IPv4 and IPv6
addresses to issue queries from. Per pdns_recursor docs, the recursor
will load balance queries between any available addresses in the
pools. Since IPv4 and IPv6 are different pools, note that specifying
only one type of address will disable issuing queries for the other
address family.
Diffstat (limited to 'interface-definitions')
-rw-r--r-- | interface-definitions/dns-forwarding.xml.in | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/interface-definitions/dns-forwarding.xml.in b/interface-definitions/dns-forwarding.xml.in index 07e63d54a..62fb8b946 100644 --- a/interface-definitions/dns-forwarding.xml.in +++ b/interface-definitions/dns-forwarding.xml.in @@ -177,6 +177,27 @@ </constraint> </properties> </leafNode> + <leafNode name="source-address"> + <properties> + <help>Local addresses from which to send DNS queries. + If unspecified, the querier will use any available address on + the outbound interface.</help> + <valueHelp> + <format>ipv4</format> + <description>IPv4 address from which to send traffic</description> + </valueHelp> + <valueHelp> + <format>ipv6</format> + <description>IPv6 address from which to send traffic</description> + </valueHelp> + <multi/> + <constraint> + <validator name="ipv4-address"/> + <validator name="ipv6-address"/> + </constraint> + </properties> + <defaultValue>0.0.0.0 ::</defaultValue> + </leafNode> <leafNode name="system"> <properties> <help>Use system name servers</help> |