mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-30 22:15:20 +00:00
rbtdb zone find() function could set foundname incorrectly
when an empty node was found, the result was treated as a partial match, but foundname could still contain the name of the empty node instead of its parent.
This commit is contained in:
committed by
Matthijs Mekking
parent
dd1050e938
commit
2025ba8f7a
@@ -1319,11 +1319,19 @@ found:
|
||||
/*
|
||||
* We have an exact match for the name, but there are no
|
||||
* active rdatasets in the desired version. That means that
|
||||
* this node doesn't exist in the desired version, and that
|
||||
* we really have a partial match.
|
||||
* this node doesn't exist in the desired version.
|
||||
* If there's a node above this one, reassign the
|
||||
* foundname to the parent and treat this as a partial
|
||||
* match.
|
||||
*/
|
||||
if (!wild) {
|
||||
NODE_UNLOCK(lock, &nlocktype);
|
||||
if (search.chain.level_count > 0) {
|
||||
dns_dbnode_t *parent =
|
||||
search.chain.levels
|
||||
[search.chain.level_count - 1];
|
||||
dns_rbt_fullnamefromnode(parent, foundname);
|
||||
}
|
||||
goto partial_match;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user