Add workaround for resolver/compat integration
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
||||
"github.com/safing/portbase/log"
|
||||
"github.com/safing/portbase/modules"
|
||||
"github.com/safing/portmaster/netenv"
|
||||
"github.com/safing/portmaster/resolver"
|
||||
"github.com/tevino/abool"
|
||||
)
|
||||
|
||||
@@ -28,6 +29,12 @@ var (
|
||||
|
||||
func init() {
|
||||
module = modules.Register("compat", prep, start, stop, "base", "network", "interception", "netenv", "notifications")
|
||||
|
||||
// Workaround resolver integration.
|
||||
// See resolver/compat.go for details.
|
||||
resolver.CompatDNSCheckInternalDomainScope = DNSCheckInternalDomainScope
|
||||
resolver.CompatSelfCheckIsFailing = SelfCheckIsFailing
|
||||
resolver.CompatSubmitDNSCheckDomain = SubmitDNSCheckDomain
|
||||
}
|
||||
|
||||
func prep() error {
|
||||
|
||||
@@ -12,6 +12,7 @@ import (
|
||||
"github.com/safing/portbase/log"
|
||||
"github.com/safing/portbase/rng"
|
||||
"github.com/safing/portmaster/network/packet"
|
||||
"github.com/safing/portmaster/resolver"
|
||||
)
|
||||
|
||||
var (
|
||||
@@ -25,7 +26,7 @@ var (
|
||||
systemIntegrationCheckPackets = make(chan packet.Packet, 1)
|
||||
systemIntegrationCheckWaitDuration = 3 * time.Second
|
||||
|
||||
DNSCheckInternalDomainScope string
|
||||
DNSCheckInternalDomainScope = ".self-check." + resolver.InternalSpecialUseDomain
|
||||
dnsCheckReceivedDomain = make(chan string, 1)
|
||||
dnsCheckWaitDuration = 3 * time.Second
|
||||
dnsCheckAnswerLock sync.Mutex
|
||||
|
||||
Reference in New Issue
Block a user