-
Notifications
You must be signed in to change notification settings - Fork 33
/
DNSSEC.pm
4701 lines (4206 loc) · 168 KB
/
DNSSEC.pm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
package Zonemaster::Engine::Test::DNSSEC;
use 5.014002;
use strict;
use warnings;
use version; our $VERSION = version->declare( "v1.1.58" );
use Carp;
use List::MoreUtils qw[uniq none];
use List::Util qw[min];
use Locale::TextDomain qw[Zonemaster-Engine];
use Readonly;
use Zonemaster::LDNS::RR;
use Zonemaster::Engine::Profile;
use Zonemaster::Engine::Constants qw[:algo :soa :ip];
use Zonemaster::Engine::Util;
use Zonemaster::Engine::TestMethods;
=head1 NAME
Zonemaster::Engine::Test::DNSSEC - Module implementing tests focused on DNSSEC
=head1 SYNOPSIS
my @results = Zonemaster::Engine::Test::DNSSEC->all( $zone );
=cut
### Table fetched from IANA on 2017-03-09
Readonly::Hash our %algo_properties => (
0 => {
status => $ALGO_STATUS_NOT_ZONE_SIGN,
description => q{Delete DS},
mnemonic => q{DELETE},
sig => 0,
},
1 => {
status => $ALGO_STATUS_DEPRECATED,
description => q{RSA/MD5},
mnemonic => q{RSAMD5},
sig => 0,
},
2 => {
status => $ALGO_STATUS_NOT_ZONE_SIGN,
description => q{Diffie-Hellman},
mnemonic => q{DH},
sig => 0,
},
3 => {
status => $ALGO_STATUS_DEPRECATED,
description => q{DSA/SHA1},
mnemonic => q{DSA},
sig => 1,
},
4 => {
status => $ALGO_STATUS_RESERVED,
description => q{Reserved},
},
5 => {
status => $ALGO_STATUS_NOT_RECOMMENDED,
description => q{RSA/SHA1},
mnemonic => q{RSASHA1},
sig => 1,
},
6 => {
status => $ALGO_STATUS_DEPRECATED,
description => q{DSA-NSEC3-SHA1},
mnemonic => q{DSA-NSEC3-SHA1},
sig => 1,
},
7 => {
status => $ALGO_STATUS_NOT_RECOMMENDED,
description => q{RSASHA1-NSEC3-SHA1},
mnemonic => q{RSASHA1-NSEC3-SHA1},
sig => 1,
},
8 => {
status => $ALGO_STATUS_OTHER,
description => q{RSA/SHA-256},
mnemonic => q{RSASHA256},
sig => 1,
},
9 => {
status => $ALGO_STATUS_RESERVED,
description => q{Reserved},
},
10 => {
status => $ALGO_STATUS_NOT_RECOMMENDED,
description => q{RSA/SHA-512},
mnemonic => q{RSASHA512},
sig => 1,
},
11 => {
status => $ALGO_STATUS_RESERVED,
description => q{Reserved},
},
12 => {
status => $ALGO_STATUS_DEPRECATED,
description => q{GOST R 34.10-2001},
mnemonic => q{ECC-GOST},
sig => 1,
},
13 => {
status => $ALGO_STATUS_OTHER,
description => q{ECDSA Curve P-256 with SHA-256},
mnemonic => q{ECDSAP256SHA256},
sig => 1,
},
14 => {
status => $ALGO_STATUS_OTHER,
description => q{ECDSA Curve P-384 with SHA-384},
mnemonic => q{ECDSAP384SHA384},
sig => 1,
},
15 => {
status => $ALGO_STATUS_OTHER,
description => q{Ed25519},
mnemonic => q{ED25519},
sig => 1,
},
16 => {
status => $ALGO_STATUS_OTHER,
description => q{Ed448},
mnemonic => q{ED448},
sig => 1,
},
(
map { $_ => { status => $ALGO_STATUS_UNASSIGNED, description => q{Unassigned}, } } ( 17 .. 122 )
),
(
map { $_ => { status => $ALGO_STATUS_RESERVED, description => q{Reserved}, } } ( 123 .. 251 )
),
252 => {
status => $ALGO_STATUS_NOT_ZONE_SIGN,
description => q{Reserved for Indirect Keys},
mnemonic => q{INDIRECT},
sig => 0,
},
253 => {
status => $ALGO_STATUS_PRIVATE,
description => q{private algorithm},
mnemonic => q{PRIVATEDNS},
sig => 1,
},
254 => {
status => $ALGO_STATUS_PRIVATE,
description => q{private algorithm OID},
mnemonic => q{PRIVATEOID},
sig => 1,
},
255 => {
status => $ALGO_STATUS_RESERVED,
description => q{Reserved},
},
);
Readonly::Hash our %rsa_key_size_details => (
5 => {
min_size => 512,
max_size => 4096,
rec_size => 2048,
reference => q{RFC 3110},
},
7 => {
min_size => 512,
max_size => 4096,
rec_size => 2048,
reference => q{RFC 5155},
},
8 => {
min_size => 512,
max_size => 4096,
rec_size => 2048,
reference => q{RFC 5702},
},
10 => {
min_size => 1024,
max_size => 4096,
rec_size => 2048,
reference => q{RFC 5702},
},
);
Readonly::Hash our %digest_algorithms => (
0 => q{Reserved},
1 => q{SHA-1},
2 => q{SHA-256},
3 => q{GOST R 34.11-94},
4 => q{SHA-384},
(
map { $_ => q{Unassigned} } ( 5 .. 255 )
),
);
Readonly::Hash our %LDNS_digest_algorithms_supported => (
1 => q{sha1},
2 => q{sha256},
3 => q{gost},
4 => q{sha384},
);
=head1 METHODS
=over
=item all()
my @logentry_array = all( $zone );
Runs the default set of tests for that module, i.e. between L<one and seventeen tests|/TESTS> depending on the tested zone.
If L<DNSSEC07|/dnssec07()> finds no DNSKEY nor DS RRs, no other test is run. If L<DNSSEC07|/dnssec07()> finds a DNSKEY RR, L<DNSSEC06|/dnssec06()> is run.
Takes a L<Zonemaster::Engine::Zone> object.
Returns a list of L<Zonemaster::Engine::Logger::Entry> objects.
=back
=cut
sub all {
my ( $class, $zone ) = @_;
my @results;
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec07} ) ) {
push @results, $class->dnssec07( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec07} ) and grep { $_->tag eq 'NEITHER_DNSKEY_NOR_DS' } @results ) {
push @results,
info(
NOT_SIGNED => {
zone => q{} . $zone->name
}
);
} else {
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec01} ) ) {
push @results, $class->dnssec01( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec02} ) ) {
push @results, $class->dnssec02( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec03} ) ) {
push @results, $class->dnssec03( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec04} ) ) {
push @results, $class->dnssec04( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec05} ) ) {
push @results, $class->dnssec05( $zone );
}
if ( grep { $_->tag eq q{DNSKEY_BUT_NOT_DS} or $_->tag eq q{DNSKEY_AND_DS} } @results ) {
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec06} ) ) {
push @results, $class->dnssec06( $zone );
}
}
else {
push @results,
info( ADDITIONAL_DNSKEY_SKIPPED => {} );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec08} ) ) {
push @results, $class->dnssec08( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec09} ) ) {
push @results, $class->dnssec09( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec10} ) ) {
push @results, $class->dnssec10( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec11} ) ) {
push @results, $class->dnssec11( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec13} ) ) {
push @results, $class->dnssec13( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec14} ) ) {
push @results, $class->dnssec14( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec15} ) ) {
push @results, $class->dnssec15( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec16} ) ) {
push @results, $class->dnssec16( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec17} ) ) {
push @results, $class->dnssec17( $zone );
}
if ( Zonemaster::Engine::Util::should_run_test( q{dnssec18} ) ) {
push @results, $class->dnssec18( $zone );
}
}
push @results, info( TEST_CASE_END => { testcase => (split /::/, (caller(0))[3])[-1] } );
return @results;
} ## end sub all
=over
=item metadata()
my $hash_ref = metadata();
Returns a reference to a hash, the keys of which are the names of all Test Cases in the module, and the corresponding values are references to
an array containing all the message tags that the Test Case can use in L<log entries|Zonemaster::Engine::Logger::Entry>.
=back
=cut
sub metadata {
my ( $class ) = @_;
return {
dnssec01 => [
qw(
DS01_DIGEST_NOT_SUPPORTED_BY_ZM
DS01_DS_ALGO_DEPRECATED
DS01_DS_ALGO_2_MISSING
DS01_DS_ALGO_NOT_DS
DS01_DS_ALGO_RESERVED
TEST_CASE_END
TEST_CASE_START
)
],
dnssec02 => [
qw(
DS02_ALGO_NOT_SUPPORTED_BY_ZM
DS02_DNSKEY_NOT_FOR_ZONE_SIGNING
DS02_DNSKEY_NOT_SEP
DS02_DNSKEY_NOT_SIGNED_BY_ANY_DS
DS02_NO_DNSKEY_FOR_DS
DS02_NO_MATCHING_DNSKEY_RRSIG
DS02_NO_MATCH_DS_DNSKEY
DS02_NO_VALID_DNSKEY_FOR_ANY_DS
DS02_RRSIG_NOT_VALID_BY_DNSKEY
)
],
dnssec03 => [
qw(
DS03_ERR_MULT_NSEC3
DS03_ILLEGAL_HASH_ALGO
DS03_ILLEGAL_ITERATION_VALUE
DS03_ILLEGAL_SALT_LENGTH
DS03_INCONSISTENT_HASH_ALGO
DS03_INCONSISTENT_ITERATION
DS03_INCONSISTENT_NSEC3_FLAGS
DS03_INCONSISTENT_SALT_LENGTH
DS03_LEGAL_EMPTY_SALT
DS03_LEGAL_HASH_ALGO
DS03_LEGAL_ITERATION_VALUE
DS03_NO_DNSSEC_SUPPORT
DS03_NO_NSEC3
DS03_NSEC3_OPT_OUT_DISABLED
DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD
DS03_NSEC3_OPT_OUT_ENABLED_TLD
DS03_SERVER_NO_DNSSEC_SUPPORT
DS03_SERVER_NO_NSEC3
DS03_UNASSIGNED_FLAG_USED
)
],
dnssec04 => [
qw(
RRSIG_EXPIRATION
RRSIG_EXPIRED
REMAINING_SHORT
REMAINING_LONG
DURATION_LONG
DURATION_OK
TEST_CASE_END
TEST_CASE_START
)
],
dnssec05 => [
qw(
ALGORITHM_DEPRECATED
ALGORITHM_NOT_RECOMMENDED
ALGORITHM_NOT_ZONE_SIGN
ALGORITHM_OK
ALGORITHM_PRIVATE
ALGORITHM_RESERVED
ALGORITHM_UNASSIGNED
IPV4_DISABLED
IPV6_DISABLED
KEY_DETAILS
NO_RESPONSE
NO_RESPONSE_DNSKEY
TEST_CASE_END
TEST_CASE_START
)
],
dnssec06 => [
qw(
EXTRA_PROCESSING_OK
EXTRA_PROCESSING_BROKEN
TEST_CASE_END
TEST_CASE_START
)
],
dnssec07 => [
qw(
ADDITIONAL_DNSKEY_SKIPPED
DNSKEY_BUT_NOT_DS
DNSKEY_AND_DS
NEITHER_DNSKEY_NOR_DS
DS_BUT_NOT_DNSKEY
NOT_SIGNED
TEST_CASE_END
TEST_CASE_START
)
],
dnssec08 => [
qw(
DS08_ALGO_NOT_SUPPORTED_BY_ZM
DS08_DNSKEY_RRSIG_EXPIRED
DS08_DNSKEY_RRSIG_NOT_YET_VALID
DS08_MISSING_RRSIG_IN_RESPONSE
DS08_NO_MATCHING_DNSKEY
DS08_RRSIG_NOT_VALID_BY_DNSKEY
)
],
dnssec09 => [
qw(
DS09_ALGO_NOT_SUPPORTED_BY_ZM
DS09_MISSING_RRSIG_IN_RESPONSE
DS09_NO_MATCHING_DNSKEY
DS09_RRSIG_NOT_VALID_BY_DNSKEY
DS09_SOA_RRSIG_EXPIRED
DS09_SOA_RRSIG_NOT_YET_VALID
)
],
dnssec10 => [
qw(
DS10_ALGO_NOT_SUPPORTED_BY_ZM
DS10_ANSWER_VERIFY_ERROR
DS10_HAS_NSEC
DS10_HAS_NSEC3
DS10_INCONSISTENT_NSEC_NSEC3
DS10_MISSING_NSEC_NSEC3
DS10_MIXED_NSEC_NSEC3
DS10_NAME_NOT_COVERED_BY_NSEC
DS10_NAME_NOT_COVERED_BY_NSEC3
DS10_NON_EXISTENT_RESPONSE_ERROR
DS10_NSEC3_MISSING_SIGNATURE
DS10_NSEC3_RRSIG_VERIFY_ERROR
DS10_NSEC_MISSING_SIGNATURE
DS10_NSEC_RRSIG_VERIFY_ERROR
DS10_UNSIGNED_ANSWER
)
],
dnssec11 => [
qw(
DS11_INCONSISTENT_DS
DS11_INCONSISTENT_SIGNED_ZONE
DS11_UNDETERMINED_DS
DS11_UNDETERMINED_SIGNED_ZONE
DS11_PARENT_WITHOUT_DS
DS11_PARENT_WITH_DS
DS11_NS_WITH_SIGNED_ZONE
DS11_NS_WITH_UNSIGNED_ZONE
DS11_DS_BUT_UNSIGNED_ZONE
),
],
dnssec13 => [
qw(
DS13_ALGO_NOT_SIGNED_DNSKEY
DS13_ALGO_NOT_SIGNED_NS
DS13_ALGO_NOT_SIGNED_SOA
),
],
dnssec14 => [
qw(
NO_RESPONSE
NO_RESPONSE_DNSKEY
DNSKEY_SMALLER_THAN_REC
DNSKEY_TOO_SMALL_FOR_ALGO
DNSKEY_TOO_LARGE_FOR_ALGO
IPV4_DISABLED
IPV6_DISABLED
KEY_SIZE_OK
TEST_CASE_END
TEST_CASE_START
),
],
dnssec15 => [
qw(
DS15_HAS_CDNSKEY_NO_CDS
DS15_HAS_CDS_AND_CDNSKEY
DS15_HAS_CDS_NO_CDNSKEY
DS15_INCONSISTENT_CDNSKEY
DS15_INCONSISTENT_CDS
DS15_MISMATCH_CDS_CDNSKEY
DS15_NO_CDS_CDNSKEY
),
],
dnssec16 => [
qw(
DS16_CDS_INVALID_RRSIG
DS16_CDS_MATCHES_NON_SEP_DNSKEY
DS16_CDS_MATCHES_NON_ZONE_DNSKEY
DS16_CDS_MATCHES_NO_DNSKEY
DS16_CDS_NOT_SIGNED_BY_CDS
DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY
DS16_CDS_UNSIGNED
DS16_CDS_WITHOUT_DNSKEY
DS16_DELETE_CDS
DS16_DNSKEY_NOT_SIGNED_BY_CDS
DS16_MIXED_DELETE_CDS
),
],
dnssec17 => [
qw(
DS17_CDNSKEY_INVALID_RRSIG
DS17_CDNSKEY_IS_NON_SEP
DS17_CDNSKEY_IS_NON_ZONE
DS17_CDNSKEY_MATCHES_NO_DNSKEY
DS17_CDNSKEY_NOT_SIGNED_BY_CDNSKEY
DS17_CDNSKEY_SIGNED_BY_UNKNOWN_DNSKEY
DS17_CDNSKEY_UNSIGNED
DS17_CDNSKEY_WITHOUT_DNSKEY
DS17_DELETE_CDNSKEY
DS17_DNSKEY_NOT_SIGNED_BY_CDNSKEY
DS17_MIXED_DELETE_CDNSKEY
),
],
dnssec18 => [
qw(
DS18_NO_MATCH_CDS_RRSIG_DS
DS18_NO_MATCH_CDNSKEY_RRSIG_DS
),
],
};
} ## end sub metadata
Readonly my %TAG_DESCRIPTIONS => (
DNSSEC01 => sub {
__x # DNSSEC:DNSSEC01
"Legal values for the DS hash digest algorithm";
},
DNSSEC02 => sub {
__x # DNSSEC:DNSSEC02
"DS must match a valid DNSKEY in the child zone";
},
DNSSEC03 => sub {
__x # DNSSEC:DNSSEC03
"Check for too many NSEC3 iterations";
},
DNSSEC04 => sub {
__x # DNSSEC:DNSSEC04
"Check for too short or too long RRSIG lifetimes";
},
DNSSEC05 => sub {
__x # DNSSEC:DNSSEC05
"Check for invalid DNSKEY algorithms";
},
DNSSEC06 => sub {
__x # DNSSEC:DNSSEC06
"Verify DNSSEC additional processing";
},
DNSSEC07 => sub {
__x # DNSSEC:DNSSEC07
"If DNSKEY at child, parent should have DS";
},
DNSSEC08 => sub {
__x # DNSSEC:DNSSEC08
"Valid RRSIG for DNSKEY";
},
DNSSEC09 => sub {
__x # DNSSEC:DNSSEC09
"RRSIG(SOA) must be valid and created by a valid DNSKEY";
},
DNSSEC10 => sub {
__x # DNSSEC:DNSSEC10
"Zone contains NSEC or NSEC3 records";
},
DNSSEC11 => sub {
__x # DNSSEC:DNSSEC11
"DS in delegation requires signed zone";
},
DNSSEC12 => sub {
__x # DNSSEC:DNSSEC12
"Test for DNSSEC Algorithm Completeness";
},
DNSSEC13 => sub {
__x # DNSSEC:DNSSEC13
"All DNSKEY algorithms used to sign the zone";
},
DNSSEC14 => sub {
__x # DNSSEC:DNSSEC14
"Check for valid RSA DNSKEY key size";
},
DNSSEC15 => sub {
__x # DNSSEC:DNSSEC15
"Existence of CDS and CDNSKEY";
},
DNSSEC16 => sub {
__x # DNSSEC:DNSSEC16
"Validate CDS";
},
DNSSEC17 => sub {
__x # DNSSEC:DNSSEC17
"Validate CDNSKEY";
},
DNSSEC18 => sub {
__x # DNSSEC:DNSSEC18
"Validate trust from DS to CDS and CDNSKEY";
},
ADDITIONAL_DNSKEY_SKIPPED => sub {
__x # DNSSEC:ADDITIONAL_DNSKEY_SKIPPED
'No DNSKEYs found. Additional tests skipped.', @_;
},
ALGORITHM_DEPRECATED => sub {
__x # DNSSEC:ALGORITHM_DEPRECATED
'The DNSKEY with tag {keytag} uses deprecated algorithm number '
. '{algo_num} ({algo_descr}).',
@_;
},
ALGORITHM_NOT_RECOMMENDED => sub {
__x # DNSSEC:ALGORITHM_NOT_RECOMMENDED
'The DNSKEY with tag {keytag} uses an algorithm number '
. '{algo_num} ({algo_descr}) which is not recommended to be used.',
@_;
},
ALGORITHM_NOT_ZONE_SIGN => sub {
__x # DNSSEC:ALGORITHM_NOT_ZONE_SIGN
'The DNSKEY with tag {keytag} uses algorithm number not meant for '
. 'zone signing, algorithm number {algo_num} ({algo_descr}).',
@_;
},
ALGORITHM_OK => sub {
__x # DNSSEC:ALGORITHM_OK
'The DNSKEY with tag {keytag} uses algorithm number {algo_num} '
. '({algo_descr}), which is OK.',
@_;
},
ALGORITHM_PRIVATE => sub {
__x # DNSSEC:ALGORITHM_PRIVATE
'The DNSKEY with tag {keytag} uses private algorithm number '
. '{algo_num} ({algo_descr}).',
@_;
},
ALGORITHM_RESERVED => sub {
__x # DNSSEC:ALGORITHM_RESERVED
'The DNSKEY with tag {keytag} uses reserved algorithm number '
. '{algo_num} ({algo_descr}).',
@_;
},
ALGORITHM_UNASSIGNED => sub {
__x # DNSSEC:ALGORITHM_UNASSIGNED
'The DNSKEY with tag {keytag} uses unassigned algorithm number '
. '{algo_num} ({algo_descr}).',
@_;
},
DNSKEY_AND_DS => sub {
__x # DNSSEC:DNSKEY_AND_DS
'{parent} sent a DS record, and {child} a DNSKEY record.', @_;
},
DNSKEY_BUT_NOT_DS => sub {
__x # DNSSEC:DNSKEY_BUT_NOT_DS
'{child} sent a DNSKEY record, but {parent} did not send a DS record.', @_;
},
DNSKEY_SMALLER_THAN_REC => sub {
__x # DNSSEC:DNSKEY_SMALLER_THAN_REC
'DNSKEY with tag {keytag} and using algorithm {algo_num} '
. '({algo_descr}) has a size ({keysize}) smaller than the '
. 'recommended one ({keysizerec}).',
@_;
},
DNSKEY_TOO_SMALL_FOR_ALGO => sub {
__x # DNSSEC:DNSKEY_TOO_SMALL_FOR_ALGO
'DNSKEY with tag {keytag} and using algorithm {algo_num} '
. '({algo_descr}) has a size ({keysize}) smaller than the minimum '
. 'one ({keysizemin}).',
@_;
},
DNSKEY_TOO_LARGE_FOR_ALGO => sub {
__x # DNSSEC:DNSKEY_TOO_LARGE_FOR_ALGO
'DNSKEY with tag {keytag} and using algorithm {algo_num} '
. '({algo_descr}) has a size ({keysize}) larger than the maximum one '
. '({keysizemax}).',
@_;
},
DS01_DIGEST_NOT_SUPPORTED_BY_ZM => sub {
__x # DNSSEC:DS01_DIGEST_NOT_SUPPORTED_BY_ZM
'DS record for zone {domain} with keytag {keytag} was created by digest algorithm {ds_algo_num} '
. '({ds_algo_mnemo}) which cannot be validated by this installation of Zonemaster. '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS01_DS_ALGO_DEPRECATED => sub {
__x # DNSSEC:DS01_DS_ALGO_DEPRECATED
'DS record for zone {domain} with keytag {keytag} was created by digest algorithm {ds_algo_num} '
. '({ds_algo_mnemo}) which is deprecated. '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS01_DS_ALGO_2_MISSING => sub {
__x # DNSSEC:DS01_DS_ALGO_2_MISSING
'No DS record created by digest algorithm 2 (SHA-256) is present for zone {domain}.',
@_;
},
DS01_DS_ALGO_NOT_DS => sub {
__x # DNSSEC:DS01_DS_ALGO_NOT_DS
'DS record for zone {domain} with keytag {keytag} was created by digest algorithm {ds_algo_num} '
. '({ds_algo_mnemo}) which is not meant for DS. '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS01_DS_ALGO_RESERVED => sub {
__x # DNSSEC:DS01_DS_ALGO_RESERVED
'DS record for zone {domain} with keytag {keytag} was created with an unassigned digest algorithm '
. '(algorithm number {ds_algo_num}). '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS02_ALGO_NOT_SUPPORTED_BY_ZM => sub {
__x # DNSSEC:DS02_ALGO_NOT_SUPPORTED_BY_ZM
'DNSKEY with tag {keytag} uses unsupported algorithm {algo_num} '
. '({algo_mnemo}) by this installation of Zonemaster. Fetched from '
. 'the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS02_DNSKEY_NOT_FOR_ZONE_SIGNING => sub {
__x # DNSSEC:DS02_DNSKEY_NOT_FOR_ZONE_SIGNING
'Flags field of DNSKEY record with tag {keytag} has not ZONE bit set '
. 'although DS with same tag is present in parent. Fetched from '
. 'the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS02_DNSKEY_NOT_SEP => sub {
__x # DNSSEC:DS02_DNSKEY_NOT_SEP
'Flags field of DNSKEY record with tag {keytag} has not SEP bit set '
. 'although DS with same tag is present in parent. Fetched from '
. 'the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS02_DNSKEY_NOT_SIGNED_BY_ANY_DS => sub {
__x # DNSSEC:DS02_DNSKEY_NOT_SIGNED_BY_ANY_DS
'The DNSKEY RRset has not been signed by any DNSKEY matched by a DS record. '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS02_NO_DNSKEY_FOR_DS => sub {
__x # DNSSEC:DS02_NO_DNSKEY_FOR_DS
'The DNSKEY record with tag {keytag} that the DS refers to does not '
. 'exist in the DNSKEY RRset. Fetched from the nameservers with IP '
. '"{ns_ip_list}".',
@_;
},
DS02_NO_MATCHING_DNSKEY_RRSIG => sub {
__x # DNSSEC:DS02_NO_MATCHING_DNSKEY_RRSIG
'The DNSKEY RRset is not signed by the DNSKEY with tag {keytag} that '
. 'the DS record refers to. Fetched from the nameservers with IP '
. '"{ns_ip_list}".',
@_;
},
DS02_NO_MATCH_DS_DNSKEY => sub {
__x # DNSSEC:DS02_NO_MATCH_DS_DNSKEY
'The DS record does not match the DNSKEY with tag {keytag} by algorithm '
. 'or digest. Fetched from the nameservers with IP "{ns_ip_list}".',
@_;
},
DS02_NO_VALID_DNSKEY_FOR_ANY_DS => sub {
__x # DNSSEC:DS02_NO_VALID_DNSKEY_FOR_ANY_DS
'There is no valid DNSKEY matched by any of the DS records. '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS02_RRSIG_NOT_VALID_BY_DNSKEY => sub {
__x # DNSSEC:DS02_RRSIG_NOT_VALID_BY_DNSKEY
'The DNSKEY RRset is signed with an RRSIG with tag {keytag} which cannot '
. 'be validated by the matching DNSKEY. Fetched from the nameservers with IP '
. 'addresses "{ns_ip_list}".',
@_;
},
DS03_ERR_MULT_NSEC3 => sub {
__x # DNSSEC:DS03_ERR_MULT_NSEC3
'Multiple NSEC3 records when one is expected. Fetched from name servers "{ns_list}".', @_;
},
DS03_ILLEGAL_HASH_ALGO => sub {
__x # DNSSEC:DS03_ILLEGAL_HASH_ALGO
'The following servers respond with an illegal hash algorithm for NSEC3 ({algo_num}). '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_ILLEGAL_ITERATION_VALUE => sub {
__x # DNSSEC:DS03_ILLEGAL_ITERATION_VALUE
'The following servers respond with the NSEC3 iteration value {int}. '
. 'The recommended practice is to set this value to 0. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_ILLEGAL_SALT_LENGTH => sub {
__x # DNSSEC:DS03_ILLEGAL_SALT_LENGTH
'The following servers respond with a non-empty salt in NSEC3 ({int} octets). '
. 'The recommended practice is to use an empty salt. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_INCONSISTENT_HASH_ALGO => sub {
__x # DNSSEC:DS03_INCONSISTENT_HASH_ALGO
'Inconsistent hash algorithm in NSEC3 in responses for the child zone from different name servers.', @_;
},
DS03_INCONSISTENT_ITERATION => sub {
__x # DNSSEC:DS03_INCONSISTENT_ITERATION
'Inconsistent NSEC3 iteration value in responses for the child zone from different name servers.', @_;
},
DS03_INCONSISTENT_NSEC3_FLAGS => sub {
__x # DNSSEC:DS03_INCONSISTENT_NSEC3_FLAGS
'Inconsistent NSEC3 flag list in responses for the child zone from different name servers.', @_;
},
DS03_INCONSISTENT_SALT_LENGTH => sub {
__x # DNSSEC:DS03_INCONSISTENT_SALT_LENGTH
'Inconsistent salt length in NSEC3 in responses for the child zone from different name servers.', @_;
},
DS03_LEGAL_EMPTY_SALT => sub {
__x # DNSSEC:DS03_LEGAL_EMPTY_SALT
'The following servers respond with a legal empty salt in NSEC3. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_LEGAL_HASH_ALGO => sub {
__x # DNSSEC:DS03_LEGAL_HASH_ALGO
'The following servers respond with a legal hash algorithm in NSEC3. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_LEGAL_ITERATION_VALUE => sub {
__x # DNSSEC:DS03_LEGAL_ITERATION_VALUE
'The following servers respond with NSEC3 iteration value set to zero (as recommended). '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_NO_DNSSEC_SUPPORT => sub {
__x # DNSSEC:DS03_NO_DNSSEC_SUPPORT
'The zone is not DNSSEC signed or not properly DNSSEC signed. Testing for NSEC3 has been skipped. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_NO_NSEC3 => sub {
__x # DNSSEC:DS03_NO_NSEC3
'The zone does not use NSEC3. Testing for NSEC3 has been skipped. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_NSEC3_OPT_OUT_DISABLED => sub {
__x # DNSSEC:DS03_NSEC3_OPT_OUT_DISABLED
'The following servers respond with NSEC3 opt-out disabled (as recommended). '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD => sub {
__x # DNSSEC:DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD
'The following servers respond with NSEC3 opt-out enabled. '
. 'The recommended practice is to disable opt-out. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_NSEC3_OPT_OUT_ENABLED_TLD => sub {
__x # DNSSEC:DS03_NSEC3_OPT_OUT_ENABLED_TLD
'The following servers respond with NSEC3 opt-out enabled. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_SERVER_NO_DNSSEC_SUPPORT => sub {
__x # DNSSEC:DS03_SERVER_NO_DNSSEC_SUPPORT
'The following name servers do not support DNSSEC or have not been properly configured. '
. 'Testing for NSEC3 has been skipped on those servers. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_SERVER_NO_NSEC3 => sub {
__x # DNSSEC:DS03_SERVER_NO_NSEC3
'The following name servers do not use NSEC3, but others do. '
. 'Testing for NSEC3 has been skipped on the following servers. '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS03_UNASSIGNED_FLAG_USED => sub {
__x # DNSSEC:DS03_UNASSIGNED_FLAG_USED
'The following servers respond with an NSEC3 record where an unassigned flag is used (flag {int}). '
. 'Fetched from name servers "{ns_list}".',
@_;
},
DS08_ALGO_NOT_SUPPORTED_BY_ZM => sub {
__x # DNSSEC:DS08_ALGO_NOT_SUPPORTED_BY_ZM
'DNSKEY with tag {keytag} uses unsupported algorithm {algo_num} '
. '({algo_mnemo}) by this installation of Zonemaster. Fetched from '
. 'the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS08_DNSKEY_RRSIG_EXPIRED => sub {
__x # DNSSEC:DS08_DNSKEY_RRSIG_EXPIRED
'RRSIG with keytag {keytag} and covering type DNSKEY has already expired. '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS08_DNSKEY_RRSIG_NOT_YET_VALID => sub {
__x # DNSSEC:DS08_DNSKEY_RRSIG_NOT_YET_VALID
'RRSIG with keytag {keytag} and covering type DNSKEY has inception date in '
. 'the future. Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS08_MISSING_RRSIG_IN_RESPONSE => sub {
__x # DNSSEC:DS08_MISSING_RRSIG_IN_RESPONSE
'The DNSKEY RRset is not signed, which is against expectation. Fetched '
. 'from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS08_NO_MATCHING_DNSKEY => sub {
__x # DNSSEC:DS08_NO_MATCHING_DNSKEY
'The DNSKEY RRset is signed with an RRSIG with tag {keytag} which does '
. 'not match any DNSKEY record. Fetched from the nameservers with IP '
. 'addresses "{ns_ip_list}".',
@_;
},
DS08_RRSIG_NOT_VALID_BY_DNSKEY => sub {
__x # DNSSEC:DS08_RRSIG_NOT_VALID_BY_DNSKEY
'The DNSKEY RRset is signed with an RRSIG with tag {keytag} which cannot '
. 'be validated by the matching DNSKEY. Fetched from the nameservers with IP '
. 'addresses "{ns_ip_list}".',
@_;
},
DS09_ALGO_NOT_SUPPORTED_BY_ZM => sub {
__x # DNSSEC:DS09_ALGO_NOT_SUPPORTED_BY_ZM
'DNSKEY with tag {keytag} uses unsupported algorithm {algo_num} '
. '({algo_mnemo}) by this installation of Zonemaster. Fetched from '
. 'the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS09_MISSING_RRSIG_IN_RESPONSE => sub {
__x # DNSSEC:DS09_MISSING_RRSIG_IN_RESPONSE
'The SOA RRset is not signed, which is against expectation. Fetched '
. 'from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS09_NO_MATCHING_DNSKEY => sub {
__x # DNSSEC:DS09_NO_MATCHING_DNSKEY
'The SOA RRset is signed with an RRSIG with tag {keytag} which does '
. 'not match any DNSKEY record. Fetched from the nameservers with IP '
. 'addresses "{ns_ip_list}".',
@_;
},
DS09_RRSIG_NOT_VALID_BY_DNSKEY => sub {
__x # DNSSEC:DS09_RRSIG_NOT_VALID_BY_DNSKEY
'The SOA RRset is signed with an RRSIG with tag {keytag} which cannot '
. 'be validated by the matching DNSKEY. Fetched from the nameservers with IP '
. 'addresses "{ns_ip_list}".',
@_;
},
DS09_SOA_RRSIG_EXPIRED => sub {
__x # DNSSEC:DS09_SOA_RRSIG_EXPIRED
'RRSIG with keytag {keytag} and covering type SOA has already expired. '
. 'Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS09_SOA_RRSIG_NOT_YET_VALID => sub {
__x # DNSSEC:DS09_SOA_RRSIG_NOT_YET_VALID
'RRSIG with keytag {keytag} and covering type SOA has inception date in '
. 'the future. Fetched from the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS10_ALGO_NOT_SUPPORTED_BY_ZM => sub {
__x # DNSSEC:DS10_ALGO_NOT_SUPPORTED_BY_ZM
'DNSKEY with tag {keytag} uses unsupported algorithm {algo_num} '
. '({algo_mnemo}) by this installation of Zonemaster. Fetched from '
. 'the nameservers with IP addresses "{ns_ip_list}".',
@_;
},
DS10_ANSWER_VERIFY_ERROR => sub {
__x # DNSSEC:DS10_ANSWER_VERIFY_ERROR
'The name "{domain}" of RR type "{rrtype}" is signed by RRSIG, but the signature '
. 'or signatures cannot be verified. Fetched from the nameservers with '
. 'IP addresses "{ns_ip_list}".',
@_;
},
DS10_HAS_NSEC => sub {
__x # DNSSEC:DS10_HAS_NSEC
'The zone has NSEC records. Fetched from the nameservers with IP '