idnits 2.17.1 draft-ietf-dnsext-tkey-02.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** Looks like you're using RFC 2026 boilerplate. This must be updated to follow RFC 3978/3979, as updated by RFC 4748. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- ** The document seems to lack a 1id_guidelines paragraph about Internet-Drafts being working documents. ** The document seems to lack a 1id_guidelines paragraph about 6 months document validity -- however, there's a paragraph with a matching beginning. Boilerplate error? == No 'Intended status' indicated for this document; assuming Proposed Standard Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The document seems to lack separate sections for Informative/Normative References. All references will be assumed normative when checking for downward references. Miscellaneous warnings: ---------------------------------------------------------------------------- == Line 176 has weird spacing: '...-stream undef...' -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (April 2000) is 8777 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Missing Reference: 'RFC 1034' is mentioned on line 100, but not defined -- Looks like a reference, but probably isn't: '1035' on line 100 == Missing Reference: 'RFC 2535' is mentioned on line 561, but not defined ** Obsolete undefined reference: RFC 2535 (Obsoleted by RFC 4033, RFC 4034, RFC 4035) == Missing Reference: 'RFC 2136' is mentioned on line 101, but not defined == Missing Reference: 'RFC 2119' is mentioned on line 125, but not defined == Missing Reference: 'RFC 1995' is mentioned on line 127, but not defined == Missing Reference: 'RFC 1750' is mentioned on line 582, but not defined ** Obsolete undefined reference: RFC 1750 (Obsoleted by RFC 4086) == Missing Reference: 'RFC 1982' is mentioned on line 228, but not defined == Missing Reference: 'RFC 2030' is mentioned on line 237, but not defined ** Obsolete undefined reference: RFC 2030 (Obsoleted by RFC 4330) == Missing Reference: 'RFC 2104' is mentioned on line 312, but not defined == Missing Reference: 'RFC 2539' is mentioned on line 364, but not defined == Missing Reference: 'RFC 2437' is mentioned on line 574, but not defined ** Obsolete undefined reference: RFC 2437 (Obsoleted by RFC 3447) == Missing Reference: 'RFC 2434' is mentioned on line 598, but not defined ** Obsolete undefined reference: RFC 2434 (Obsoleted by RFC 5226) -- Possible downref: Non-RFC (?) normative reference: ref. 'Schneier' Summary: 9 errors (**), 0 flaws (~~), 14 warnings (==), 4 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 DNSEXT Working Group Donald E. Eastlake, 3rd 2 INTERNET-DRAFT Motorola 3 Expires: October 2000 April 2000 5 Secret Key Establishment for DNS (TKEY RR) 6 ------ --- ------------- --- --- ----- --- 7 9 Status of This Document 11 This draft is intended to be become a Proposed Standard RFC. 12 Distribution of this document is unlimited. Comments should be sent 13 to the DNS working group mailing list or 14 to the author. 16 This document is an Internet-Draft and is in full conformance with 17 all provisions of Section 10 of RFC2026. Internet-Drafts are working 18 documents of the Internet Engineering Task Force (IETF), its areas, 19 and its working groups. Note that other groups may also distribute 20 working documents as Internet-Drafts. 22 Internet-Drafts are draft documents valid for a maximum of six 23 months. Internet-Drafts may be updated, replaced, or obsoleted by 24 other documents at any time. It is not appropriate to use Internet- 25 Drafts as reference material or to cite them other than as a 26 ``working draft'' or ``work in progress.'' 28 The list of current Internet-Drafts can be accessed at 29 http://www.ietf.org/ietf/1id-abstracts.txt 31 The list of Internet-Draft Shadow Directories can be accessed at 32 http://www.ietf.org/shadow.html. 34 Abstract 36 [draft-ietf-dnsext-tsig-*.txt] provides a means of authenticating 37 Domain Name System (DNS) queries and responses using shared secret 38 keys via the TSIG resource record (RR). However, it provides no 39 mechanism for setting up such keys other than manual exchange. This 40 document describes a TKEY RR that can be used in a number of 41 different modes to establish shared secret keys between a DNS 42 resolver and server. 44 Acknowledgments 46 The comments and ideas of the following persons (listed in alphabetic 47 order) have been incorporated herein and are gratefully acknowledged: 49 Olafur Gudmundsson (TIS) 51 Stuart Kwan (Microsoft) 53 Ed Lewis (TIS) 55 Brian Wellington (TIS) 57 Table of Contents 59 Status of This Document....................................1 61 Abstract...................................................2 62 Acknowledgments............................................2 64 Table of Contents..........................................3 66 1. Introduction............................................4 67 1.1 Overview of Contents...................................4 68 2. The TKEY Resource Record................................5 69 2.1 The Name Field.........................................5 70 2.2 The TTL Field..........................................6 71 2.3 The Algorithm Field....................................6 72 2.4 The Inception and Expiration Fields....................6 73 2.5 The Mode Field.........................................7 74 2.6 The Error Field........................................7 75 2.7 The Key Size and Data Fields...........................8 76 2.8 The Other Size and Data Fields.........................8 77 3. General TKEY Considerations.............................8 78 4. Exchange via Resolver Query.............................9 79 4.1 Query for Diffie-Hellman Exchanged Keying..............9 80 4.2 Query for TKEY Deletion...............................10 81 4.3 Query for GSS-API Establishment.......................11 82 4.4 Query for Server Assigned Keying......................11 83 4.5 Query for Resolver Assigned Keying....................12 84 5. Spontaneous Server Inclusion...........................13 85 5.1 Spontaneous Server Key Deletion.......................13 86 6. Methods of Encryption..................................14 87 7. IANA Considerations....................................14 88 8. Security Considerations................................15 90 References................................................16 92 Author's Address..........................................17 93 Expiration and File Name..................................17 95 1. Introduction 97 The Domain Name System (DNS) is a hierarchical, distributed, highly 98 available database used for bi-directional mapping between domain 99 names and addresses, for email routing, and for other information 100 [RFC 1034, 1035]. It has been extended to provide for public key 101 security and dynamic update [RFC 2535, RFC 2136]. Familiarity with 102 these RFCs is assumed. 104 [draft-ietf-dnsext-tsig-*.txt] provides a means of efficiently 105 authenticating DNS messages using shared secret keys via the TSIG 106 resource record (RR) but provides no mechanism for setting up such 107 keys other than manual exchange. This document specifies a TKEY RR 108 that can be used in a number of different modes to establish and 109 delete such shared secret keys between a DNS resolver and server. 111 Note that TKEY established keying material and TSIGs that use it are 112 associated with DNS servers or resolvers. They are not associated 113 with zones. They may be used to authenticate queries and responses 114 but they do not provide zone based DNS data origin or denial 115 authentication [RFC 2535]. 117 Certain modes of TKEY perform encryption which may affect their 118 export or import status for some countries. The affected modes 119 specified in this document are the server assigned mode and the 120 resolver assigned mode. 122 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 123 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 124 document are to be interpreted as described in [RFC 2119]. 126 In all cases herein, the term "resolver" includes that part of a 127 server which may make full and incremental [RFC 1995] zone transfer 128 queries, forwards recursive queries, etc. 130 1.1 Overview of Contents 132 Section 2 below specifies the TKEY RR and provides a description of 133 and considerations for its constituent fields. 135 Section 3 describes general principles of operations with TKEY. 137 Section 4 discusses key agreement and deletion via DNS requests with 138 the Query opcode for RR type TKEY. This method is applicable to all 139 currently defined TKEY modes, although in some cases it is not what 140 would intuitively be called a "query". 142 Section 5 discusses spontaneous inclusion of TKEY RRs in responses by 143 servers which is currently used only for key deletion. 145 Section 6 describes encryption methods for transmitting secret key 146 information. In this document these are used only for the server 147 assigned mode and the resolver assigned mode. 149 Section 7 covers IANA considerations in assignment of TKEY modes. 151 Finally, Section 8 provides the required security considerations 152 section. 154 2. The TKEY Resource Record 156 The TKEY resource record (RR) has the structure given below. Its RR 157 type code is 249. 159 Field Type Comment 160 ----- ---- ------- 162 NAME domain see description below 163 TTYPE u_int16_t TKEY = 249 164 CLASS u_int16_t ignored, SHOULD be 255 (ANY) 165 TTL u_int32_t ignored, SHOULD be zero 166 RDLEN u_int16_t size of RDATA 167 RDATA: 168 Algorithm: domain 169 Inception: u_int32_t 170 Expiration: u_int32_t 171 Mode: u_int16_t 172 Error: u_int16_t 173 Key Size: u_int16_t 174 Key Data: octet-stream 175 Other Size: u_int16_t 176 Other Data: octet-stream undefined by this specification 178 2.1 The Name Field 180 The Name field relates to naming keys. Its meaning differs somewhat 181 with mode and context as explained in subsequent sections. 183 At any DNS server or resolver only one octet string of keying 184 material may be in place for any particular key name. An attempt to 185 establish another set of keying material at a server for an existing 186 name returns a BADNAME error. 188 For a TKEY with a non-root name appearing in a query, the TKEY RR 189 name SHOULD be a domain locally unique at the resolver, less than 128 190 octets long in wire encoding, and meaningful to the resolver to 191 assist in distinguishing keys and/or key agreement sessions. For 192 TKEY(s) appearing in a response to a query, the TKEY RR name SHOULD 193 be a globally unique server assigned domain. 195 A reasonable key naming strategy is as follows: 197 If the key is generated as the result of a query with root as 198 its owner name, then the server SHOULD create a globally unique 199 domain name, to be the key name, by suffixing a pseudo-random 200 [RFC 1750] label with a domain name of the server. For example 201 89n3mDgX072pp.server1.example.com. If generation of a new 202 pseudo-random name in each case is an excessive computation load 203 or entropy drain, a serial number prefix can be added to a fixed 204 pseudo-random name generated an DNS server start time, such as 205 1001.89n3mDgX072pp.server1.example.com. 207 If the key is generated as the result of a query with a non-root 208 name, say 789.resolver.example.net, then use the concatenation 209 of that with a name of the server. For example 210 789.resolver.example.net.server1.example.com. 212 2.2 The TTL Field 214 The TTL field is meaningless in TKEY RRs. It SHOULD always be zero to 215 be sure that older DNS implementations do not cache TKEY RRs. 217 2.3 The Algorithm Field 219 The algorithm name is in the form of a domain name with the same 220 meaning as in [draft-ietf-dnsext-tsig-*.txt]. The algorithm 221 determines how the secret keying material agreed to using the TKEY RR 222 is actually used to derive the algorithm specific key. 224 2.4 The Inception and Expiration Fields 226 The inception time and expiration times are in number of seconds 227 since the beginning of 1 January 1970 GMT ignoring leap seconds 228 treated as modulo 2**32 using ring arithmetic [RFC 1982]. In messages 229 between a DNS resolver and a DNS server where these fields are 230 meaningful, they are either the requested validity interval for the 231 keying material asked for or specify the validity interval of keying 232 material provided. 234 To avoid different interpretations of the inception and expiration 235 times in TKEY RRs, resolvers and servers exchanging them must have 236 the same idea of what time it is. One way of doing this is with the 237 NTP protocol [RFC 2030] but that or any other time synchronization 238 used for this purpose MUST be done securely. 240 2.5 The Mode Field 242 The mode field specifies the general scheme for key agreement or the 243 purpose of the TKEY DNS message. Servers and resolvers supporting 244 this specification MUST implement the Diffie-Hellman key agreement 245 mode and the key deletion mode for queries. All other modes are 246 OPTIONAL. A server supporting TKEY that receives a TKEY request with 247 a mode it does not support returns the BADMODE error. The following 248 values of the Mode octet are defined, available, or reserved: 250 Value Description 251 ----- ----------- 252 0 - reserved, see section 7 253 1 server assignment 254 2 Diffie-Hellman exchange 255 3 GSS-API negotiation 256 4 resolver assignment 257 5 key deletion 258 6-65534 - available, see section 7 259 65535 - reserved, see section 7 261 2.6 The Error Field 263 The error code field is an extended RCODE. The following values are 264 defined: 266 Value Description 267 ----- ----------- 268 0 - no error 269 1-15 a non-extended RCODE 270 16 BADSIG (tsig) 271 17 BADKEY (tsig) 272 18 BADTIME (tsig) 273 19 BADMODE 274 20 BADNAME 275 21 BADALG 277 When the TKEY Error Field is non-zero in a response to a TKEY query, 278 the DNS header RCODE field indicates no error. However, it is 279 possible if a TKEY is spontaneously included in a response the TKEY 280 RR and DNS header error field could have unrelated non-zero error 281 codes. 283 2.7 The Key Size and Data Fields 285 The key data size field is an unsigned 16 bit integer in network 286 order which specifies the size of the key exchange data field in 287 octets. The meaning of this data depends on the mode. 289 2.8 The Other Size and Data Fields 291 The Other Size and Other Data fields are not used in this 292 specification but may be used in future extensions. The RDLEN field 293 MUST equal the length of the RDATA section through the end of Other 294 Data or the RR is to be considered malformed and rejected. 296 3. General TKEY Considerations 298 TKEY is a meta-RR that is not stored or cached in the DNS and does 299 not appear in zone files. It supports a variety of modes for the 300 establishment and deletion of shared secret keys information between 301 DNS resolvers and servers. The establishment of such a shared key 302 requires that state be maintained at both ends and the allocation of 303 the resources to maintain such state may require mutual agreement. In 304 the absence of willingness to provide such state, servers MUST return 305 errors such as NOTIMP or REFUSED for an attempt to use TKEY and 306 resolvers are free to ignore any TKEY RRs they receive. 308 The shared secret keying material developed by using TKEY is a plain 309 octet sequence. The means by which this shared secret keying 310 material, exchanged via TKEY, is actually used in any particular TSIG 311 algorithm is algorithm dependent and is defined in connection with 312 that algorithm. For example, see [RFC 2104] for how TKEY agreed 313 shared secret keying material is used in the HMAC-MD5 algorithm or 314 other HMAC algorithms. 316 There MUST NOT be more than one TKEY RR in a DNS query or response. 318 Except for GSS-API mode, TKEY responses MUST always have DNS 319 transaction authentication to protect the integrity of any keying 320 data, error codes, etc. This authentication MUST use a previously 321 established secret (TSIG) or public (SIG(0)) key and MUST NOT use any 322 key that the response to be verified is itself providing. 324 TKEY queries MUST be authenticated for all modes except GSS-API and, 325 under some circumstances, server assignment mode. In particular, if 326 the query for a server assigned key is for a key to assert some 327 privilege, such as update authority, then the query must be 328 authenticated to avoid spoofing. However, if the key is just to be 329 used for transaction security, then spoofing will lead at worst to 330 denial of service. Query authentication SHOULD use an established 331 secret (TSIG) key authenticator if available. Otherwise, it must use 332 a public (SIG(0)) key signature. It MUST NOT use any key that the 333 query is itself providing. 335 In the absence of required TKEY authentication, a NOTAUTH error MUST 336 be returned. 338 To avoid replay attacks, it is necessary that a TKEY response or 339 query not be valid if replayed on the order of 2**32 second (about 340 136 years), or a multiple thereof, later. To accomplish this, the 341 keying material used in any TSIG or SIG(0) RR that authenticates a 342 TKEY message MUST NOT have a lifetime of more then 2**31 - 1 seconds 343 (about 68 years). Thus, on attempted replay, the authenticating TSIG 344 or SIG(0) RR will not be verifiable due to key expiration and the 345 replay will fail. 347 4. Exchange via Resolver Query 349 One method for a resolver and a server to agree about shared secret 350 keying material for use in TSIG is through DNS requests from the 351 resolver which are syntactically DNS queries for type TKEY. Such 352 queries MUST be accompanied by a TKEY RR in the additional 353 information section to indicate the mode in use and accompanied by 354 other information where required. 356 Type TKEY queries SHOULD NOT be flagged as recursive and servers MAY 357 ignore the recursive header bit in TKEY queries they receive. 359 4.1 Query for Diffie-Hellman Exchanged Keying 361 Diffie-Hellman (DH) key exchange is means whereby two parties can 362 derive some shared secret information without requiring any secrecy 363 of the messages they exchange [Schneier]. Provisions have been made 364 for the storage of DH public keys in the DNS [RFC 2539]. 366 A resolver sends a query for type TKEY accompanied by a TKEY RR in 367 the additional information section specifying the Diffie-Hellman mode 368 and accompanied by a KEY RR also in the additional information 369 section specifying a resolver Diffie-Hellman key. The TKEY RR 370 algorithm field is set to the authentication algorithm the resolver 371 plans to use. The "key data" provided in the TKEY is used as a random 372 [RFC 1750] nonce to avoid always deriving the same keying material 373 for the same pair of DH KEYs. 375 The server response contains a TKEY in its answer section with the 376 Diffie-Hellman mode. The "key data" provided in this TKEY is used as 377 an additional nonce to avoid always deriving the same keying material 378 for the same pair of DH KEYs. If the TKEY error field is non-zero, 379 the query failed for the reason given. FORMERR is given if the query 380 included no DH KEY and BADKEY is given if the query included an 381 incompatible DH KEY. 383 If the TKEY error field is zero, the resolver supplied Diffie-Hellman 384 KEY RR SHOULD be echoed in the additional information section and a 385 server Diffie-Hellman KEY RR will also be present in the answer 386 section of the response. Both parties can then calculate the same 387 shared secret quantity from the pair of Diffie-Hellman (DH) keys used 388 [Schneier] (provided these DH keys use the same generator and 389 modulus) and the data in the TKEY RRs. The TKEY RR data is mixed 390 with the DH result as follows: 392 keying material = 393 XOR ( DH value, MD5 ( query data | DH value ) | 394 MD5 ( server data | DH value ) ) 396 Where XOR is an exclusive-OR operation and "|" is byte-stream 397 concatenation. The shorter of the two operands to XOR is byte-wise 398 left justified and padded with zero-valued bytes to match the length 399 of the other operand. "DH value" is the Diffie-Hellman value derived 400 from the KEY RRs. Query data and server data are the values sent in 401 the TKEY RR data fields. These "query data" and "server data" nonces 402 are suffixed by the DH value, digested by MD5, the results 403 concatenated, and then XORed with the DH value. 405 The inception and expiry times in the query TKEY RR are those 406 requested for the keying material. The inception and expiry times in 407 the response TKEY RR are the maximum period the server will consider 408 the keying material valid. Servers may pre-expire keys so this is 409 not a guarantee. 411 4.2 Query for TKEY Deletion 413 Keys established via TKEY can be treated as soft state. Since DNS 414 transactions are originated by the resolver, the resolver can simply 415 toss keys, although it may have to go through another key exchange if 416 it later needs one. Similarly, the server can discard keys although 417 that will result in an error on receiving a query with a TSIG using 418 the discarded key. 420 To avoid attempted reliance in requests on keys no longer in effect, 421 servers MUST implement key deletion whereby the server "discards" a 422 key on receipt from a resolver of an authenticated delete request for 423 a TKEY RR with the key's name. If the server has no record of a key 424 with that name, it returns BADNAME. 426 Key deletion TKEY queries MUST be authenticated. This authentication 427 MAY be a TSIG RR using the key to be deleted. 429 For querier assigned and Diffie-Hellman keys, the server MUST truly 430 "discard" all active state associated with the key. For server 431 assigned keys, the server MAY simply mark the key as no longer 432 retained by the client and may re-send it in response to a future 433 query for server assigned keying material. 435 4.3 Query for GSS-API Establishment 437 This mode is described in a separate document under preparation which 438 should be seen for the full description. Basically the resolver and 439 server can exchange queries and responses for type TKEY with a TKEY 440 RR specifying the GSS-API mode in the additional information section 441 and a GSS-API token in the key data portion of the TKEY RR. 443 Any issues of possible encryption of parts the GSS-API token data 444 being transmitted are handled by the GSS-API level. In addition, the 445 GSS-API level provides its own authentication so that this mode of 446 TKEY query and response MAY be, but do not need to be, authenticated 447 with TSIG RR or SIG(0) RR. 449 The inception and expiry times in a GSS-API mode TKEY RR are ignored. 451 4.4 Query for Server Assigned Keying 453 Optionally, the server can assign keying for the resolver. It is 454 sent to the resolver encrypted under a resolver public key. See 455 section 6 for description of encryption methods. 457 A resolver sends a query for type TKEY accompanied by a TKEY RR 458 specifying the "server assignment" mode and a resolver KEY RR to be 459 used in encrypting the response, both in the additional information 460 section. The TKEY algorithm field is set to the authentication 461 algorithm the resolver plans to use. It is RECOMMENDED that any "key 462 data" provided in the query TKEY RR by the resolver be strongly mixed 463 by the server with server generated randomness [RFC 1750] to derive 464 the keying material to be used. The KEY RR that appears in the query 465 need not be accompanied by a SIG(KEY) RR. If the query is 466 authenticated by the resolver with a TSIG RR [draft-ietf-dnsext- 467 tsig-*.txt] or SIG(0) RR and that authentication is verified, then 468 any SIG(KEY) provided in the query SHOULD be ignored. The KEY RR in 469 such a query SHOULD have a name that corresponds to the resolver but 470 it is only essential that it be a public key for which the resolver 471 has the corresponding private key so it can decrypt the response 472 data. 474 The server response contains a TKEY RR in its answer section with the 475 server assigned mode and echoes the KEY RR provided in the query in 476 its additional information section. 478 If the reponse TKEY error field is zero, the key data portion of the 479 response TKEY RR will be the server assigned keying data encrypted 480 under the public key in the resolver provided KEY RR. In this case, 481 the owner name of the answer TKEY RR will be the server assigned name 482 of the key. 484 If the error field of the response TKEY is non-zero, the query failed 485 for the reason given. FORMERR is given if the query specified no 486 encryption key. 488 The inception and expiry times in the query TKEY RR are those 489 requested for the keying material. The inception and expiry times in 490 the response TKEY are the maximum period the server will consider the 491 keying material valid. Servers may pre-expire keys so this is not a 492 guarantee. 494 The resolver KEY RR MUST be authenticated, through the authentication 495 of this query with a TSIG or SIG(0) or the signing of the resolver 496 KEY with a SIG(KEY). Otherwise, an attacker can forge a resolver KEY 497 for which they know the private key, and thereby the attacker could 498 obtain a valid shared secret key from the server. 500 4.5 Query for Resolver Assigned Keying 502 Optionally, a server can accept resolver assigned keys. The keying 503 material must be encrypted under a server key for protection in 504 transmission as described in Section 6. 506 The resolver sends a TKEY query with a TKEY RR that specifies the 507 encrypted keying material and a KEY RR specifying the server public 508 key used to encrypt the data, both in the additional information 509 section. The name of the key and the keying data are completely 510 controlled by the sending resolver so a globally unique key name 511 SHOULD be used. The KEY RR used MUST be one for which the server has 512 the corresponding private key, or it will not be able to decrypt the 513 keying material and will return a FORMERR, and for which no untrusted 514 party (preferably no other party than the server) has the private 515 key, or the untrusted private key holder can capture the messages to 516 the server, learn the shared secret, and spoof valid TSIGs. 518 The query TKEY RR inception and expiry give the time period the 519 querier intends to consider the keying material valid. The server 520 can return a lesser time interval to advise that it will not maintain 521 state for that long and can pre-expire keys in any case. 523 This mode of query MUST be authenticated with a TSIG or SIG(0). 524 Otherwise, an attacker can forge a resolver assigned TKEY query, and 525 thereby the attacker could specify a shared secret key that would be 526 accepted, used, and honored by the server. 528 5. Spontaneous Server Inclusion 530 A DNS server may include a TKEY RR spontaneously as additional 531 information in responses. This SHOULD only be done if the server 532 knows the querier understands TKEY and has this option implemented. 533 This technique can be used to delete a key and may be specified for 534 modes defined in the future. A disadvantage of this technique is 535 that there is no way for the server to get any error or success 536 indication back and, in the case of UDP, no way to even know if the 537 DNS response reached the resolver. 539 5.1 Spontaneous Server Key Deletion 541 A server can optionally tell a client that it has deleted a secret 542 key by spontaneously including a TKEY RR in the additional 543 information section of a response with the key's name and specifying 544 the key deletion mode. Such a response SHOULD be authenticated. If 545 authenticated, it "deletes" the key with the given name. The 546 inception and expiry times of the delete TKEY RR are ignored. Failure 547 by a client to receive or properly process such additional 548 information in a response would mean that the client might use a key 549 that the server had discarded and would then get an error indication. 551 For server assigned and Diffie-Hellman keys, the client must truly 552 "discard" all active state associated with the key. For querier 553 assigned keys, the querier MAY simply mark the key as no longer 554 retained by the server and may re-send it in a future query 555 specifying querier assigned keying material. 557 6. Methods of Encryption 559 For the server assigned and resolver assigned key agreement modes, 560 the keying material is sent within the key data field of a TKEY RR 561 encrypted under the public key in an accompanying KEY RR [RFC 2535]. 562 This KEY RR MUST be for a public key algorithm where the public and 563 private keys can be used for encryption and the corresponding 564 decryption which recovers the originally encrypted data. The KEY RR 565 SHOULD correspond to a name for the decrypting resolver/server such 566 that the decrypting process has access to the corresponding private 567 key to decrypt the data. The secret keying material being sent will 568 generally be fairly short, usually less than 256 bits, because that 569 is adequate for very strong protection with modern keyed hash or 570 symmetric algorithms. 572 If the KEY RR specifies the RSA algorithm, then the keying material 573 is encrypted as per the description of RSAES-PKCS1-v1_5 encryption in 574 PKCS#1 [RFC 2437]. (Note, the secret keying material being sent is 575 directly RSA encrypted in PKCS#1 format. It is not "enveloped" under 576 some other symmetric algorithm.) In the unlikely event that the 577 keying material will not fit within one RSA modulus of the chosen 578 public key, additional RSA encryption blocks are included. The 579 length of each block is clear from the public RSA key specified and 580 the RSAES-PKCS1-v1_5 padding makes it clear what part of the 581 encrypted data is actually keying material and what part is 582 formatting or the required at least eight bytes of random [RFC 1750] 583 padding. 585 7. IANA Considerations 587 This section is to be interpreted as provided in [RFC 2434]. 589 Mode field values 0x0000 through 0x00FF, and 0XFF00 through 0XFFFF 590 can only be assigned by an IETF standards action. Special 591 consideration should be given before the allocation of meaning for 592 Mode field values 0x0000 and 0xFFFF. 594 Mode field values 0x0100 through 0x0FFF and 0xF0000 through 0xFEFF 595 are allocated by IESG approval or IETF consensus. 597 Mode field values 0x1000 through 0xEFFF are allocated based on 598 Specification Required as defined in [RFC 2434]. 600 Mode values should not be changed when the status of their use 601 changes. For example, a mode value assigned for an Experimental 602 Standard should not be changed later just because that standard's 603 status is changed to Proposed. 605 The following assignments are documented herein: 607 RR Type 249 for TKEY. 609 TKEY Modes 1 through 5 as listed in section 2.5. 611 Extended RCODE Error values of 19, 20, and 21 as listed in 612 section 2.6. 614 8. Security Considerations 616 The entirety of this specification is concerned with the secure 617 establishment of a shared secret between DNS clients and servers in 618 support of TSIG [draft-ietf-dnsext-tsig-*.txt]. 620 Protection against denial of service via the use of TKEY is not 621 provided. 623 References 625 [Schneier] - Bruce Schneier, "Applied Cryptography: Protocols, 626 Algorithms, and Source Code in C", 1996, John Wiley and Sons 628 RFC 1034 - P. Mockapetris, "Domain Names - Concepts and Facilities", 629 STD 13, November 1987. 631 RFC 1035 - P. Mockapetris, "Domain Names - Implementation and 632 Specifications", STD 13, November 1987. 634 RFC 1750 - D. Eastlake, S. Crocker & J. Schiller, "Randomness 635 Recommendations for Security", December 1994. 637 RFC 1982 - Robert Elz, Randy Bush, "Serial Number Arithmetic", 638 09/03/1996. 640 RFC 1995 - Masataka Ohta, "Incremental Zone Transfer in DNS", August 641 1996. 643 RFC 2030 - D. Mills, "Simple Network Time Protocol (SNTP) Version 4 644 for IPv4, IPv6 and OSI", October 1996. 646 RFC 2104 - H. Krawczyk, M. Bellare, R. Canetti, "HMAC: Keyed-Hashing 647 for Message Authentication", February 1997. 649 RFC 2119 - S. Bradner, "Key words for use in RFCs to Indicate 650 Requirement Levels", March 1997. 652 RFC 2136 - P. Vixie, S. Thomson, Y. Rekhter, J. Bound, "Dynamic 653 Updates in the Domain Name System (DNS UPDATE)", 04/21/1997. 655 RFC 2434 - T. Narten, H. Alvestrand, "Guidelines for Writing an IANA 656 Considerations Section in RFCs, October 1998. 658 RFC 2437 - B. Kaliski, J. Staddon, "PKCS #1: RSA Cryptography 659 Specifications Version 2.0", October 1998. 661 RFC 2535 - D. Eastlake, "Domain Name System Security Extensions", 662 March 1999. 664 RFC 2539 - D. Eastlake, "Storage of Diffie-Hellman Keys in the Domain 665 Name System (DNS)", March 1999. 667 draft-ietf-dnsext-tsig-*.txt - P. Vixie, O. Gudmundsson, D. 668 Eastlake, "Secret Key Transaction Signatures for DNS (TSIG)". 670 Author's Address 672 Donald E. Eastlake 3rd 673 Motorola 674 65 Shindegan Hill Road, RR #1 675 Carmel, NY 10512 USA 677 Telephone: +1 914-276-2668 (h) 678 +1 508-261-5434 (w) 679 FAX: +1 508-261-4447 (w) 680 email: Donald.Eastlake@motorola.com 682 Expiration and File Name 684 This draft expires October 2000. 686 Its file name is draft-ietf-dnsext-tkey-02.txt.