Policy reserved domains
According to RFC6761 query to localhost domain should generate immediate response with loopback ip address.
Added test.
and invalid
. to special domain list
Also allows to disable specific deny rules from reserved domain list on zone-by-zone basis as it should be according to RFC6303 sec.3. Disable can be done by policy rule PASS. Also any FORWARD rule for such zone will be evaluated before DENY that query.
#205 (closed) implement reserved domains properly.
Merge request reports
Activity
- Resolved by Vladimír Čunát
assigned to @vcunat
Reviewed the RFC and amended the implementation, then re-checked quite some answers, also in comparison to Unbound's. This might actually be relatively easy to test superficially via respdiff.
I'd like to think of this a bit more, e.g. on Omnia it's become common to avoid the local refusals via
policy.del(0)
which now probably won't work, etc.added 27 commits
-
bd3ba69b...d8fed142 - 26 commits from branch
master
- a2f929a7 - Merge branch 'master' into policy-reserved-domains
-
bd3ba69b...d8fed142 - 26 commits from branch
I think that
policy.del(0)
is bad practice, it unblocks all of reserved domains. Local PTR resolving can be now allowed with:policy:add(policy.suffix(policy.PASS, {todname('168.192.in-addr.arpa.')}))
This is not perfect and I think we should answer only to records from hints module and other reserved domains should be blocked. Policy module should run after hints module and in produce phase. At least some actions should run in produce (DENY, PASS, FORWARD).
I agree! But I want to think of compatibility anyway. It came into use due to the difficulty of adding a rule to forward local zones, etc.
EDIT: that doesn't mean I'll make any such changes in the end; I just don't know yet.
Edited by Vladimír Čunátchanged milestone to %1.3.x
added 51 commits
-
b154c751...758b133d - 47 commits from branch
master
- dd78f620 - hints docs: clean a bit, note interaction with policies
- 9635aa40 - policy docs: rework it all
- 2f4317c1 - Merge branch 'master' into policy-reserved-domains
- b5f7b21d - NEWS: changes in this branch
Toggle commit list-
b154c751...758b133d - 47 commits from branch
mentioned in commit 956295a3
changed milestone to %1.4.0
mentioned in commit deckard@b1ccad35
mentioned in merge request deckard!62 (merged)
Well, there's a tiny incompatibility:
policy
rules shadowhints
just as before this MR – some might have worked around it bypolicy.del(0)
but that won't work anymore and a different approach is needed (e.g.policy.PASS
). Still, it seems rather unlikely to me that any real use case would be affected by that. I saw mainly the special-use default policy shadowing custom policies, but that's fixed by the MR.