Commit 8db0203f authored by Petr Špaček's avatar Petr Špaček

Deckard: fail on unknown keywords in CONFIG section

All unknown (and, formerly, silently ignored) keywords were removed from
existing tests. This allows us to detect typos.
parent 61d00397
Pipeline #32098 failed with stage
in 5 seconds
...@@ -947,11 +947,11 @@ def parse_config(scn_cfg, qmin, installdir): ...@@ -947,11 +947,11 @@ def parse_config(scn_cfg, qmin, installdir):
# Enable selectively for some tests # Enable selectively for some tests
if k == 'do-not-query-localhost': if k == 'do-not-query-localhost':
do_not_query_localhost = str2bool(v) do_not_query_localhost = str2bool(v)
if k == 'domain-insecure': elif k == 'domain-insecure':
negative_ta_list.append(v) negative_ta_list.append(v)
if k == 'harden-glue': elif k == 'harden-glue':
harden_glue = str2bool(v) harden_glue = str2bool(v)
if k == 'query-minimization': elif k == 'query-minimization':
qmin = str2bool(v) qmin = str2bool(v)
elif k == 'trust-anchor': elif k == 'trust-anchor':
trust_anchor = v.strip('"\'') trust_anchor = v.strip('"\'')
...@@ -1003,6 +1003,8 @@ def parse_config(scn_cfg, qmin, installdir): ...@@ -1003,6 +1003,8 @@ def parse_config(scn_cfg, qmin, installdir):
% (v, str(ex))) % (v, str(ex)))
elif k == 'force-ipv6' and v.upper() == 'TRUE': elif k == 'force-ipv6' and v.upper() == 'TRUE':
sockfamily = socket.AF_INET6 sockfamily = socket.AF_INET6
else:
raise NotImplementedError('unsupported CONFIG key "%s"' % k)
ctx = { ctx = {
"DO_NOT_QUERY_LOCALHOST": str(do_not_query_localhost).lower(), "DO_NOT_QUERY_LOCALHOST": str(do_not_query_localhost).lower(),
......
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "3 2 1 0 0" ; target-fetch-policy: "3 2 1 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
harden-glue: "no" harden-glue: "no"
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
harden-referral-path: no ; harden-referral-path: no
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
; minimization does not affect priming query ; minimization does not affect priming query
query-minimization: off query-minimization: off
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
harden-referral-path: no ; harden-referral-path: no
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
; test with pre-scripted replies does not make sense with qmin ; test with pre-scripted replies does not make sense with qmin
query-minimization: off query-minimization: off
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
query-minimization: on query-minimization: on
name: "." ; name: "."
stub-addr: 127.0.0.10 # K.ROOT-SERVERS.NET. stub-addr: 127.0.0.10 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
query-minimization: on query-minimization: on
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
query-minimization: on query-minimization: on
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
query-minimization: on query-minimization: on
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
module-config: "iterator" ; module-config: "iterator"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
; The island of trust is at example.com ; The island of trust is at example.com
server: ;server:
trust-anchor: "example.com. IN DS 438 10 2 33F8133EB48EDB093839E985600EB7B7009EB5AC312D11CCA9007F6B 71D94D7B" trust-anchor: "example.com. IN DS 438 10 2 33F8133EB48EDB093839E985600EB7B7009EB5AC312D11CCA9007F6B 71D94D7B"
val-override-date: "20160308103040" val-override-date: "20160308103040"
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
......
; config options ; config options
target-fetch-policy: "3 2 1 0 0" ; target-fetch-policy: "3 2 1 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "3 2 1 0 0" ; target-fetch-policy: "3 2 1 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "3 2 1 0 0" ; target-fetch-policy: "3 2 1 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "3 2 1 0 0" ; target-fetch-policy: "3 2 1 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
harden-referral-path: yes ; harden-referral-path: yes
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
do-ip6: no ; do-ip6: no
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
stub-zone: ;stub-zone:
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
harden-referral-path: no ; harden-referral-path: no
target-fetch-policy: "0 0 0 0 0" ; target-fetch-policy: "0 0 0 0 0"
name: "." ; name: "."
stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET. stub-addr: 193.0.14.129 # K.ROOT-SERVERS.NET.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5" trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5"
val-override-timestamp: "1437625000" val-override-timestamp: "1437625000"
stub-zone: ;stub-zone:
name: "." ; name: "."
stub-addr: 198.41.0.4 # a.root-servers.net. stub-addr: 198.41.0.4 # a.root-servers.net.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5" trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5"
val-override-timestamp: "1441892800" val-override-timestamp: "1441892800"
query-minimization: off query-minimization: off
stub-zone: ;stub-zone:
name: "." ; name: "."
stub-addr: 198.41.0.4 # a.root-servers.net. stub-addr: 198.41.0.4 # a.root-servers.net.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5" trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5"
val-override-timestamp: "1437625000" val-override-timestamp: "1437625000"
stub-zone: ;stub-zone:
name: "." ; name: "."
stub-addr: 198.41.0.4 # a.root-servers.net. stub-addr: 198.41.0.4 # a.root-servers.net.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5" trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5"
val-override-timestamp: "1438783903" val-override-timestamp: "1438783903"
query-minimization: off query-minimization: off
stub-zone: ;stub-zone:
name: "." ; name: "."
stub-addr: 198.41.0.4 # a.root-servers.net. stub-addr: 198.41.0.4 # a.root-servers.net.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
stub-addr: 193.0.14.129 stub-addr: 193.0.14.129
trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5" trust-anchor: ". 3600 IN DS 19036 8 2 49AAC11D7B6F6446702E54A1607371607A1A41855200FD2CE1CDDE32F24E8FB5"
val-override-timestamp: "1450794800" val-override-timestamp: "1450794800"
......
; config options ; config options
server: ;server:
trust-anchor: ". 3600 IN DS 17272 13 4 B87AD8C76DC2244E7AA57285057BF533F2E248CC8D7E1A071D8A3837A711A5EA705C4707E6E8911DA653BE1AE019927B" trust-anchor: ". 3600 IN DS 17272 13 4 B87AD8C76DC2244E7AA57285057BF533F2E248CC8D7E1A071D8A3837A711A5EA705C4707E6E8911DA653BE1AE019927B"
val-override-timestamp: "1442323400" val-override-timestamp: "1442323400"
do-not-query-localhost: off do-not-query-localhost: off
stub-zone: ;stub-zone:
name: "." ; name: "."
stub-addr: 127.0.0.1 # ns. stub-addr: 127.0.0.1 # ns.
CONFIG_END CONFIG_END
......
; config options ; config options
server: ;server:
trust-anchor: ". 3600 IN DS 17272 13 4 B87AD8C76DC2244E7AA57285057BF533F2E248CC8D7E1A071D8A3837A711A5EA705C4707E6E8911DA653BE1AE019927B" trust-anchor: ". 3600 IN DS 17272 13 4 B87AD8C76DC2244E7AA57285057BF533F2E248CC8D7E1A071D8A3837A711A5EA705C4707E6E8911DA653BE1AE019927B"
val-override-timestamp: "1442323400" val-override-timestamp: "1442323400"
do-not-query-localhost: off do-not-query-localhost: off
stub-zone: ;stub-zone:
name: "." ; name: "."
stub-addr: 127.0.0.1 # ns. stub-addr: 127.0.0.1 # ns.
CONFIG_END CONFIG_END
......
; config options ; config options
server: