Pull request 2398: 7781-fix-serve-plain-dns

Updates #7781.

Squashed commit of the following:

commit 5dff0be1763e7da7dd655bf1e34dfa8402ad96e8
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Apr 22 18:15:42 2025 +0300

    home: fix serve plain dns
This commit is contained in:
Stanislav Chzhen
2025-04-22 20:31:15 +03:00
parent 72425b80a3
commit 4ccc2a2138

View File

@@ -347,13 +347,6 @@ func newDNSTLSConfig(
return nil, fmt.Errorf(format, err)
}
// Unencrypted DoH is managed by AdGuard Home itself, not by dnsproxy.
// Therefore, avoid setting the certificate property to prevent dnsproxy
// from starting encrypted listeners. See [dnsforward.Server.prepareTLS].
if conf.AllowUnencryptedDoH {
return dnsConf, nil
}
dnsConf.Cert = &cert
return dnsConf, nil