Repository navigation
add NSEC record to debug resolve issue - #183
Merged
Merged
Conversation
keepsimple1
force-pushed
the
debug-resolve
branch
from
March 24, 2024 15:11
fc9bb22 to
0c49981
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This patch is to help debugging issue #182 .
Testing with this patch, it shows that python zeroconf publishes a DNS RR
NSECrecord (type 47) that indicates the absence of address records:[2024-03-18T05:21:14Z DEBUG mdns_sd::dns_parser] DnsNSec { record: DnsRecord { entry: DnsEntry { name: "worky-station._workstation._tcp.local.", ty: 47, class: 1, unique: true }, ttl: 120, created: 1710739274570, expires: 1710739394570, refresh: 1710739370570 }, next_domain: "worky-station._workstation._tcp.local.", bitmap: [64, 0, 0, 8] }The
bitmaphas 2 bits set: bit 1 (TYPE_A) and bit 28 (TYPE_AAAA) for Ipv4 and Ipv6 address records absence. This is the reason why the current mdns-sd lib cannot resolve its addresses.(This patch added logging facility so that we can do this:
$ RUST_LOG=debug cargo run --example query _workstation._tcp)UPDATE: added logic to lookup for addresses if the responder providesNSECrecord announcing lack of address info.UPDATE: keep the
DnsNSecrecord definition for future use. Also added a simple test case.