]> git.ipfire.org Git - thirdparty/bind9.git/commit
Hold a reference to the NTA table for the lifetime of each NTA 11966/head
authorEvan Hunt <each@isc.org>
Mon, 4 May 2026 07:05:27 +0000 (00:05 -0700)
committerOndřej Surý <ondrej@isc.org>
Wed, 6 May 2026 07:33:11 +0000 (09:33 +0200)
commit3db5d47ed4fd73ca515b224ef42d2a810ceab5ad
treea5351473cf7d83ee3d350bfcb109a8d7de5538e2
parentddcacbc5a84f43daa1cc80a2565b7336a1290744
Hold a reference to the NTA table for the lifetime of each NTA

Each dns__nta_t now references its parent ntatable in nta_create() and
releases it in dns__nta_destroy().  This avoids a use-after-free in
fetch_done() and other callbacks that dereference nta->ntatable: the
ntatable could otherwise be released by view destruction while an
in-flight resolver fetch still holds a reference to the NTA.

(cherry picked from commit 26c895cc9281d5cc36447d4a2c5464ad31137f76)
lib/dns/nta.c