From 436aac48c3f445bd309653e747a554e2ea53dbfb Mon Sep 17 00:00:00 2001 From: HLFH Date: Tue, 26 Jan 2016 19:25:43 +0100 Subject: [PATCH] Update recursing.md to make it work with IPv6 --- docs/markdown/authoritative/recursion.md | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/docs/markdown/authoritative/recursion.md b/docs/markdown/authoritative/recursion.md index 905008fc29..e6bf172c6b 100644 --- a/docs/markdown/authoritative/recursion.md +++ b/docs/markdown/authoritative/recursion.md @@ -27,7 +27,7 @@ Authoritative Server itself, which leads to a very tight packet loop! By specifying [`allow-recursion`](settings.md#allow-recursion), recursion can be restricted to netmasks specified. The default is to allow recursion from -everywhere. Example: `allow-recursion=203.0.113.0/24, 198.51.100.0/26, 192.0.2.4`. +everywhere. Example: `allow-recursion=203.0.113.0/24, 198.51.100.0/26, 192.0.2.4`, `::1`. ## Details Questions carry a number of flags. One of these is called 'Recursion Desired'. @@ -41,7 +41,22 @@ if the RD flag were unset and the answer will indicate that recursion was not available. It is also possible to use a resolver living on a different port. To do so, -specify a recursor like this: `recursor=192.0.2.1:5300` +specify a recursor like this: `recursor=192.0.2.1:5300`. + +**Reminder:** [according to RFC3986](https://tools.ietf.org/html/rfc3986#section-3.2.2) for IPv6, the notation is to +encode the IPv6 IP number in square brackets like this: `recursor=[::1]:5300`, as +they explain in section 3.2.2: Host: + +> A host identified by an Internet Protocol literal address, version 6 [RFC3513] or +later, is distinguished by enclosing the IP literal within square brackets ("[" and "]"). +This is the only place where square bracket characters are allowed in the URI syntax. +In anticipation of future, as-yet-undefined IP literal address formats, an +implementation may use an optional version flag to indicate such a format explicitly +rather than rely on heuristic determination. + +So, be careful! `pdns-recursor` can't work in IPv6 if you write something wrongly +like ~~`recursor=::1:5300`~~ without the required square brackets ("[" and "]") +enclosing the IP litteral. If the backend does not answer a question within a large amount of time, this is logged as 'Recursive query for remote 198.51.100.15 with internal id 0 was not -- 2.47.2