idnits 2.17.1 draft-ietf-dnssd-push-00.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Using lowercase 'not' together with uppercase 'MUST', 'SHALL', 'SHOULD', or 'RECOMMENDED' is not an accepted usage according to RFC 2119. Please use uppercase 'NOT' together with RFC 2119 keywords (if that is what you mean). Found 'MUST not' in this paragraph: A client MUST not send a SUBSCRIBE message that duplicates the name, type and class of an existing active subscription. For the purpose of this matching, the established DNS case-insensitivity for US-ASCII letters applies (e.g., "foo.com" and "Foo.com" are the same). If a server receives such a duplicate SUBSCRIBE message this is an error and the server MUST immediately close the TCP connection. == Using lowercase 'not' together with uppercase 'MUST', 'SHALL', 'SHOULD', or 'RECOMMENDED' is not an accepted usage according to RFC 2119. Please use uppercase 'NOT' together with RFC 2119 keywords (if that is what you mean). Found 'MUST not' in this paragraph: A client MUST not send an UNSUBSCRIBE message that does not exactly match the name, type and class of an existing active subscription. If a server receives such an UNSUBSCRIBE message this is an error and the server MUST immediately close the TCP connection. -- The document date (March 9, 2015) is 3326 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) == Outdated reference: A later version (-14) exists of draft-ietf-dane-srv-11 == Outdated reference: A later version (-28) exists of draft-ietf-tls-tls13-04 ** Obsolete normative reference: RFC 793 (Obsoleted by RFC 9293) ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) ** Obsolete normative reference: RFC 5966 (Obsoleted by RFC 7766) ** Obsolete normative reference: RFC 6195 (Obsoleted by RFC 6895) == Outdated reference: A later version (-10) exists of draft-ietf-dnssd-hybrid-00 == Outdated reference: A later version (-06) exists of draft-sekar-dns-llq-01 Summary: 4 errors (**), 0 flaws (~~), 7 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Internet Engineering Task Force T. Pusateri 3 Internet-Draft Seeking affiliation 4 Intended status: Standards Track S. Cheshire 5 Expires: September 10, 2015 Apple Inc. 6 March 9, 2015 8 DNS Push Notifications 9 draft-ietf-dnssd-push-00 11 Abstract 13 The Domain Name System (DNS) was designed to efficiently return 14 matching records for queries for data that is relatively static. 15 When those records change frequently, DNS is still efficient at 16 returning the updated results when polled. But there exists no 17 mechanism for a client to be asynchronously notified when these 18 changes occur. This document defines a mechanism for a client to be 19 notified of such changes to DNS records, called DNS Push 20 Notifications. 22 Status of This Memo 24 This Internet-Draft is submitted in full conformance with the 25 provisions of BCP 78 and BCP 79. 27 Internet-Drafts are working documents of the Internet Engineering 28 Task Force (IETF). Note that other groups may also distribute 29 working documents as Internet-Drafts. The list of current Internet- 30 Drafts is at http://datatracker.ietf.org/drafts/current/. 32 Internet-Drafts are draft documents valid for a maximum of six months 33 and may be updated, replaced, or obsoleted by other documents at any 34 time. It is inappropriate to use Internet-Drafts as reference 35 material or to cite them other than as "work in progress." 37 This Internet-Draft will expire on September 10, 2015. 39 Copyright Notice 41 Copyright (c) 2015 IETF Trust and the persons identified as the 42 document authors. All rights reserved. 44 This document is subject to BCP 78 and the IETF Trust's Legal 45 Provisions Relating to IETF Documents 46 (http://trustee.ietf.org/license-info) in effect on the date of 47 publication of this document. Please review these documents 48 carefully, as they describe your rights and restrictions with respect 49 to this document. Code Components extracted from this document must 50 include Simplified BSD License text as described in Section 4.e of 51 the Trust Legal Provisions and are provided without warranty as 52 described in the Simplified BSD License. 54 Table of Contents 56 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 57 1.1. Requirements Language . . . . . . . . . . . . . . . . . . 2 58 2. Motivation . . . . . . . . . . . . . . . . . . . . . . . . . 3 59 3. Overview . . . . . . . . . . . . . . . . . . . . . . . . . . 4 60 4. Transport . . . . . . . . . . . . . . . . . . . . . . . . . . 4 61 5. State Considerations . . . . . . . . . . . . . . . . . . . . 5 62 6. Protocol Operation . . . . . . . . . . . . . . . . . . . . . 6 63 6.1. Discovery . . . . . . . . . . . . . . . . . . . . . . . . 6 64 6.2. DNS Push Notification SUBSCRIBE . . . . . . . . . . . . . 8 65 6.3. DNS Push Notification UNSUBSCRIBE . . . . . . . . . . . . 10 66 6.4. DNS Push Notification Update Messages . . . . . . . . . . 11 67 7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 13 68 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 13 69 9. Security Considerations . . . . . . . . . . . . . . . . . . . 14 70 9.1. Security Services . . . . . . . . . . . . . . . . . . . . 14 71 9.2. TLS Name Authentication . . . . . . . . . . . . . . . . . 14 72 9.3. TLS Compression . . . . . . . . . . . . . . . . . . . . . 14 73 9.4. TLS Session Resumption . . . . . . . . . . . . . . . . . 15 74 10. References . . . . . . . . . . . . . . . . . . . . . . . . . 15 75 10.1. Normative References . . . . . . . . . . . . . . . . . . 15 76 10.2. Informative References . . . . . . . . . . . . . . . . . 16 77 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 17 79 1. Introduction 81 DNS records may be updated using DNS Update [RFC2136]. Other 82 mechanisms such as a Hybrid Proxy [I-D.ietf-dnssd-hybrid] can also 83 generate changes to a DNS zone. This document specifies a protocol 84 for Unicast DNS clients to subscribe to receive asynchronous 85 notifications of changes to RRSets of interest. It is immediately 86 relevant in the case of DNS Service Discovery [RFC6763] but is not 87 limited to that use case and provides a general DNS mechanism for DNS 88 record change notifications. Familiarity with the DNS protocol and 89 DNS packet formats is assumed [RFC1034] [RFC1035] [RFC6195]. 91 1.1. Requirements Language 93 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 94 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 95 document are to be interpreted as described in "Key words for use in 96 RFCs to Indicate Requirement Levels" [RFC2119]. 98 2. Motivation 100 As the domain name system continues to adapt to new uses and changes 101 in deployment, polling has the potential to burden DNS servers at 102 many levels throughout the network. Other network protocols have 103 successfully deployed a publish/subscribe model to state changes 104 following the Observer design pattern. XMPP Publish-Subscribe 105 [XEP-0060] and Atom [RFC4287] are examples. While DNS servers are 106 generally highly tuned and capable of a high rate of query/response 107 traffic, adding a publish/subscribe model for tracking changes to DNS 108 records can result in more timely notification of changes with 109 reduced CPU usage and lower network traffic. 111 Multicast DNS [RFC6762] implementations always listen on a well known 112 link-local IP multicast group, and new services and updates are sent 113 for all group members to receive. Therefore, Multicast DNS already 114 has asynchronous change notification capability. However, when DNS 115 Service Discovery [RFC6763] is used across a wide area network using 116 Unicast DNS (possibly facilitated via a Hybrid Proxy 117 [I-D.ietf-dnssd-hybrid]) it would be beneficial to have an equivalent 118 capability for Unicast DNS, to allow clients to learn about DNS 119 record changes in a timely manner without polling. 121 DNS Long-Lived Queries (LLQ) [I-D.sekar-dns-llq] is an existing 122 deployed solution to provide asynchronous change notifications. Even 123 though it can be used over TCP, LLQ is defined primarily as a UDP- 124 based protocol, and as such it defines its own equivalents of 125 existing TCP features like the three-way handshake. This document 126 builds on experience gained with the LLQ protocol, with an improved 127 design that uses long-lived TCP connections instead of UDP (and 128 therefore doesn't need to duplicate existing TCP functionality), and 129 adopts the syntax and semantics of DNS Update messages [RFC2136] 130 instead of inventing a new vocabulary of messages to communicate DNS 131 zone changes. 133 3. Overview 135 The existing DNS Update protocol [RFC2136] provides a mechanism for 136 clients to add or delete individual resource records (RRs) or entire 137 resource record sets (RRSets) on the zone's server. Adopting this 138 existing syntax and semantics for DNS Push Notifications allows for 139 messages going in the other direction, from server to client, to 140 communicate changes to a zone. The client first must subscribe for 141 Push Notifications by connecting to the server and sending DNS 142 message(s) indicating the RRSet(s) of interest. When the client 143 loses interest in updates to these records, it unsubscribes. The DNS 144 Push Notification server for a zone is any server capable of 145 generating the correct change notifications for a name. It may be a 146 master, slave, or stealth name server [RFC1996]. 148 DNS Push Notification clients are NOT required to implement DNS 149 Update Prerequisite processing. Prerequisites are used to perform 150 tentative atomic test-and-set type operations on the server, and that 151 concept has no application when it comes to an authoritative server 152 telling a client of changes to DNS records. 154 4. Transport 156 Implementations of DNS Update [RFC2136] MAY use either User Datagram 157 Protocol (UDP) [RFC0768] or Transmission Control Protocol (TCP) 158 [RFC0793] as the transport protocol, in keeping with the historical 159 precedent that DNS queries must first be sent over UDP [RFC1123]. 160 This requirement to use UDP has subsequently been relaxed [RFC5966]. 161 DNS Push Notification is defined only for TCP. DNS Push Notification 162 clients MUST use TCP. 164 Either end of the TCP connection can terminate all of the 165 subscriptions on that connection by simply closing the connection 166 abruptly with a TCP RST. (An individual subscription is terminated 167 by sending an UNSUBSCRIBE message for that specific subscription.) 169 If a client closes the connection, it is signaling that it is no 170 longer interested in receiving updates to any of the records it has 171 subscribed. It is informing the server that the server may release 172 all state information it has been keeping with regards to this 173 client. This may occur because the client computer has been 174 disconnected from the network, has gone to sleep, or the application 175 requiring the records has terminated. 177 If a server closes the connection, it is informing the client that it 178 can no longer provide updates for the subscribed records. This may 179 occur because the server application software or operating system is 180 restarting, the application terminated unexpectedly, the server is 181 undergoing maintenance procedures, or the server is overloaded and 182 can no longer provide the information to all the clients that wish to 183 receive it. The client can try to re-subscribe at a later time or 184 connect to another server supporting DNS Push Notifications for the 185 zone. 187 Transport Layer Security (TLS) [RFC5246] is well understood and 188 deployed across many protocols running over TCP. It is designed to 189 prevent eavesdropping, tampering, or message forgery. TLS is 190 REQUIRED for every connection between a client subscriber and server 191 in this protocol specification. 193 Connection setup over TCP ensures return reachability and alleviates 194 concerns of state overload at the server through anonymous 195 subscriptions. All subscribers are guaranteed to be reachable by the 196 server by virtue of the TCP three-way handshake. Additional security 197 measures such as authentication during TLS negotiation MAY also be 198 employed to increase the trust relationship between client and 199 server. Because TCP SYN flooding attacks are possible with any 200 protocol over TCP, implementers are encouraged to use industry best 201 practices to guard against such attacks [IPJ.9-4-TCPSYN]. 203 5. State Considerations 205 Each DNS Push Notification server is capable and handling some finite 206 number of Push Notification subscriptions. This number will vary 207 from server to server and is based on physical machine 208 characteristics, network bandwidth, and operating system resource 209 allocation. After a client establishes a connection to a DNS server, 210 each record subscription is individually accepted or rejected. 211 Servers may employ various techniques to limit subscriptions to a 212 manageable level. Correspondingly, the client is free to establish 213 simultaneous connections to alternate DNS servers that support DNS 214 Push Notifications for the zone and distribute record subscriptions 215 at its discretion. In this way, both clients and servers can react 216 to resource constraints. Token bucket rate limiting schemes are also 217 effective in providing fairness by a server across numerous client 218 requests. 220 6. Protocol Operation 222 A DNS Push Notification exchange begins with the client discovering 223 the appropriate server, and connecting to it. The client may then 224 add and remove Push Notification subscriptions over this connection. 225 In accordance with the current set of active subscriptions the server 226 sends relevant asynchronous Push Notifications to the client. The 227 exchange terminates when either end closes the TCP connection with a 228 TCP RST. 230 6.1. Discovery 232 The first step in DNS Push Notification subscription is to discover 233 an appropriate DNS server that supports DNS Push Notifications for 234 the desired zone. The client MUST also determine which TCP port on 235 the server is listening for connections, which need not be (and often 236 is not) the typical TCP port 53 used for conventional DNS. 238 1. The client begins the discovery by sending a DNS query to the 239 local resolver with record type SOA [RFC1035] for the name of the 240 record it wishes to subscribe. 242 2. If the SOA record exists, it MUST be returned in the Answer 243 Section of the reply. If not, the server SHOULD include the SOA 244 record for the zone of the requested name in the Authority 245 Section. 247 3. If no SOA record is returned, the client then strips off the 248 leading label from the requested name. If the resulting name has 249 at least one label in it, the client sends a new SOA query and 250 processing continues at step 2 above. If the resulting name is 251 empty (the root label) then this is a network configuration error 252 and the client gives up. The client MAY retry the operation at a 253 later time. 255 4. Once the SOA is known, the client sends a DNS query with type SRV 256 [RFC2782] for the record name "_dns-push._tcp.", where 257 is the owner name of the discovered SOA record. 259 5. If the zone in question does not offer DNS Push Notifications 260 then SRV record MUST NOT exist and the SRV query will return a 261 negative answer. 263 6. If the zone in question is set up to offer DNS Push Notifications 264 then this SRV record MUST exist. The SRV "target" contains the 265 name of the server providing DNS Push Notifications for the zone. 266 The port number on which to contact the server is in the SRV 267 record "port" field. The address(es) of the target host MAY be 268 included in the Additional Section, however, the address records 269 SHOULD be authenticated before use as described below in 270 Section 9.2 [I-D.ietf-dane-srv]. 272 7. More than one SRV record may be returned. In this case, the 273 "priority" and "weight" values in the returned SRV records are 274 used to determine the order in which to contact the servers for 275 subscription requests. As described in the SRV specification 276 [RFC2782], the server with the lowest "priority" is first 277 contacted. If more than one server has the same "priority", the 278 "weight" is indicates the weighted probability that the client 279 should contact that server. Higher weights have higher 280 probabilities of being selected. If a server is not reachable or 281 is not willing to accept a subscription request, then a 282 subsequent server is to be contacted. 284 If a server closes a DNS Push Notification subscription connection, 285 the client SHOULD repeat the discovery process in order to determine 286 the preferred DNS server for subscriptions at that time. 288 6.2. DNS Push Notification SUBSCRIBE 290 A DNS Push Notification client indicates its desire to receive DNS 291 Push Notifications for a given domain name by sending a SUBSCRIBE 292 request over the established TCP connection to the server. A 293 SUBSCRIBE request is formatted identically to a conventional DNS 294 QUERY request [RFC1035], except that the opcode is SUBSCRIBE (6) 295 instead of QUERY (0). If neither QTYPE nor QCLASS are ANY (255) then 296 this is a specific subscription to changes for the given name, type 297 and class. If one or both of QTYPE or QCLASS are ANY (255) then this 298 is a wildcard subscription to changes for the given name for any type 299 and/or class, as appropriate. 301 In a SUBSCRIBE request the DNS Header QR bit MUST be zero. 302 If the QR bit is not zero the message is not a SUBSCRIBE request. 304 The AA, TC, RD, RA, Z, AD, and CD bits, the ID field, and the RCODE 305 field, MUST be zero on transmission, and MUST be silently ignored on 306 reception. 308 Like a DNS QUERY request, a SUBSCRIBE request MUST contain exactly 309 one question. Since SUBSCRIBE requests are sent over TCP, multiple 310 SUBSCRIBE requests can be concatenated in a single TCP stream and 311 packed efficiently into TCP segments, so the ability to pack multiple 312 SUBSCRIBE operations into a single DNS message within that TCP stream 313 would add extra complexity for little benefit. 315 ANCOUNT MUST be zero, and the Answer Section MUST be empty. 316 Any records in the Answer Section MUST be silently ignored. 318 NSCOUNT MUST be zero, and the Authority Section MUST be empty. 319 Any records in the Authority Section MUST be silently ignored. 321 ARCOUNT MUST be zero, and the Additional Section MUST be empty. 322 Any records in the Additional Section MUST be silently ignored. 324 Each SUBSCRIBE request generates exactly one SUBSCRIBE response from 325 the server. 327 In the SUBSCRIBE response the RCODE indicates whether or not the 328 subscription was accepted. Supported RCODEs are as follows: 330 +----------+-------+------------------------------------------------+ 331 | Mnemonic | Value | Description | 332 +----------+-------+------------------------------------------------+ 333 | NOERROR | 0 | SUBSCRIBE successful | 334 | FORMERR | 1 | Server failed to process request due to a | 335 | | | malformed request | 336 | SERVFAIL | 2 | Server failed to process request due to | 337 | | | resource exhaustion | 338 | NOTIMP | 4 | Server does not implement DNS Push | 339 | | | Notifications | 340 | REFUSED | 5 | Server refuses to process request for policy | 341 | | | or security reasons | 342 +----------+-------+------------------------------------------------+ 344 Table 1: Response codes 346 In a SUBSCRIBE response the DNS Header QR bit MUST be one. 347 If the QR bit is not one the message is not a SUBSCRIBE response. 349 The AA, TC, RD, RA, Z, AD, and CD bits, and the ID field, MUST be 350 zero on transmission, and MUST be silently ignored on reception. 352 The Question Section MUST echo back the values provided by the client 353 in the SUBSCRIBE request that generated this SUBSCRIBE response. 355 ANCOUNT MUST be zero, and the Answer Section MUST be empty. 356 Any records in the Answer Section MUST be silently ignored. 357 If the subscription was accepted and there are positive answers for 358 the requested name, type and class, then these positive answers MUST 359 be communicated to the client in an immediately following Push 360 Notification Update, not in the Answer Section of the SUBSCRIBE 361 response. This simplifying requirement is made so that there is only 362 a single way that information is communicated to a DNS Push 363 Notification client. Since a DNS Push Notification client has to 364 parse information received via Push Notification Updates anyway, it 365 is simpler if it does not also have to parse information received via 366 the Answer Section of a SUBSCRIBE response. 368 NSCOUNT MUST be zero, and the Authority Section MUST be empty. 369 Any records in the Authority Section MUST be silently ignored. 371 ARCOUNT MUST be zero, and the Additional Section MUST be empty. 373 Any records in the Additional Section MUST be silently ignored. 375 If accepted, the subscription will stay in effect until the client 376 revokes the subscription or until the connection between the client 377 and the server is closed. 379 A client MUST not send a SUBSCRIBE message that duplicates the name, 380 type and class of an existing active subscription. For the purpose 381 of this matching, the established DNS case-insensitivity for US-ASCII 382 letters applies (e.g., "foo.com" and "Foo.com" are the same). If a 383 server receives such a duplicate SUBSCRIBE message this is an error 384 and the server MUST immediately close the TCP connection. 386 Wildcarding is not supported. That is, a wildcard ("*") in a 387 SUBSCRIBE message matches only a wildcard ("*") in the zone, and 388 nothing else. 390 Aliasing is not supported. That is, a CNAME in a SUBSCRIBE message 391 matches only a CNAME in the zone, and nothing else. 393 A client may SUBSCRIBE to records that are unknown to the server at 394 the time of the request and this is not an error. The server MUST 395 accept these requests and send Push Notifications if and when matches 396 are found in the future. 398 6.3. DNS Push Notification UNSUBSCRIBE 400 To cancel an individual subscription without closing the entire 401 connection, the client sends an UNSUBSCRIBE message over the 402 established TCP connection to the server. The UNSUBSCRIBE message is 403 formatted identically to the SUBSCRIBE message which created the 404 subscription, with the exact same name, type and class, except that 405 the opcode is UNSUBSCRIBE (7) instead of SUBSCRIBE (6). 407 A client MUST not send an UNSUBSCRIBE message that does not exactly 408 match the name, type and class of an existing active subscription. 409 If a server receives such an UNSUBSCRIBE message this is an error and 410 the server MUST immediately close the TCP connection. 412 No response message is generated as a result of processing an 413 UNSUBSCRIBE message. 415 Having being successfully revoked with a correctly-formatted 416 UNSUBSCRIBE message, the previously referenced subscription is no 417 longer active and the server MAY discard the state associated with it 418 immediately, or later, at the server's discretion. 420 6.4. DNS Push Notification Update Messages 422 Once a subscription has been successfully established, the server 423 generates Push Notification Updates to send to the client as 424 appropriate. An initial Push Notification Update will be sent 425 immediately in the case that the answer set was non-empty at the 426 moment the subscription was established. Subsequent changes to the 427 answer set are then communicated to the client in subsequent Push 428 Notification Updates. 430 The format of Push Notification Updates borrows from the existing DNS 431 Update [RFC2136] protocol, with some simplifications. 433 The following figure shows the existing DNS Update header format: 435 1 1 1 1 1 1 436 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 437 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 438 | ID | 439 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 440 |QR| Opcode | Z | RCODE | 441 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 442 | ZOCOUNT | 443 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 444 | PRCOUNT | 445 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 446 | UPCOUNT | 447 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 448 | ADCOUNT | 449 +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+ 451 Figure 1 453 For DNS Push Notifications the following rules apply: 455 The QR bit MUST be zero, and the Opcode MUST be UPDATE (5). 456 Messages received where this is not true are not Push Notification 457 Update Messages and should be silently ignored for the purposes of 458 Push Notification Update Message handling. 460 ID, the Z bits, and RCODE MUST be zero on transmission, 461 and MUST be silently ignored on reception. 463 ZOCOUNT MUST be zero, and the Zone Section MUST be empty. 464 Any records in the Zone Section MUST be silently ignored. 466 PRCOUNT MUST be zero, and the Prerequisite Section MUST be empty. 467 Any records in the Prerequisite Section MUST be silently ignored. 469 ADCOUNT MUST be zero, and the Additional Data Section MUST be empty. 470 Any records in the Additional Data Section MUST be silently ignored. 472 The Update Section contains the relevant change information for the 473 client, formatted identically to a DNS Update [RFC2136]. To recap: 475 Delete all RRsets from a name: 476 TTL=0, CLASS=ANY, RDLENGTH=0, TYPE=ANY. 478 Delete an RRset from a name: 479 TTL=0, CLASS=ANY, RDLENGTH=0; 480 TYPE specifies the RRset being deleted. 482 Delete an individual RR from a name: 483 TTL=0, CLASS=NONE; 484 TYPE, RDLENGTH and RDATA specifies the RR being deleted. 486 Add an individual RR to a name: 487 TTL, CLASS, TYPE, RDLENGTH and RDATA specifies the RR being added. 489 Upon reception of a Push Notification Update Message, the client 490 receiving the message MUST validate that the records being added or 491 deleted correspond with at least one currently active subscription on 492 that connection. Specifically, the record name MUST match the name 493 given in the SUBSCRIBE request, subject to the usual established DNS 494 case-insensitivity for US-ASCII letters. If the QTYPE was not ANY 495 (255) then the TYPE of the record must match the QTYPE given in the 496 SUBSCRIBE request. If the QCLASS was not ANY (255) then the CLASS of 497 the record must match the QCLASS given in the SUBSCRIBE request. If 498 a matching active subscription on that connection is not found, then 499 that individual record addition/deletion is silently ignored. 500 Processing of other additions and deletions in this message is not 501 affected. The TCP connection is not closed. This is to allow for 502 the race condition where a client sends an outbound UNSUBSCRIBE while 503 inbound Push Notification Updates for that subscription from the 504 server are still in flight. 506 In the case where a single change affects more than one active 507 subscription, only one update is sent. For example, an update adding 508 a given record may match both a SUBSCRIBE request with the same QTYPE 509 and a different SUBSCRIBE request with QTYPE=ANY. It is not the case 510 that two updates are sent because the new record matches two active 511 subscriptions. 513 The server SHOULD encode change notifications in the most efficient 514 manner possible. For example, when three AAAA records are deleted 515 from a given name, and no other AAAA records exist for that name, the 516 server SHOULD send a "delete an RRset from a name" update, not three 517 separate "delete an individual RR from a name" updates. Similarly, 518 when both an SRV and a TXT record are deleted from a given name, and 519 no other records of any kind exist for that name, the server SHOULD 520 send a "delete all RRsets from a name" update, not two separate 521 "delete an RRset from a name" updates. 523 Reception of a Push Notification Update Message results in no 524 response back to the server. 526 The TTL of an added record is stored by the client and decremented as 527 time passes, with the caveat that for as long as a relevant 528 subscription is active, the TTL does not decrement below 1 second. 529 For as long as a relevant subscription remains active, the client 530 SHOULD assume that when a record goes away the server will notify it 531 of that fact. Consequently, a client does not have to poll to verify 532 that the record is still there. Once a subscription is cancelled 533 (individually, or as a result of the TCP connection being closed) 534 record aging resumes and records are removed from the local cache 535 when their TTL reaches zero. 537 7. Acknowledgements 539 The authors would like to thank Kiren Sekar and Marc Krochmal for 540 previous work completed in this field. This draft has been improved 541 due to comments from Ran Atkinson. 543 8. IANA Considerations 545 This document defines the service name: "_dns-push._tcp". 546 It is only applicable for the TCP protocol. 547 This name is to be published in the IANA Service Name Registry. 549 This document defines two DNS OpCodes: SUBSCRIBE with (tentative) 550 value 6 and UNSUBSCRIBE with (tentative) value 7. 552 9. Security Considerations 554 Strict TLS support is mandatory in DNS Push Notifications. There is 555 no provision for opportunistic encryption using a mechanism like 556 "STARTTLS". 558 9.1. Security Services 560 It is the goal of using TLS to provide the following security 561 services: 563 Confidentiality All application-layer communication is encrypted 564 with the goal that no party should be able to decrypt it except 565 the intended receiver. 567 Data integrity protection Any changes made to the communication in 568 transit are detectable by the receiver. 570 Authentication An end-point of the TLS communication is 571 authenticated as the intended entity to communicate with. 573 Deployment recommendations on the appropriate key lengths and cypher 574 suites are beyond the scope of this document. Please refer to TLS 575 Recommendations [I-D.ietf-uta-tls-bcp] for the best current 576 practices. Keep in mind that best practices only exist for a 577 snapshot in time and recommendations will continue to change. 578 Updated versions or errata may exist for these recommendations. 580 9.2. TLS Name Authentication 582 As described in Section 6.1, the client discovers the DNS Push 583 Notification server using an SRV lookup for the record name "_dns- 584 push._tcp.". The server connection endpoint SHOULD then be 585 authenticated using DANE TLSA records for the associated SRV record. 586 This associates the target's name and port number with a trusted TLS 587 certificate [I-D.ietf-dane-srv]. This procedure uses the TLS Sever 588 Name Indication (SNI) extension [RFC6066] to inform the server of the 589 name the client has authenticated through the use of TLSA records. 591 9.3. TLS Compression 593 In order to reduce the chances of compression related attacks, TLS- 594 level compression SHOULD be disabled when using TLS versions 1.2 and 595 earlier. In the draft version of TLS 1.3 [I-D.ietf-tls-tls13], TLS- 596 level compression has been removed completely. 598 9.4. TLS Session Resumption 600 TLS Session Resumption MUST be disabled on DNS Push Notification 601 servers. It is not useful to have subscription state cached for long 602 periods of time. It is also not desirable for subscription state to 603 be maintained while the client is not connected. 605 10. References 607 10.1. Normative References 609 [I-D.ietf-dane-srv] 610 Finch, T., Miller, M., and P. Saint-Andre, "Using DNS- 611 Based Authentication of Named Entities (DANE) TLSA Records 612 with SRV Records", draft-ietf-dane-srv-11 (work in 613 progress), February 2015. 615 [I-D.ietf-tls-tls13] 616 Dierks, T. and E. Rescorla, "The Transport Layer Security 617 (TLS) Protocol Version 1.3", draft-ietf-tls-tls13-04 (work 618 in progress), January 2015. 620 [I-D.ietf-uta-tls-bcp] 621 Sheffer, Y., Holz, R., and P. Saint-Andre, 622 "Recommendations for Secure Use of TLS and DTLS", draft- 623 ietf-uta-tls-bcp-11 (work in progress), February 2015. 625 [RFC0768] Postel, J., "User Datagram Protocol", STD 6, RFC 768, 626 August 1980. 628 [RFC0793] Postel, J., "Transmission Control Protocol", STD 7, RFC 629 793, September 1981. 631 [RFC1034] Mockapetris, P., "Domain names - concepts and facilities", 632 STD 13, RFC 1034, November 1987. 634 [RFC1035] Mockapetris, P., "Domain names - implementation and 635 specification", STD 13, RFC 1035, November 1987. 637 [RFC1123] Braden, R., "Requirements for Internet Hosts - Application 638 and Support", STD 3, RFC 1123, October 1989. 640 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 641 Requirement Levels", BCP 14, RFC 2119, March 1997. 643 [RFC2136] Vixie, P., Thomson, S., Rekhter, Y., and J. Bound, 644 "Dynamic Updates in the Domain Name System (DNS UPDATE)", 645 RFC 2136, April 1997. 647 [RFC2782] Gulbrandsen, A., Vixie, P., and L. Esibov, "A DNS RR for 648 specifying the location of services (DNS SRV)", RFC 2782, 649 February 2000. 651 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 652 (TLS) Protocol Version 1.2", RFC 5246, August 2008. 654 [RFC5966] Bellis, R., "DNS Transport over TCP - Implementation 655 Requirements", RFC 5966, August 2010. 657 [RFC6066] Eastlake, D., "Transport Layer Security (TLS) Extensions: 658 Extension Definitions", RFC 6066, January 2011. 660 [RFC6195] Eastlake, D., "Domain Name System (DNS) IANA 661 Considerations", RFC 6195, March 2011. 663 10.2. Informative References 665 [I-D.ietf-dnssd-hybrid] 666 Cheshire, S., "Hybrid Unicast/Multicast DNS-Based Service 667 Discovery", draft-ietf-dnssd-hybrid-00 (work in progress), 668 November 2014. 670 [I-D.sekar-dns-llq] 671 Sekar, K., "DNS Long-Lived Queries", draft-sekar-dns- 672 llq-01 (work in progress), August 2006. 674 [IPJ.9-4-TCPSYN] 675 Eddy, W., "Defenses Against TCP SYN Flooding Attacks", The 676 Internet Protocol Journal, Cisco Systems, Volume 9, Number 677 4, December 2006. 679 [RFC1996] Vixie, P., "A Mechanism for Prompt Notification of Zone 680 Changes (DNS NOTIFY)", RFC 1996, August 1996. 682 [RFC4287] Nottingham, M., Ed. and R. Sayre, Ed., "The Atom 683 Syndication Format", RFC 4287, December 2005. 685 [RFC6762] Cheshire, S. and M. Krochmal, "Multicast DNS", RFC 6762, 686 February 2013. 688 [RFC6763] Cheshire, S. and M. Krochmal, "DNS-Based Service 689 Discovery", RFC 6763, February 2013. 691 [XEP-0060] 692 Millard, P., Saint-Andre, P., and R. Meijer, "Publish- 693 Subscribe", XSF XEP 0060, July 2010. 695 Authors' Addresses 697 Tom Pusateri 698 Seeking affiliation 699 Hilton Head Island, SC 700 USA 702 Phone: +1 843 473 7394 703 Email: pusateri@bangj.com 705 Stuart Cheshire 706 Apple Inc. 707 1 Infinite Loop 708 Cupertino, CA 95014 709 USA 711 Phone: +1 408 974 3207 712 Email: cheshire@apple.com