]> CyberLeo.Net >> Repos - FreeBSD/releng/7.2.git/blob - contrib/bind9/doc/rfc/rfc2137.txt
Create releng/7.2 from stable/7 in preparation for 7.2-RELEASE.
[FreeBSD/releng/7.2.git] / contrib / bind9 / doc / rfc / rfc2137.txt
1
2
3
4
5
6
7 Network Working Group                                    D. Eastlake 3rd
8 Request for Comments: 2137                               CyberCash, Inc.
9 Updates: 1035                                                 April 1997
10 Category: Standards Track
11
12
13                 Secure Domain Name System Dynamic Update
14
15 Status of this Memo
16
17    This document specifies an Internet standards track protocol for the
18    Internet community, and requests discussion and suggestions for
19    improvements.  Please refer to the current edition of the "Internet
20    Official Protocol Standards" (STD 1) for the standardization state
21    and status of this protocol.  Distribution of this memo is unlimited.
22
23 Abstract
24
25    Domain Name System (DNS) protocol extensions have been defined to
26    authenticate the data in DNS and provide key distribution services
27    [RFC2065].  DNS Dynamic Update operations have also been defined
28    [RFC2136], but without a detailed description of security for the
29    update operation.  This memo describes how to use DNSSEC digital
30    signatures covering requests and data to secure updates and restrict
31    updates to those authorized to perform them as indicated by the
32    updater's possession of cryptographic keys.
33
34 Acknowledgements
35
36    The contributions of the following persons (who are listed in
37    alphabetic order) to this memo are gratefully acknowledged:
38
39          Olafur Gudmundsson (ogud@tis.com>
40          Charlie Kaufman <Charlie_Kaufman@iris.com>
41          Stuart Kwan <skwan@microsoft.com>
42          Edward Lewis <lewis@tis.com>
43
44 Table of Contents
45
46       1. Introduction............................................2
47       1.1 Overview of DNS Dynamic Update.........................2
48       1.2 Overview of DNS Security...............................2
49       2. Two Basic Modes.........................................3
50       3. Keys....................................................5
51       3.1 Update Keys............................................6
52       3.1.1 Update Key Name Scope................................6
53       3.1.2 Update Key Class Scope...............................6
54       3.1.3 Update Key Signatory Field...........................6
55
56
57
58 Eastlake                    Standards Track                     [Page 1]
59 \f
60 RFC 2137                         SDNSDU                       April 1997
61
62
63       3.2 Zone Keys and Update Modes.............................8
64       3.3 Wildcard Key Punch Through.............................9
65       4. Update Signatures.......................................9
66       4.1 Update Request Signatures..............................9
67       4.2 Update Data Signatures................................10
68       5. Security Considerations................................10
69       References................................................10
70       Author's Address..........................................11
71
72 1. Introduction
73
74    Dynamic update operations have been defined for the Domain Name
75    System (DNS) in RFC 2136, but without a detailed description of
76    security for those updates.  Means of securing the DNS and using it
77    for key distribution have been defined in RFC 2065.
78
79    This memo proposes techniques based on the defined DNS security
80    mechanisms to authenticate DNS updates.
81
82    Familiarity with the DNS system [RFC 1034, 1035] is assumed.
83    Familiarity with the DNS security and dynamic update proposals will
84    be helpful.
85
86 1.1 Overview of DNS Dynamic Update
87
88    DNS dynamic update defines a new DNS opcode, new DNS request and
89    response structure if that opcode is used, and new error codes.  An
90    update can specify complex combinations of deletion and insertion
91    (with or without pre-existence testing) of resource records (RRs)
92    with one or more owner names; however, all testing and changes for
93    any particular DNS update request are restricted to a single zone.
94    Updates occur at the primary server for a zone.
95
96    The primary server for a secure dynamic zone must increment the zone
97    SOA serial number when an update occurs or the next time the SOA is
98    retrieved if one or more updates have occurred since the previous SOA
99    retrieval and the updates themselves did not update the SOA.
100
101 1.2 Overview of DNS Security
102
103    DNS security authenticates data in the DNS by also storing digital
104    signatures in the DNS as SIG resource records (RRs).  A SIG RR
105    provides a digital signature on the set of all RRs with the same
106    owner name and class as the SIG and whose type is the type covered by
107    the SIG.  The SIG RR cryptographically binds the covered RR set to
108    the signer, time signed, signature expiration date, etc.  There are
109    one or more keys associated with every secure zone and all data in
110    the secure zone is signed either by a zone key or by a dynamic update
111
112
113
114 Eastlake                    Standards Track                     [Page 2]
115 \f
116 RFC 2137                         SDNSDU                       April 1997
117
118
119    key tracing its authority to a zone key.
120
121    DNS security also defines transaction SIGs and request SIGs.
122    Transaction SIGs appear at the end of a response.  Transaction SIGs
123    authenticate the response and bind it to the corresponding request
124    with the key of the host where the responding DNS server is.  Request
125    SIGs appear at the end of a request and authenticate the request with
126    the key of the submitting entity.
127
128    Request SIGs are the primary means of authenticating update requests.
129
130    DNS security also permits the storage of public keys in the DNS via
131    KEY RRs.  These KEY RRs are also, of course, authenticated by SIG
132    RRs.  KEY RRs for zones are stored in their superzone and subzone
133    servers, if any, so that the secure DNS tree of zones can be
134    traversed by a security aware resolver.
135
136 2. Two Basic Modes
137
138    A dynamic secure zone is any secure DNS zone containing one or more
139    KEY RRs that can authorize dynamic updates, i.e., entity or user KEY
140    RRs with the signatory field non-zero, and whose zone KEY RR
141    signatory field indicates that updates are implemented. There are two
142    basic modes of dynamic secure zone which relate to the update
143    strategy, mode A and mode B.  A summary comparison table is given
144    below and then each mode is described.
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 Eastlake                    Standards Track                     [Page 3]
171 \f
172 RFC 2137                         SDNSDU                       April 1997
173
174
175                    SUMMARY OF DYNAMIC SECURE ZONE MODES
176
177    CRITERIA:                |   MODE A           |   MODE B
178    =========================+====================+===================
179    Definition:              | Zone Key Off line  | Zone Key On line
180    =========================+====================+===================
181    Server Workload          |   Low              |   High
182    -------------------------+--------------------+-------------------
183    Static Data Security     |   Very High        |   Medium-High
184    -------------------------+--------------------+-------------------
185    Dynamic Data Security    |   Medium           |   Medium-High
186    -------------------------+--------------------+-------------------
187    Key Restrictions         |   Fine grain       |   Coarse grain
188    -------------------------+--------------------+-------------------
189    Dynamic Data Temporality |   Transient        |   Permanent
190    -------------------------+--------------------+-------------------
191    Dynamic Key Rollover     |   No               |   Yes
192    -------------------------+--------------------+-------------------
193
194    For mode A, the zone owner key and static zone master file are always
195    kept off-line for maximum security of the static zone contents.
196
197    As a consequence, any dynamicly added or changed RRs are signed in
198    the secure zone by their authorizing dynamic update key and they are
199    backed up, along with this SIG RR, in a separate online dynamic
200    master file.  In this type of zone, server computation is minimized
201    since the server need only check signatures on the update data and
202    request, which have already been signed by the updater, generally a
203    much faster operation than signing data.  However, the AXFR SIG and
204    NXT RRs which covers the zone under the zone key will not cover
205    dynamically added data.  Thus, for type A dynamic secure zones, zone
206    transfer security is not automatically provided for dynamically added
207    RRs, where they could be omitted, and authentication is not provided
208    for the server denial of the existence of a dynamically added type.
209    Because the dynamicly added RRs retain their update KEY signed SIG,
210    finer grained control of updates can be implemented via bits in the
211    KEY RR signatory field.  Because dynamic data is only stored in the
212    online dynamic master file and only authenticated by dynamic keys
213    which expire, updates are transient in nature.  Key rollover for an
214    entity that can authorize dynamic updates is more cumbersome since
215    the authority of their key must be traceable to a zone key and so, in
216    general, they must securely communicate a new key to the zone
217    authority for manual transfer to the off line static master file.
218    NOTE: for this mode the zone SOA must be signed by a dynamic update
219    key and that private key must be kept on line so that the SOA can be
220    changed for updates.
221
222
223
224
225
226 Eastlake                    Standards Track                     [Page 4]
227 \f
228 RFC 2137                         SDNSDU                       April 1997
229
230
231    For mode B, the zone owner key and master file are kept on-line at
232    the zone primary server. When authenticated updates succeed, SIGs
233    under the zone key for the resulting data (including the possible NXT
234    type bit map changes) are calculated and these SIG (and possible NXT)
235    changes are entered into the zone and the unified on-line master
236    file.  (The zone transfer AXFR SIG may be recalculated for each
237    update or on demand when a zone transfer is requested and it is out
238    of date.)
239
240    As a consequence, this mode requires considerably more computational
241    effort on the part of the server as the public/private keys are
242    generally arranged so that signing (calculating a SIG) is more effort
243    than verifying a signature.  The security of static data in the zone
244    is decreased because the ultimate state of the static data being
245    served and the ultimate zone authority private key are all on-line on
246    the net.  This means that if the primary server is subverted, false
247    data could be authenticated to secondaries and other
248    servers/resolvers.  On the other hand, this mode of operation means
249    that data added dynamically is more secure than in mode A.  Dynamic
250    data will be covered by the AXFR SIG and thus always protected during
251    zone transfers and will be included in NXT RRs so that it can be
252    falsely denied by a server only to the same extent that static data
253    can (i.e., if it is within a wild card scope). Because the zone key
254    is used to sign all the zone data, the information as to who
255    originated the current state of dynamic RR sets is lost, making
256    unavailable the effects of some of the update control bits in the KEY
257    RR signatory field.  In addition, the incorporation of the updates
258    into the primary master file and their authentication by the zone key
259    makes then permanent in nature.  Maintaining the zone key on-line
260    also means that dynamic update keys which are signed by the zone key
261    can be dynamically updated since the zone key is available to
262    dynamically sign new values.
263
264    NOTE:  The Mode A / Mode B distinction only effects the validation
265    and performance of update requests.  It has no effect on retrievals.
266    One reasonable operational scheme may be to keep a mostly static main
267    zone operating in Mode A and have one or more dynamic subzones
268    operating in Mode B.
269
270 3. Keys
271
272    Dynamic update requests depend on update keys as described in section
273    3.1 below.  In addition, the zone secure dynamic update mode and
274    availability of some options is indicated in the zone key.  Finally,
275    a special rule is used in searching for KEYs to validate updates as
276    described in section 3.3.
277
278
279
280
281
282 Eastlake                    Standards Track                     [Page 5]
283 \f
284 RFC 2137                         SDNSDU                       April 1997
285
286
287 3.1 Update Keys
288
289    All update requests to a secure zone must include signatures by one
290    or more key(s) that together can authorize that update.  In order for
291    the Domain Name System (DNS) server receiving the request to confirm
292    this, the key or keys must be available to and authenticated by that
293    server as a specially flagged KEY Resource Record.
294
295    The scope of authority of such keys is indicated by their KEY RR
296    owner name, class, and signatory field flags as described below. In
297    addition, such KEY RRs must be entity or user keys and not have the
298    authentication use prohibited bit on.  All parts of the actual update
299    must be within the scope of at least one of the keys used for a
300    request SIG on the update request as described in section 4.
301
302 3.1.1 Update Key Name Scope
303
304    The owner name of any update authorizing KEY RR must (1) be the same
305    as the owner name of any RRs being added or deleted or (2) a wildcard
306    name including within its extended scope (see section 3.3) the name
307    of any RRs being added or deleted and those RRs must be in the same
308    zone.
309
310 3.1.2 Update Key Class Scope
311
312    The class of any update authorizing KEY RR must be the same as the
313    class of any RR's being added or deleted.
314
315 3.1.3 Update Key Signatory Field
316
317    The four bit "signatory field" (see RFC 2065) of any update
318    authorizing KEY RR must be non-zero.  The bits have the meanings
319    described below for non-zone keys (see section 3.2 for zone type
320    keys).
321
322                     UPDATE KEY RR SIGNATORY FIELD BITS
323
324          0           1           2           3
325    +-----------+-----------+-----------+-----------+
326    |   zone    |  strong   |  unique   |  general  |
327    +-----------+-----------+-----------+-----------+
328
329    Bit 0, zone control - If nonzero, this key is authorized to attach,
330         detach, and move zones by creating and deleting NS, glue A, and
331         zone KEY RR(s).  If zero, the key can not authorize any update
332         that would effect such RRs.  This bit is meaningful for both
333         type A and type B dynamic secure zones.
334
335
336
337
338 Eastlake                    Standards Track                     [Page 6]
339 \f
340 RFC 2137                         SDNSDU                       April 1997
341
342
343         NOTE:  do not confuse the "zone" signatory field bit with the
344         "zone" key type bit.
345
346    Bit 1, strong update - If nonzero, this key is authorized to add and
347         delete RRs even if there are other RRs with the same owner name
348         and class that are authenticated by a SIG signed with a
349         different dynamic update KEY. If zero, the key can only
350         authorize updates where any existing RRs of the same owner and
351         class are authenticated by a SIG using the same key.  This bit
352         is meaningful only for type A dynamic zones and is ignored in
353         type B dynamic zones.
354
355         Keeping this bit zero on multiple KEY RRs with the same or
356         nested wild card owner names permits multiple entities to exist
357         that can create and delete names but can not effect RRs with
358         different owner names from any they created.  In effect, this
359         creates two levels of dynamic update key, strong and weak, where
360         weak keys are limited in interfering with each other but a
361         strong key can interfere with any weak keys or other strong
362         keys.
363
364    Bit 2, unique name update - If nonzero, this key is authorized to add
365         and update RRs for only a single owner name.  If there already
366         exist RRs with one or more names signed by this key, they may be
367         updated but no new name created until the number of existing
368         names is reduced to zero.  This bit is meaningful only for mode
369         A dynamic zones and is ignored in mode B dynamic zones. This bit
370         is meaningful only if the owner name is a wildcard.  (Any
371         dynamic update KEY with a non-wildcard name is, in effect, a
372         unique name update key.)
373
374         This bit can be used to restrict a KEY from flooding a zone with
375         new names.  In conjunction with a local administratively imposed
376         limit on the number of dynamic RRs with a particular name, it
377         can completely restrict a KEY from flooding a zone with RRs.
378
379    Bit 3, general update - The general update signatory field bit has no
380         special meaning.  If the other three bits are all zero, it must
381         be one so that the field is non-zero to designate that the key
382         is an update key.  The meaning of all values of the signatory
383         field with the general bit and one or more other signatory field
384         bits on is reserved.
385
386    All the signatory bit update authorizations described above only
387    apply if the update is within the name and class scope as per
388    sections 3.1.1 and 3.1.2.
389
390
391
392
393
394 Eastlake                    Standards Track                     [Page 7]
395 \f
396 RFC 2137                         SDNSDU                       April 1997
397
398
399 3.2 Zone Keys and Update Modes
400
401    Zone type keys are automatically authorized to sign anything in their
402    zone, of course, regardless of the value of their signatory field.
403    For zone keys, the signatory field bits have different means than
404    they they do for update keys, as shown below.  The signatory field
405    MUST be zero if dynamic update is not supported for a zone and MUST
406    be non-zero if it is.
407
408                      ZONE KEY RR SIGNATORY FIELD BITS
409
410                   0           1           2           3
411             +-----------+-----------+-----------+-----------+
412             |   mode    |  strong   |  unique   |  general  |
413             +-----------+-----------+-----------+-----------+
414
415    Bit 0, mode - This bit indicates the update mode for this zone.  Zero
416         indicates mode A while a one indicates mode B.
417
418    Bit 1, strong update - If nonzero, this indicates that the "strong"
419         key feature described in section 3.1.3 above is implemented and
420         enabled for this secure zone.  If zero, the feature is not
421         available.  Has no effect if the zone is a mode B secure update
422         zone.
423
424    Bit 2, unique name update - If nonzero, this indicates that the
425         "unique name" feature described in section 3.1.3 above is
426         implemented and enabled for this secure zone.  If zero, this
427         feature is not available.  Has no effect if the zone is a mode B
428         secure update zone.
429
430    Bit 3, general - This bit has no special meeting.  If dynamic update
431         for a zone is supported and the other bits in the zone key
432         signatory field are zero, it must be a one.  The meaning of zone
433         keys where the signatory field has the general bit and one or
434         more other bits on is reserved.
435
436    If there are multiple dynamic update KEY RRs for a zone and zone
437    policy is in transition, they might have different non-zero signatory
438    fields.  In that case, strong and unique name restrictions must be
439    enforced as long as there is a non-expired zone key being advertised
440    that indicates mode A with the strong or unique name bit on
441    respectively.  Mode B updates MUST be supported as long as there is a
442    non-expired zone key that indicates mode B.  Mode A updates may be
443    treated as mode B updates at server option if non-expired zone keys
444    indicate that both are supported.
445
446
447
448
449
450 Eastlake                    Standards Track                     [Page 8]
451 \f
452 RFC 2137                         SDNSDU                       April 1997
453
454
455    A server that will be executing update operations on a zone, that is,
456    the primary master server, MUST not advertize a zone key that will
457    attract requests for a mode or features that it can not support.
458
459 3.3 Wildcard Key Punch Through
460
461    Just as a zone key is valid throughout the entire zone, update keys
462    with wildcard names are valid throughout their extended scope, within
463    the zone. That is, they remain valid for any name that would match
464    them, even existing specific names within their apparent scope.
465
466    If this were not so, then whenever a name within a wildcard scope was
467    created by dynamic update, it would be necessary to first create a
468    copy of the KEY RR with this name, because otherwise the existence of
469    the more specific name would hide the authorizing KEY RR and would
470    make later updates impossible.  An updater could create such a KEY RR
471    but could not zone sign it with their authorizing signer.  They would
472    have to sign it with the same key using the wildcard name as signer.
473    Thus in creating, for example, one hundred type A RRs authorized by a
474    *.1.1.1.in-addr.arpa. KEY RR, without key punch through 100 As, 100
475    KEYs, and 200 SIGs would have to be created as opposed to merely 100
476    As and 100 SIGs with key punch through.
477
478 4. Update Signatures
479
480    Two kinds of signatures can appear in updates.  Request signatures,
481    which are always required, cover the entire request and authenticate
482    the DNS header, including opcode, counts, etc., as well as the data.
483    Data signatures, on the other hand, appear only among the RRs to be
484    added and are only required for mode A operation.  These two types of
485    signatures are described further below.
486
487 4.1 Update Request Signatures
488
489    An update can effect multiple owner names in a zone.  It may be that
490    these different names are covered by different dynamic update keys.
491    For every owner name effected, the updater must know a private key
492    valid for that name (and the zone's class) and must prove this by
493    appending request SIG RRs under each such key.
494
495    As specified in RFC 2065, a request signature is a SIG RR occurring
496    at the end of a request with a type covered field of zero.  For an
497    update, request signatures occur in the Additional information
498    section.  Each request SIG signs the entire request, including DNS
499    header, but excluding any other request SIG(s) and with the ARCOUNT
500    in the DNS header set to what it wold be without the request SIGs.
501
502
503
504
505
506 Eastlake                    Standards Track                     [Page 9]
507 \f
508 RFC 2137                         SDNSDU                       April 1997
509
510
511 4.2 Update Data Signatures
512
513    Mode A dynamic secure zones require that the update requester provide
514    SIG RRs that will authenticate the after update state of all RR sets
515    that are changed by the update and are non-empty after the update.
516    These SIG RRs appear in the request as RRs to be added and the
517    request must delete any previous data SIG RRs that are invalidated by
518    the request.
519
520    In Mode B dynamic secure zones, all zone data is authenticated by
521    zone key SIG RRs.  In this case, data signatures need not be included
522    with the update.  A resolver can determine which mode an updatable
523    secure zone is using by examining the signatory field bits of the
524    zone KEY RR (see section 3.2).
525
526 5. Security Considerations
527
528    Any zone permitting dynamic updates is inherently less secure than a
529    static secure zone maintained off line as recommended in RFC 2065. If
530    nothing else, secure dynamic update requires on line change to and
531    re-signing of the zone SOA resource record (RR) to increase the SOA
532    serial number.  This means that compromise of the primary server host
533    could lead to arbitrary serial number changes.
534
535    Isolation of dynamic RRs to separate zones from those holding most
536    static RRs can limit the damage that could occur from breach of a
537    dynamic zone's security.
538
539 References
540
541    [RFC2065] Eastlake, D., and C. Kaufman, "Domain Name System Security
542    Extensions", RFC 2065, CyberCash, Iris, January 1997.
543
544    [RFC2136] Vixie, P., Editor, Thomson, T., Rekhter, Y., and J. Bound,
545    "Dynamic Updates in the Domain Name System (DNS UPDATE)", RFC 2136,
546    April 1997.
547
548    [RFC1035] Mockapetris, P., "Domain Names - Implementation and
549    Specifications", STD 13, RFC 1035, November 1987.
550
551    [RFC1034] Mockapetris, P., "Domain Names - Concepts and Facilities",
552    STD 13, RFC 1034, November 1987.
553
554
555
556
557
558
559
560
561
562 Eastlake                    Standards Track                    [Page 10]
563 \f
564 RFC 2137                         SDNSDU                       April 1997
565
566
567 Author's Address
568
569    Donald E. Eastlake, 3rd
570    CyberCash, Inc.
571    318 Acton Street
572    Carlisle, MA 01741 USA
573
574    Phone:   +1 508-287-4877
575             +1 508-371-7148 (fax)
576             +1 703-620-4200 (main office, Reston, Virginia, USA)
577    EMail:   dee@cybercash.com
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 Eastlake                    Standards Track                    [Page 11]
619 \f