Pull request: 3172 fix mobileconfig
Merge in DNS/adguard-home from 3172-mobileconfig to master
Updates #3172.
Updates #2497.
Squashed commit of the following:
commit 30549ef4eda9d88f0738089e901492d7369caa25
Author: Eugene Burkov <e.burkov@adguard.com>
Date: Tue Jun 1 21:00:17 2021 +0300
all: log changes
commit 9b9429447430a8e5656b992c04c4a74606dc5f9f
Author: Ildar Kamalov <ik@adguard.com>
Date: Tue Jun 1 17:56:59 2021 +0300
client: always show port input
commit 6d6a0bdfaa849220a5ddb4a17502ab05379d7a1c
Merge: 13a3bffd 77946a7f
Author: Eugene Burkov <e.burkov@adguard.com>
Date: Tue Jun 1 17:50:41 2021 +0300
Merge branch 'master' into 3172-mobileconfig
commit 13a3bffd4dd6ccabf3d261f17b2c758a5c61eb9c
Author: Ildar Kamalov <ik@adguard.com>
Date: Tue Jun 1 17:20:17 2021 +0300
client: add port to mobile config form
commit f6abe0b6044572f3801c31b683e76f90c4a28487
Author: Eugene Burkov <e.burkov@adguard.com>
Date: Mon May 31 19:43:37 2021 +0300
home: imp cyclo
commit c304a0bacdca6f8b5ffd21f3d00c8244ea9e4e36
Author: Eugene Burkov <e.burkov@adguard.com>
Date: Mon May 31 18:19:46 2021 +0300
home: reduce allocs
commit 10a7678861079b710bb0ef14569c60a09612ec70
Author: Eugene Burkov <e.burkov@adguard.com>
Date: Mon May 24 20:05:08 2021 +0300
all: make the host parameter required
This commit is contained in:
@@ -6,7 +6,6 @@ import (
|
||||
"net/url"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strconv"
|
||||
|
||||
"github.com/AdguardTeam/AdGuardHome/internal/aghnet"
|
||||
"github.com/AdguardTeam/AdGuardHome/internal/dnsforward"
|
||||
@@ -254,7 +253,7 @@ func getDNSEncryption() (de dnsEncryption) {
|
||||
if tlsConf.PortHTTPS != 0 {
|
||||
addr := hostname
|
||||
if tlsConf.PortHTTPS != 443 {
|
||||
addr = net.JoinHostPort(addr, strconv.Itoa(tlsConf.PortHTTPS))
|
||||
addr = aghnet.JoinHostPort(addr, tlsConf.PortHTTPS)
|
||||
}
|
||||
|
||||
de.https = (&url.URL{
|
||||
@@ -267,14 +266,14 @@ func getDNSEncryption() (de dnsEncryption) {
|
||||
if tlsConf.PortDNSOverTLS != 0 {
|
||||
de.tls = (&url.URL{
|
||||
Scheme: "tls",
|
||||
Host: net.JoinHostPort(hostname, strconv.Itoa(tlsConf.PortDNSOverTLS)),
|
||||
Host: aghnet.JoinHostPort(hostname, tlsConf.PortDNSOverTLS),
|
||||
}).String()
|
||||
}
|
||||
|
||||
if tlsConf.PortDNSOverQUIC != 0 {
|
||||
de.quic = (&url.URL{
|
||||
Scheme: "quic",
|
||||
Host: net.JoinHostPort(hostname, strconv.Itoa(int(tlsConf.PortDNSOverQUIC))),
|
||||
Host: aghnet.JoinHostPort(hostname, tlsConf.PortDNSOverQUIC),
|
||||
}).String()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user