mirror of
https://github.com/hickory-dns/hickory-dns.git
synced 2026-04-25 11:15:54 +03:00
[PR #1994] [CLOSED] Authority can depend on client source ipnet #2745
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#2745
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/1994
Author: @dxfgg17
Created: 7/26/2023
Status: ❌ Closed
Base:
main← Head:main📝 Commits (3)
56851b4Authority can depend on client source ipnetabcd7b7Merge branch 'bluejekyll:main' into main0da2a0aFix from trust-dns/main📊 Changes
3 files changed (+163 additions, -20 deletions)
View changed files
📝
Cargo.lock(+1 -0)📝
crates/server/Cargo.toml(+1 -0)📝
crates/server/src/authority/catalog.rs(+161 -20)📄 Description
I thought it could be useful to answer differently to clients depending on their source ip network.
There is no breaking change (existing functions still work the same way) but I added the two following functions in the catalog.rs file:
Now, authorities are stored like this:
There is a small performance overhead when adding an AuthorityObject because the vector has to be sorted to have at the first position the smallest IpNet and last position the biggest one (which is None, corresponding to all networks and to the current behaviour, all networks).
If this is not a wanted behavior or functionnalty feel free to delete this, I won't be offended it was just something I needed :)
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.