summaryrefslogtreecommitdiff
path: root/interface-definitions/dns-forwarding.xml
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2019-08-20 11:50:55 +0200
committerChristian Poessinger <christian@poessinger.com>2019-08-25 19:19:20 +0200
commit8c471a772153ae7dc6d3b934c5a96706bc9a6ba5 (patch)
tree46bb61f9df6c8a73556acd3845cd63da6f597953 /interface-definitions/dns-forwarding.xml
parent4416174194de1534632b9f1e12d0b272f75ccf40 (diff)
downloadvyos-1x-8c471a772153ae7dc6d3b934c5a96706bc9a6ba5.tar.gz
vyos-1x-8c471a772153ae7dc6d3b934c5a96706bc9a6ba5.zip
powerdns: T1524: support setting allow-from network
Netmasks (both IPv4 and IPv6) that are allowed to use the server. The default allows access only from RFC 1918 private IP addresses. Due to the aggressive nature of the internet these days, it is highly recommended to not open up the recursor for the entire internet. Questions from IP addresses not listed here are ignored and do not get an answer. https://docs.powerdns.com/recursor/settings.html#allow-from Imagine an ISP network with non RFC1918 IP adresses - they can't make use of PowerDNS recursor. As of now VyOS hat allow-from set to 0.0.0.0/0 and ::/0 which created an open resolver. If there is no allow-from statement a config-migrator will add the appropriate nodes to the configuration, resulting in: service { dns { forwarding { allow-from 0.0.0.0/0 allow-from ::/0 cache-size 0 ignore-hosts-file listen-address 192.0.2.1 } } } (cherry picked from commit dc0f641956d002fa8588ef8d1213791cf36e92f2)
Diffstat (limited to 'interface-definitions/dns-forwarding.xml')
-rw-r--r--interface-definitions/dns-forwarding.xml17
1 files changed, 17 insertions, 0 deletions
diff --git a/interface-definitions/dns-forwarding.xml b/interface-definitions/dns-forwarding.xml
index 56820608c..08a221ebe 100644
--- a/interface-definitions/dns-forwarding.xml
+++ b/interface-definitions/dns-forwarding.xml
@@ -97,6 +97,23 @@
<valueless/>
</properties>
</leafNode>
+ <leafNode name="allow-from">
+ <properties>
+ <help>Networks allowed to query this server</help>
+ <valueHelp>
+ <format>ipv4net</format>
+ <description>IP address and prefix length</description>
+ </valueHelp>
+ <valueHelp>
+ <format>ipv6net</format>
+ <description>IPv6 address and prefix length</description>
+ </valueHelp>
+ <multi/>
+ <constraint>
+ <validator name="ip-prefix"/>
+ </constraint>
+ </properties>
+ </leafNode>
<leafNode name="listen-address">
<properties>
<help>Addresses to listen for DNS queries [REQUIRED]</help>