On Windows, Ninlil's listening sockets claim their ports exclusively, with a per-address fallback for the DNS transports #426
No reviewers
Labels
No labels
agent
api-regen
agent
architect
agent
coder
agent
console-coder
agent
docs-writer
agent
mechanic
agent
protocol-coder
agent
storage-coder
area/api
area/ci
area/console
area/dhcp
area/dns
area/docs
area/packaging
area/process
area/storage
area/windows
kind
bug
kind
chore
kind
docs
kind
epic
kind
feature
kind
performance
kind
security
kind
test
priority
high
priority
low
priority
medium
resolution
duplicate
resolution
not-a-bug
resolution
wontfix
status
blocked
status
in-progress
status
needs-decision
status
needs-design
status
ready
theme
ad-samba-dns
theme
alternatives-benchmark
theme
console-toolchain
theme
later
theme
parity-devices
theme
parity-query
theme
post-release-fixes
theme
tracker-setup
theme
valkey
theme
windows-installer
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
lantea-one/ninlil!426
Loading…
Reference in a new issue
No description provided.
Delete branch "feature/403-windows-exclusive-listener-ports"
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?
Closes #403
On Windows another socket could bind a port Ninlil serves (a specific address beside the wildcard, or with address reuse) and take some clients' traffic. Ninlil's listening sockets now claim their ports exclusively there. Linux and macOS are unchanged.
What changes on Windows
ListenSocketSet(DNS over UDP and TCP, DNS-over-TLS, DNSCrypt), DHCPv4, DHCPv6, TFTP and the web listener (which also serves DNS-over-HTTPS) setSO_EXCLUSIVEADDRUSEbefore the bind. DHCP and TFTP set it in place ofSO_REUSEADDR.svchostholds UDP0.0.0.0:53with connection sharing, Hyper-V and WSL; the exclusive wildcard bind fails beside it, binds on specific addresses succeed. Without the fallback DNS over UDP would no longer start on such a machine.netstathint.Evidence
SpaFallbackTeststhat need a built console.Ninlil.Web.Testspassed (2349) before the last small round. The exclusive-port tests and the fallback test are red without the production change.Known limits
ee2b8fc8mentions a README change that the commit does not contain; the README change is ine31057d7.README "Ports" and the troubleshooting entry describe the rule as measured; CHANGELOG has the entry.
🤖 Generated with Claude Code
https://claude.ai/code/session_01T33E3pmQvqkTriyQUMNUTK