]> CyberLeo.Net >> Repos - FreeBSD/releng/8.1.git/blob - contrib/bind9/NSEC3-NOTES
Copy stable/8 to releng/8.1 in preparation for 8.1-RC1.
[FreeBSD/releng/8.1.git] / contrib / bind9 / NSEC3-NOTES
1
2                         DNSSEC and UPDATE
3
4                 Converting from insecure to secure
5
6 As of BIND 9.6.0 it is possible to move a zone between being insecure
7 to secure and back again.  A secure zone can be using NSEC or NSEC3.
8
9 To move a zone from insecure to secure you need to configure named
10 so that it can see the K* files which contain the public and private
11 parts of the keys that will be used to sign the zone.  These files
12 will have been generated by dnssec-keygen.  You can do this by
13 placing them in the key-directory as specified in named.conf.
14
15         zone example.net {
16                 type master;
17                 allow-update { .... };
18                 file "dynamic/example.net/example.net";
19                 key-directory "dynamic/example.net";
20         };
21
22 Assuming one KSK and one ZSK DNSKEY key have been generated.  Then
23 this will cause the zone to be signed with the ZSK and the DNSKEY
24 RRset to be signed with the KSK DNSKEY.  A NSEC chain will also be
25 generated as part of the initial signing process.
26
27         % nsupdate
28         > ttl 3600
29         > update add example.net DNSKEY 256 3 7 AwEAAZn17pUF0KpbPA2c7Gz76Vb18v0teKT3EyAGfBfL8eQ8al35zz3Y I1m/SAQBxIqMfLtIwqWPdgthsu36azGQAX8=
30         > update add example.net DNSKEY 257 3 7 AwEAAd/7odU/64o2LGsifbLtQmtO8dFDtTAZXSX2+X3e/UNlq9IHq3Y0 XtC0Iuawl/qkaKVxXe2lo8Ct+dM6UehyCqk=
31         > send
32
33 While the update request will complete almost immediately the zone
34 will not be completely signed until named has had time to walk the
35 zone and generate the NSEC and RRSIG records.  Initially the NSEC
36 record at the zone apex will have the OPT bit set.  When the NSEC
37 chain is complete the OPT bit will be cleared.  Additionally when
38 the zone is fully signed the private type (default TYPE65534) records
39 will have a non zero value for the final octet. 
40
41 The private type record has 5 octets.
42         algorithm (octet 1)
43         key id in network order (octet 2 and 3)
44         removal flag (octet 4)
45         complete flag (octet 5)
46
47 If you wish to go straight to a secure zone using NSEC3 you should
48 also add a NSEC3PARAM record to the update request with the flags
49 field set to indicate whether the NSEC3 chain will have the OPTOUT
50 bit set or not.
51
52         % nsupdate
53         > ttl 3600
54         > update add example.net DNSKEY 256 3 7 AwEAAZn17pUF0KpbPA2c7Gz76Vb18v0teKT3EyAGfBfL8eQ8al35zz3Y I1m/SAQBxIqMfLtIwqWPdgthsu36azGQAX8=
55         > update add example.net DNSKEY 257 3 7 AwEAAd/7odU/64o2LGsifbLtQmtO8dFDtTAZXSX2+X3e/UNlq9IHq3Y0 XtC0Iuawl/qkaKVxXe2lo8Ct+dM6UehyCqk=
56         > update add example.net NSEC3PARAM 1 1 100 1234567890
57         > send
58
59 Again the update request will complete almost immediately however the
60 NSEC3PARAM record will have additional flag bits set indicating that the
61 NSEC3 chain is under construction.  When the NSEC3 chain is complete the
62 flags field will be set to zero. 
63
64 While the initial signing and NSEC/NSEC3 chain generation is happening
65 other updates are possible.
66
67                 DNSKEY roll overs via UPDATE
68
69 It is possible to perform key rollovers via update.  You need to
70 add the K* files for the new keys so that named can find them.  You
71 can then add the new DNSKEY RRs via update.  Named will then cause
72 the zone to be signed with the new keys.  When the signing is
73 complete the private type records will be updated so that the last
74 octet is non zero.
75
76 If this is for a KSK you need to inform the parent and any trust
77 anchor repositories of the new KSK.
78
79 You should then wait for the maximum TLL in the zone before removing the
80 old DNSKEY.  If it is a KSK that is being updated you also need to wait
81 for the DS RRset in the parent to be updated and its TTL to expire.
82 This ensures that all clients will be able to verify at least a signature
83 when you remove the old DNSKEY.
84
85 The old DNSKEY can be removed via UPDATE.  Take care to specify
86 the correct key.  Named will clean out any signatures generated by
87 the old key after the update completes.
88
89                 NSEC3PARAM rollovers via UPDATE.
90
91 Add the new NSEC3PARAM record via update.  When the new NSEC3 chain
92 has been generated the NSEC3PARAM flag field will be zero.  At this
93 point you can remove the old NSEC3PARAM record.  The old chain will
94 be removed after the update request completes.
95
96                 Converting from NSEC to NSEC3
97
98 To do this you just need to add a NSEC3PARAM record.  When the
99 conversion is complete the NSEC chain will have been removed and
100 the NSEC3PARAM record will have a zero flag field.  The NSEC3 chain
101 will be generated before the NSEC chain is destroyed.
102
103                 Converting from NSEC3 to NSEC
104
105 To do this remove all NSEC3PARAM records with a zero flag field.  The
106 NSEC chain will be generated before the NSEC3 chain is removed.
107
108                 Converting from secure to insecure
109
110 To do this remove all the DNSKEY records.  Any NSEC or NSEC3 chains
111 will be removed as well as associated NSEC3PARAM records.  This will
112 take place after the update requests completes.
113
114                 Periodic re-signing.
115
116 Named will periodically re-sign RRsets which have not been re-signed
117 as a result of some update action.  The signature lifetimes will
118 be adjusted so as to spread the re-sign load over time rather than
119 all at once.
120
121                 NSEC3 and OPTOUT
122
123 Named only supports creating new NSEC3 chains where all the NSEC3
124 records in the zone have the same OPTOUT state.  Named supports
125 UPDATES to zones where the NSEC3 records in the chain have mixed
126 OPTOUT state.  Named does not support changing the OPTOUT state of
127 an individual NSEC3 record, the entire chain needs to be changed if
128 the OPTOUT state of an individual NSEC3 needs to be changed.