named can create unrecoverable managed-keys.jnl file
- Run
named
in a way it can't reach the internet (f.e. set the query-source port to the listening port).
options {
query-source address 10.10.10.20 port 53054;
port 53;
listen-on port 53053 { 10.10.10.20; };
};
- Stop it after you see
running
in the log immediately, but beforeresolver priming query complete
is printed - Verify that managed-keys.jnl is bogus with
$ bin/tools/named-journalprint managed-keys.bind.jnl
del . 0 IN SOA . . 0 0 0 0 0
add . 0 IN SOA . . 1 0 0 0 0
add . 0 IN TYPE65533 \# 16 00000000000000000000000000000000
- Now fix your config:
options {
query-source address 10.10.10.20 port 0;
port 53;
listen-on port 53053 { 10.10.10.20; };
};
- Run
named
again and it will not recover from the brokenmanaged-keys.bind.jnl
file:
08-Sep-2021 09:50:48.172 running
08-Sep-2021 09:50:49.784 managed-keys-zone: DNSKEY set for zone '.' could not be verified with current keys
08-Sep-2021 09:50:49.788 validating ./NS: no valid signature found
08-Sep-2021 09:50:49.788 no valid RRSIG resolving './NS/IN': 198.97.190.53#53
08-Sep-2021 09:50:49.796 validating ./NS: no valid signature found
08-Sep-2021 09:50:49.796 no valid RRSIG resolving './NS/IN': 199.7.83.42#53
08-Sep-2021 09:50:49.804 validating ./NS: no valid signature found
08-Sep-2021 09:50:49.804 no valid RRSIG resolving './NS/IN': 193.0.14.129#53
08-Sep-2021 09:50:53.028 validating ./NS: no valid signature found
08-Sep-2021 09:50:53.028 no valid RRSIG resolving './NS/IN': 198.41.0.4#53
08-Sep-2021 09:50:53.040 validating ./NS: no valid signature found
08-Sep-2021 09:50:53.040 no valid RRSIG resolving './NS/IN': 192.33.4.12#53
08-Sep-2021 09:50:58.168 resolver priming query complete
08-Sep-2021 09:51:13.172 managed-keys-zone: DNSKEY set for zone '.' could not be verified with current keys
This is low-priority issue, but it should be recorded somewhere.