mirror of
https://github.com/DNSCrypt/dnscrypt-proxy.git
synced 2025-01-20 03:09:12 +01:00
Use ODoH relays in probes
This commit is contained in:
parent
a11da2d4fb
commit
94151f9f96
@ -712,7 +712,7 @@ func _fetchODoHTargetInfo(proxy *Proxy, name string, stamp stamps.ServerStamp, i
|
||||
dlog.Debugf("Pausing done")
|
||||
}
|
||||
|
||||
url := &url.URL{
|
||||
targetURL := &url.URL{
|
||||
Scheme: "https",
|
||||
Host: stamp.ProviderName,
|
||||
Path: stamp.Path,
|
||||
@ -730,6 +730,10 @@ func _fetchODoHTargetInfo(proxy *Proxy, name string, stamp stamps.ServerStamp, i
|
||||
if err != nil {
|
||||
continue
|
||||
}
|
||||
url := targetURL
|
||||
if relay != nil {
|
||||
url = relay.ODoH.URL
|
||||
}
|
||||
responseBody, responseCode, tls, rtt, err := proxy.xTransport.ObliviousDoHQuery(useGet, url, odohQuery.odohMessage, proxy.timeout)
|
||||
if err != nil {
|
||||
continue
|
||||
@ -803,7 +807,7 @@ func _fetchODoHTargetInfo(proxy *Proxy, name string, stamp stamps.ServerStamp, i
|
||||
Proto: stamps.StampProtoTypeODoHTarget,
|
||||
Name: name,
|
||||
Timeout: proxy.timeout,
|
||||
URL: url,
|
||||
URL: targetURL,
|
||||
HostName: stamp.ProviderName,
|
||||
initialRtt: xrtt,
|
||||
useGet: useGet,
|
||||
|
Loading…
Reference in New Issue
Block a user