mirror of
https://github.com/hickory-dns/hickory-dns.git
synced 2026-04-25 03:05:51 +03:00
[PR #3252] [MERGED] Catalog: Send error responses in more edge cases #3681
Labels
No labels
blocked
breaking-change
bug
bug:critical
bug:tests
cleanup
compliance
compliance
compliance
crate:all
crate:client
crate:native-tls
crate:proto
crate:recursor
crate:resolver
crate:resolver
crate:rustls
crate:server
crate:util
dependencies
docs
duplicate
easy
easy
enhance
enhance
enhance
feature:dns-over-https
feature:dns-over-quic
feature:dns-over-tls
feature:dnsssec
feature:global_lb
feature:mdns
feature:tsig
features:edns
has workaround
ops
perf
platform:WASM
platform:android
platform:fuchsia
platform:linux
platform:macos
platform:windows
pull-request
question
test
tools
tools
trust
unclear
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hickory-dns#3681
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/hickory-dns/hickory-dns/pull/3252
Author: @divergentdave
Created: 9/3/2025
Status: ✅ Merged
Merged: 9/3/2025
Merged by: @divergentdave
Base:
main← Head:david/catalog-update-error-responses📝 Commits (6)
57b9263Change one more error messagef55dc1bFactor out helper for sending error responses6d0962fUse helper for BADVERS as well6b8aa10Send error responses in various edge cases5cc00b8Add tests for empty zone handler chain in catalog632401fStore Edns in MessageResponse as a reference📊 Changes
6 files changed (+312 additions, -117 deletions)
View changed files
📝
crates/server/src/zone_handler/catalog.rs(+213 -104)📝
crates/server/src/zone_handler/message_response.rs(+9 -9)📝
tests/integration-tests/src/mock_request_handler.rs(+1 -1)📝
tests/integration-tests/tests/integration/catalog_tests.rs(+86 -0)📝
tests/integration-tests/tests/integration/dnssec_client_handle_tests.rs(+1 -1)📝
tests/integration-tests/tests/integration/sqlite_zone_handler_tests.rs(+2 -2)📄 Description
While I was working on an UPDATE test, I noticed another case where we were failing to send a response in certain error conditions (leading to a test hang). This is related to #2572. I went through
Catalog::handle_request()and its call tree to send error responses in more cases; we should have complete coverage now. Error responses were primarily missing inCatalog::update(), in fall-through code where no zone handler in a chain handled a request, and during response signing where?was used to return early. I changed the return type of some functions or methods from aResultto aResponseInfo, which helped flush out the latter. I also changedMessageResponseso that it only holds a reference to the response'sEdnsstruct, not ownership of it, in order to eliminate some unnecessary clones.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.