mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-10-12 01:58:46 +02:00
windows: adopt GP-managed NRPT catch-all
This commit is contained in:
1 parent
58a5ea56af
commit
e4e1c0abb9
13 files changed
+3618
-287
No files matched your search
@@ -248,13 +248,7 @@ func (p *prog) handleSpecialDomains(ctx context.Context, w dns.ResponseWriter, m
|
||||
// signal the prober and respond NXDOMAIN. Used by both macOS pf probes
|
||||
// (_pf-probe-*) and Windows NRPT probes (_nrpt-probe-*) to verify that
|
||||
// DNS interception is actually routing queries to ctrld's listener.
|
||||
if probeID, ok := p.pfProbeExpected.Load().(string); ok && probeID != "" && domain == probeID {
|
||||
if chPtr, ok := p.pfProbeCh.Load().(*chan struct{}); ok && chPtr != nil {
|
||||
select {
|
||||
case *chPtr <- struct{}{}:
|
||||
default:
|
||||
}
|
||||
}
|
||||
if p.signalInterceptProbe(domain) {
|
||||
sendDNSResponse(w, m, dns.RcodeNameError) // NXDOMAIN
|
||||
return true
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user