Rename a few things

This commit is contained in:
Frank Denis 2019-11-17 15:07:40 +01:00
parent 15b405b552
commit ca7e5e5bcb
4 changed files with 10 additions and 7 deletions

View File

@ -183,7 +183,7 @@ type AnonymizedDNSConfig struct {
} }
type BrokenImplementationsConfig struct { type BrokenImplementationsConfig struct {
IncorrectPadding []string `toml:"incorrect_padding"` BrokenQueryPadding []string `toml:"broken_query_padding"`
} }
type ServerSummary struct { type ServerSummary struct {
@ -441,7 +441,7 @@ func ConfigLoad(proxy *Proxy, flags *ConfigFlags) error {
} }
proxy.routes = &routes proxy.routes = &routes
} }
proxy.serversWithIncorrectPadding = config.BrokenImplementations.IncorrectPadding proxy.serversWithBrokenQueryPadding = config.BrokenImplementations.BrokenQueryPadding
if *flags.ListAll { if *flags.ListAll {
config.ServerNames = nil config.ServerNames = nil

View File

@ -575,10 +575,13 @@ cache_neg_max_ttl = 600
[broken_implementations] [broken_implementations]
# Cisco servers currently cannot handle queries larger than 1472 bytes. # Cisco servers currently cannot handle queries larger than 1472 bytes, and don't
# This prevents large DNSCrypt responses from being received, and breaks relaying. # truncate reponses larger than questions as expected by the DNSCrypt protocol.
# This prevents large responses from being received, and breaks relaying.
# A workaround for the first issue will be applied to servers in list below.
# Do not change that list until the bugs are fixed server-side.
incorrect_padding = ['cisco', 'cisco-ipv6', 'cisco-familyshield'] broken_query_padding = ['cisco', 'cisco-ipv6', 'cisco-familyshield']

View File

@ -71,7 +71,7 @@ type Proxy struct {
blockedQueryResponse string blockedQueryResponse string
queryMeta []string queryMeta []string
routes *map[string][]string routes *map[string][]string
serversWithIncorrectPadding []string serversWithBrokenQueryPadding []string
showCerts bool showCerts bool
} }

View File

@ -299,7 +299,7 @@ func fetchDNSCryptServerInfo(proxy *Proxy, name string, stamp stamps.ServerStamp
stamp.ServerPk = serverPk stamp.ServerPk = serverPk
} }
knownBugs := ServerBugs{} knownBugs := ServerBugs{}
for _, buggyServerName := range proxy.serversWithIncorrectPadding { for _, buggyServerName := range proxy.serversWithBrokenQueryPadding {
if buggyServerName == name { if buggyServerName == name {
knownBugs.incorrectPadding = true knownBugs.incorrectPadding = true
dlog.Infof("Known bug in [%v]: padding is not correctly implemented", name) dlog.Infof("Known bug in [%v]: padding is not correctly implemented", name)