]> git.ipfire.org Git - thirdparty/bind9.git/commit
Add a mechanism to record namespaces for synth-from-dnssec
authorMark Andrews <marka@isc.org>
Thu, 16 Jun 2022 06:31:10 +0000 (16:31 +1000)
committerMark Andrews <marka@isc.org>
Wed, 6 Jul 2022 21:47:45 +0000 (07:47 +1000)
commitb979b6be407a083080e790bdc0a68ebecaa607ea
tree5036adab3695055a90806d2ad1c1bdf55120d401
parentf94fb633efed6ae3acbf8bf922323cd6bca33408
Add a mechanism to record namespaces for synth-from-dnssec

When namespace is grafted on, the DNSSEC proofs for non existance
need to come from that namespace and not a higher namespace.  We
add 3 function dns_view_sfd_add, dns_view_sfd_del and dns_view_sfd_find
to add, remove and find the namespace that should be used when
checking NSEC records.

dns_view_sfd_add adds a name to a tree, creating the tree if needed.
If the name already existed in the tree the reference count is
increased otherwise it is initalised to 1.

dns_view_sfd_del removes a reference to a name in the tree, if the
count goes to 0 the node is removed.

dns_view_sfd_find returns the namespace to be used to entered name.
If there isn't an enclosing name in the tree, or the tree does not
yet exist, the root name is returned.

Access to the tree is controlled by a read/write lock.

(cherry picked from commit 3619cad1413d32715cf4fe67f955b10330b770d4)
lib/dns/include/dns/view.h
lib/dns/view.c