Internet Engineering Task Force S. Cheshire Internet-Draft Apple Inc. Intended status: Informational T. Lemon Expires: January3,15, 2019 Nibbhaya Consulting July2,14, 2018 Service Registration Protocol for DNS-Based Service Discoverydraft-sctl-service-registration-01draft-sctl-service-registration-02 Abstract The DNS-SD Service Registration Protocol uses the standard DNS Update mechanism to enable DNS-Based Service Discovery using only unicast packets. This eliminates the dependency on Multicast DNS as the foundation layer, which greatly improves scalability and improves performance on networks where multicast service is not an optimal choice, particularly 802.11(WiFi)(Wi-Fi) and802.15802.15.4 (IoT) networks. DNS-SD Service registration uses public keys and SIG(0) to allow services to defend their registrations against attack. Status of This Memo This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet- Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." This Internet-Draft will expire on January3,15, 2019. Copyright Notice Copyright (c) 2018 IETF Trust and the persons identified as the document authors. All rights reserved. This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. 1. Introduction DNS-Based Service Discovery [RFC6763] is a component of Zero Configuration Networking [RFC6760] [ZC] [I-D.cheshire-dnssd-roadmap]. This document describes an enhancement to DNS-Based Service Discovery [RFC6763] that allows services to automatically register their services using the DNS protocol rather than using mDNS. There is already a large installed base of DNS-SD clients that can do service discovery using the DNS protocol. This extension makes it much easier to take advantage of this existing functionality. This document is intended for three audiences: implementors of software that provides services that should be advertised using DNS- SD, implementors of DNS servers that will be used in contexts where DNS-SD registration is needed, and administrators of networks where DNS-SD service is required. The document is intended to provide sufficient information to allow interoperable implementation of the registration protocol. DNS-Based Service Discovery (DNS-SD) allows services to advertise the fact that they provide service, and to provide the information required to access that service. Clients can then discover the set of services of a particular type that are available. They can then select a service from among those that are available and obtain the information required to use it. The DNS-SD Service Registration protocol, described in this document, provides a reasonably secure mechanism for publishing thisinformation: what services are offered, and how to use them.information. Once published, these services can be readily discovered by clients using standard DNS lookups. In the DNS-Based Service Discovery specification [RFC6763] Section 10 "Populating the DNS with Information" briefly discusses ways that services can publish their information in the DNS namespace. In the case of Multicast DNS [RFC6762], it allowsclients to directly queryservices to publish their information on the locallink forlink, using names in the ".local"namespace.namespace, which makes their services directly discoverable by peers attached to that same local link. RFC6763 also allows clients to discover services using the DNS protocol[RFC1035]; this is[RFC1035]. This can be doneeitherby having a system administrator manually configure service information in the DNS,or by using a Discovery Proxy [I-D.ietf-dnssd-hybrid], which performs mDNS queries on behalf clients issuing queries using DNS. This eliminats the "link local" limitation of mDNS,butprovides no additional security, and still relies on multicast. Manual configuration ofmanually populating DNSserversauthoritative server databases is costly andfailure-prone,potentially error-prone, and requires a knowledgable network administrator. Consequently, although all DNS-SD client implementations of which we are aware supportit,DNS-SD using DNS queries, in practice it is used much less frequentlyusedthan mDNS. The Discovery Proxy [I-D.ietf-dnssd-hybrid] provides one way to automatically populate the DNS namespace, but is only appropriate on networks where services are already advertised using mDNS. This document describes asolution: a way to provide DNS-SD using DNS that can be as automatic assolution more suitable for networks where multicastDNS, but with better performance, scalabilityis inefficient, or undesirable for other reasons, by supporting both offering of services, andsecurity.discovery of services, using unicast. 2. Service Registration Protocol Servicesusingthat implement the DNS-SD Service Registration Protocol use DNS Update [RFC2136] [RFC3007] to publish service information in the DNS.We will discuss several parts to this process: how to know what to publish, how to know where to publish it (under what name), how to publish it, how to secure its publication,Two variants exist, one for full-featured devices, andhow to maintainone for devices designed for "Constrained-Node Networks" [RFC7228]. Full-featured devices are either configured manually, or use theinformation once published. 2.1. What"dr._dns-sd._udp" query [RFC6763] topublish RFC 6763 describeslearn thedetails of what is to be published. In general terms, a service will have a name under which it offers services ([RFC6763] section 4.1.1) and one or moredefault registration domain from the network. Using the chosen service registration domain, full-featured devices construct the namesunder which that instance name appears ([RFC6763] section 4.1.2). The full details of how this works are described in section 4ofthat document in its entirety. A service publishes its contact information using an SRV record ontheService Instance Name. It can also publish TXTSRV, TXT, and PTR recordswith additional information aboutdescribing their service(s). For these names they then discover theservice; this is discussed in section 6zone apex ofRFC 6763. RFC 6763 isthedefinitive source for information about what to publish;closest enclosing DNS zone using SOA queries [I-D.ietf-dnssd-push]. Having discovered thereasonenclosing DNS zone, they query formentioning it here is thatthereader may prefer"_dns-update._udp<zone>" SRV record tohave an overviewdiscover the server to which they should send DNS updates. For devices designed for "Constrained-Node Networks" [RFC7228] some simplifications are used. Instead of being configured with (or discovering) thewholeservice registrationprocess before digging into the details. Also,domain, the"Service Instance Name"(proposed) special use domain name [RFC6761] "services.arpa" isan important aspectused. Instead offirst-come, first-serve naming, which we describe later on in this document. 2.2. Wherelearning the server topublish it Multicastwhich they should send DNSusesupdates, asingle namespace, ".local", whichfixed IPv6 anycast address isvalid on the local link. This convenienceused (value TBD). It isnot available forthe responsibility of a "Constrained-Node Network" supporting DNS-SDusingService Registration Protocol to provide appropriate anycast routing to deliver the DNSprotocol:updates to theportionappropriate server. It is the responsibility of theDNS namespace in which servicesDNS-SD Service Registration server on a "Constrained-Node Network" to handle thelocalupdates appropriately. In some networkare to be published mustenvironments, updates may bediscovered byaccepted directly into a local "services.arpa" zone, which has only local visibility. In other network environments, updates for names ending in "services.arpa" may be rewritten internally to names with broader visibility. The reason for these different assumptions is that "Constrained-Node Networks" generally require special egress support, and Anycast packets captured at theservice before it"Constrained-Node Network" egress canregister itself. Names published using DNS-SD servicebe assumed to have originated locally. Low-power devices that typically use "Constrained-Node Networks" may have very limited battery power. The additional DNS lookups required to discover a registration server and then communicate with it will increase the power required to advertise a service; for low-power devices, the additional flexibility this provides does not justify the additional use of power. General networks have the potential to have more complicated topologies at the Internet layer, which makes anycast routing more difficult. Such networks may or may not have the infrastructure required to route anycast to a server that can process it. However, they can bepublished underassumed to be able to provide registration domain discovery and routing. By requiring the use of TCP, the possibility of off-network spoofing is eliminated. We will discuss several parts to this process: how to know what to publish, how to know where to publish it (under what name), how to publish it, how to secure its publication, and how to maintain the information once published. 2.1. What to publish We refer to the message that services using the DNSSD Registration Protocol send as a Registration. Three types of updates appear in a Registration: Service Discovery records, Service Description records, and Host Description records. o Service Discovery records are one or more PTR RRs, mapping from the generic service type (or subtype) to the specific Service Instance Name. o Service Description records are exactly one SRV RR, and one or more TXT RRs, both with the same name, the Service Instance Name ([RFC6763] section 4.1). In principle Service Description records can include other record types, with the same Service Instance Name, though in practice they rarely do. The Service Instance Name MUST be referenced by one or more Service Discovery PTR records, unless it is a placeholder service registration for an intentionally non-discoverable service name. o The Host Description records for a service are a KEY RR, used to claim exclusive ownership of the service registration, and one or more RRs of type A or AAAA, giving the IPv4 or IPv6 address(es) of the host where the service resides. RFC 6763 describes the details of what each of these types of updates contains and is the definitive source for information about what to publish; the reason for mentioning it here is to provide the reader with enough information about what will be published that the service registration process can be understood at a high level without first learning the full details of DNS-SD. Also, the "Service Instance Name" is an important aspect of first-come, first-serve naming, which we describe later on in this document. 2.2. Where to publish it Multicast DNS uses a single namespace, ".local", which is valid on the local link. This convenience is not available for DNS-SD using the DNS protocol: services must exist in some specific unicast namespace. As described above, full-featured devices are responsible for knowing in what domain they should register their services. Devices made for "Constrained-Node Networks" register in the (proposed) special use domain name [RFC6761] "services.arpa", and let the DNS-SD Service Registration server handle rewriting that to a different domain if necessary. 2.3. How to publish it It is possible to issue a DNS Update that does several things at once; this means that it's possible to do all the work of adding a PTR resource record to the PTR RRset on the Service Name if it already exists, or creating one if it doesn't, and creating or updating the Service Instance Name and Host Description in a single transaction. A Registration is therefore implemented as a single DNS Update message that contains a service's Service Discovery records, Service Description records, and Host Description records. Updates done according to this specification are somewhat different than regular DNS Updates as defined in RFC2136. RFC2136 assumes that updating is a fairly heavyweight process, so you might first attempt to add a name if it doesn't exist, and then in a second message update the name if it does exist but matches certain preconditions. Because the registration protocol uses a single transaction, some of this adaptability is lost. In order to allow updates to happen in a single transaction, Registrations do not include update constraints. The constraints specified in Section 2.4.2 are implicit in the processing of Registrations, and so there is no need for the service sending the Registration to put in any explicit constraints. 2.3.1. How DNS-SD Service Registration differs from standard RFC2136 DNS Update DNS-SD Service Registration is based on standard RFC2136 DNS Update, with some differences: o It implements first-come first-served name allocation, protected using SIG(0). o It enforces policy about what updates are allowed. o It optionally performs rewriting of "services.arpa" to some otherthan .local. However, the processdomain. o It optionally performs automatic population ofdiscovering what that name isthe address-to-name reverse mapping domains. o A DNS-SD Service Registration server iscomplicated, andnot required to implement general DNS Update prerequsite processing. o Simplified clients are allowed to send updates to an anycast address, forany given network it should alwaysnames ending in "services.arpa" 2.3.2. Testing using standard RFC2136-compliant servers It may bethe caseuseful to set up a DNS server for testing thatthere willdoes not implement the Registration protocol. This can bejust one namespacedone by configuring the server to listen on the anycast address, or advertising it inwhich registeredthe _dns-update._udp SRV record. It must be configured to be authoritative for "services.arpa", and to accept updates from hosts on local networks for names under "services.arpa" without authentication. A server configured in this way will bepublished. Rather than requiring the serviceable todiscoversuccessfully accept and process Registrations from services that send Registrations. However, no constraints will be applied, and thisname before issuing a registration, the service SHOULD simply use the name ".local." The DNS servermeans thatreceivestheregistration requesttest server willrewrite all instances ofaccept internally inconsistent Registrations, and will not stop two Registrations, sent by different services, that claim theterminal label ".local"same name(s), from overwriting each other. 2.3.3. How touse the local registration domain name. The responseallow services to update standard RFC2136-compliant servers Ordinarily Registrations will fail when sent to any non-Registration Protocol server because theDNS Updatezone beingusedupdated is "services.arpa", and no DNS server that is not a Registration Protocol server should normally be configured toregister thebe authoritative for "services.arpa". Therefore, a servicewill contain the rewritten names, instead of ".local". Subsequent updates should still usethat sends a Registration can tell that the".local" domain andreceiving server does not support theregistration domain, sinceRegistration Protocol, but does support RFC2136, because theregistration domain may change over timeRCODE will either be NOTZONE, NOTAUTH orwhen the serviceREFUSED, or because there isphysically movedno response to the update request (when using the anycast address) In this case anew network. 2.3. Howservice MAY attempt topublish itregister itself using regular RFC2136 DNSUpdates are very flexible. As a consequence, it is possible toupdates. To dothe entireso, it must discover default registrationin a single DNS message. The update consists of two elements. The first updateszone and theService Name by adding a PTR record pointingDNS server designated tothe Service Instance Name. The second updates the Service Instance Name. The second creates orreceive updates for that zone, as described earlier using theService Instance Name update adds an_dns-update._udp SRVrecord and a KEY record, and optionally adds a TXT record with extra information about the service. The contents of the KEY record are described inrecord. It can then make thesection on First-Come First-Served Naming (Section 2.4.1). Theupdateis signedusing theprivate key that correspondsport and host pointed to by thepublic key in the KEYSRV record,using the SIG(0) protocol [RFC2931]. The update may be rejected. Ifand should use appropriate constraints to avoid overwriting competing records. Such updates are out of scope for thechosenDNSSD Registration Protocol, and a serviceinstance name is not permitted, or is already taken, the update will be returned withthat implements theerror code YXDOMAIN. In this case,DNSSD Registration Protocol MUST first attempt to use theservice will needRegistration Protocol tochoose a new instance nameregister itself, andtry again.should only attempt to use RFC2136 backwards compatibility if that fails. 2.4. How to secure it Traditional DNS update is secured using the TSIG protocol, which uses a secret key shared between the client (which issues the update) and the server (which authenticates it). This model does not work for automatic service registration. The goal of securing the DNS-SD Registration Protocol is to provide the best possible security given the constraint that service registration has to be automatic. It is possible to layer more operational security on top of what we describe here, but what we describe here improves upon the security of mDNS. The goal is not to provide the level of security of a network managed by a skilled operator. 2.4.1. First-Come First-Served Naming First-Come First-Serve naming provides a limited degree of security: a service that registers its service using DNS-SD Registration protocol is given ownership of a name for an extended period of time based on the key used to authenticate the DNS Update. As long as the registration service remembers the Service Instance Name and the key used to register that Service Instance Name, no other service can add or update the information associated with that Service Instance Name. 2.4.1.1. Service Behavior The service generates a public/private key pair. This key pair MUST be stored in stable storage; if there is no writable stable storage on the client, the client MUST be pre-configured with a public/ private key pair that can be used.When sending DNS updates, the service includes a KEY record containing the public portion of the key, which is stored as an RRset under the Service Instance Name. It is permissible for a device that offers more than one service under more than one Service Instance Name to useWhen sending DNS updates, thesameservice includes a KEYonrecord containing the public portion of the key in eachsuch name.Host Description update. The update is signed using SIG(0), using the private key that corresponds to the public key in the KEY record. The lifetimes of the records in the update is set using the EDNS(0) Update Lease option. The lifetime of the DNS-SD PTR,SRVSRV, A, AAAA and TXT records [RFC6763] is typically set to two hours. This means that if a device is disconnected from the network, it does not appear in the user interfaces of devices looking for services of that type for too long. However, the lifetime of itsDNS SIG(0) public keyKEY record should be set to a much longer time, typically 14 days. The result of this is that even though a device may be temporarily unplugged, disappearing from the network for a few days, it makes a claim on its name that lasts much longer. This way, even if a device is unplugged from the network for a few days, and its services are not available for that time, no other rogue device can come along and immediately claim its name the moment it disappears from thenetwork, and yetnetwork. In the event that a device is unplugged from the network and permanently discarded, then its name is eventually cleaned up and made available for re-use.2.4.1.2.2.4.2. Registration Server Behavior The Registration server checksthat the DNS update contains a Service Instance Name. In principle,eachnameupdate in theupdate should be evaluated asRegistration to see that it contains acandidateServiceInstance Name. However, some names will obviously beDiscovery update, a ServiceNames,Description update, andthese can be skipped when evaluating candidates. In order foracandidate to actually beHost Description update. An update is aservice instance name, the following conditions must be true:Service Discovery update if it contains oThere is at leastexactly onename that turns out NOTRRset update, o which is for a PTR RR, o which points tobea Service Instance Name o for whichtherean update isa PTR RRsetpresent in the Registration. An updatethat includesis arecord pointing toService Description update if, for thecandidate.appropriate Service Instance Name, it contains oThe candidate includes anexactly one "Delete all RRsets from a name" update, o exactly one SRVrecordRRset update, oThe candidate includes a KEYone or more TXT RRset updates, o and the target of the SRV recordIf anupdatedoes not containreferences avalid Service Instance Name, or ifhostname for which there is a Host Description update in the Registration. An update is a Host Description update if, for the appropriate hostname, it containsano exactly one "Delete all RRsets from a name" update, o A or AAAA RR update(s) o a KEY RR updatetothat adds aPTR RRsetKEY RR thatreferencescontains the public key corresponding to the private key that was used to sign the message, o there is anameService Instance Name update in the Registration that updates an SRV RR so thatis notit points to the hostname being updated by this update. A Registration MUST include at least one ServiceInstanceNamebeing updated, theupdate, at least one Service Description update, and exactly one Host Description update. An update message that does not isrejected with the NOTAUTH RCODE. If annot a Registration. An updatecontains an SRV recordmessage that containsan IP addressany otherthan the IP address from which the update was recieved, theupdates, or any update constraints, is not a Registration. Such messages should either be processed as regular RFC2136 updates, including access control checks and constraint checks, if supported, or else rejected with RCODE=REFUSED. Note that if theNOTAUTH RCODE. Oncedefinitions of eachname for which thereof these update types areupdates in the DNS Update has been considered asfollowed carefully, this means that many things that look very much like Registrations nevertheless are not. For example, acandidate, it should be the caseRegistration thatonly one name is actuallycontains an update to apossibleServiceInstance Name. If more than one name is stillName and an update to apossible candidate, thenService Instance Name, where theDNS UpdateService Name does not reference the Service Instance Name, isrejectednot a valid Registration message, but may be a valid RFC2136 update. Assuming that an update message has been validated withthe FORMERR RCODE. If therethese conditions and isonly one candidate, thena valid Registration, the server checksto see ifthat the namealreadyin the Host Description update exists. Ifit does already exist,so, then the server checks to see if the KEY record on the name is the same as theoneKEY record in theupdate for that name.update. If it is not, then theDNS Update is rejectedserver MUST reject the Registration with the YXDOMAIN RCODE. Otherwise, the server validates the update usingSIG(0).SIG(0) on the public key in the KEY record of the Host Description update. If the validation fails, theupdate isserver MUST reject the rejectration rejected withNOTAUTH.the REFUSED RCODE. Otherwise, the update isevaluatedconsidered valid and authentic, and is processed according to therulesmethod described inRFC2136 forRFC2136. The status that is returned depends on the result of processingDNS updates, and whateverthecorrect result isupdate. The server MAY add a Reverse Mapping that corresponds to the Host Description. This isreturned.not required because the Reverse Mapping serves no protocol function, but it may be useful for debugging, e.g. in annotating network packet traces or logs. The server MAY apply additional criteria when accepting updates. In some networks, it may be possible to do out-of-band registration of keys, and only accept updates from pre-registered keys. In this case, an update for a key that has not been registered should be rejectedusing NOTAUTH.with the REFUSED RCODE. There are at least two benefits to doing this rather than simply using normal SIG(0) DNS updates. First, the same registration protocol can be used in both cases, so both use cases can be addressed by the same service implementation. Second, the registration protocol includes maintenance functionality not present with normal DNS updates. Note that the semantics of using the Registration Protocol in this way are different than for typical RFC2136 implementations: the KEY used to sign the update in the Registration Protocol only allows the client to update records that refer to its Host Description. RFC2136 implementations do not normally provide a way to enforce a constraint of this type. The server may also have a dictionary of names or name patterns that are not permitted. If such a list is used, updates for Service Instance Names that match entries in the dictionary are rejected with YXDOMAIN. 2.5. TTL Consistency All RRs within an RRset are required to have the same TTL (Clarifications to the DNS Specification [RFC2181], Section 5.2). In order to avoid inconsistencies, the Registration Protocol places restrictions on TTLs sent by services and requires that Registration Protocol Servers enforce consistency. Services sending Registrations MUST use consistent TTLs in all RRs within the Registration. Registration Protocol servers MUST check that the TTLs for all RRs within the Registration are the same. If they are not, the Registration MUST be rejected with a REFUSED RCODE. Additionally, when adding RRs to an RRset, for example when processing Service Discovery records, the server MUST use the same TTL on all RRs in the RRset. How this consistency is enforced is up to the implementation. 2.6. Maintenance2.5.1.2.6.1. Cleaning up stale data Because the DNS-SD registration protocol is automatic, and not managed by humans, some additional bookkeeping is required. When an update is constructed by the client, it MUST include include an EDNS(0) Update LeaseoptionOption [I-D.sekar-dns-ul]. The Update Lease Option contains two lease times: the Update Lease Time andan EDNS(0)the Instance Leaseoption.Time. These leases are promises, similar to DHCP leases [RFC2131], from the client that it will send a new update for the service registration before the lease time expires. The Update Lease time is chosen to represent the time after the update during which the registered records other than the KEY record should be assumed to be valid. The Instance Lease time represents the time after the update during which the KEY record should be assumed to be valid. The reasoning behind the different lease times is discussed in the section on first-come, first-served naming Section 2.4.1. DNS-SD Registration Protocol servers may be configured with limits for these values. A default limit of two hours for the Update Lease and3014 days for theInstance LeaseSIG(0) KEY are currently thought to be good choices. Clients that are going to continue to use names on which they hold leases should update well before the lease ends, in case the registration service is unavailable or under heavy load. The Registration Protocol server MUST include an EDNS(0) Update Lease option in the response if the lease time proposed by the service has been shortened. The service MUST check for the EDNS(0) Update Lease option in the response and MUST use the lease times from that option in place of the options that it sent to the server when deciding when to update its registration. Clients should assume that each lease ends N seconds after the update was first transmitted, where N is thenumber included in the option.lease duration. Servers should assume that each lease ends N seconds after the update that was successfully processed was received. Because the server will always receive the update after the client sent it, this avoids the possibility of misunderstandings. DNS-SD Registration Protocol serversSHOULDMUST reject updates that do not includea DNS update lease time.an EDNS(0) Update Lease option. Dual-use serversmayMAY accept updates that don't include leases, but SHOULD differentiate between DNS-SD registration protocol updates and other updates, andSHOULDMUST reject updates that are known to be DNS-SDregistration protocolRegistration Protocol updates if they do not include leases.2.5.2.2.6.2. Sleep Proxy Another use of Service Registration Protocol is for devices that sleep to reduce power consumption. In this case, in addition to the DNS Update Lease option [I-D.sekar-dns-ul] described above, the device includes an EDNS(0) OWNER Option [I-D.cheshire-edns0-owner-option]. TheDNSEDNS(0) Update Lease option constitutes a promise by the device that it will wake up before this time elapses, to renew itsrecordsregistration and thereby demonstrate that it is still attached to the network. If it fails to renew therecordsregistration by this time, that indicates that it is no longer attached to the network, and itsrecordsregistration (except for the KEY in the Host Description) should be deleted. The EDNS(0) OWNER Option indicates that the device will be asleep, and will not be receptive to normal network traffic. When a DNS server receives a DNS Update with an EDNS(0) OWNER Option, that signifies that theDNSRegistration Protocol server shouldact asset up a proxy for any IPv4 or IPv6 address records in the DNS Update message. Thismeans that the DNS serverproxy should send ARP or ND messages claiming ownership of the IPv4 and/or IPv6 addresses in the records in question. In addition,the DNS serverproxy should answer future ARP or ND requests for those IPv4 and/or IPv6 addresses, claiming ownership of them. When the DNS server receives a TCP SYN or UDP packet addressed to one of the IPv4 or IPv6 addresses for which it proxying, it should then wake up the sleeping device using the information in the EDNS(0) OWNER Option. At present version 0 of the OWNER Option specifies the "Wake-on-LAN Magic Packet" that needs to be sent; future versions could be extended to specify other wakeup mechanisms. Note that although the authoritative DNS server that implements the DNSSD Service Registration Protocol function need not be on the same link as the sleeping host, the Sleep Proxy must be on the same link. 3. Security Considerations DNS-SD Service Registration Protocol updates have no authorization semantics other than first-come, first-served. This means that if an attacker from outside of the administrative domain of the server knows the server's IP address, it can in principle send updates to the server that will be processed successfully. Servers should therefore be configured to reject updates from source addresses outside of the administrative domain of the server. For Anycast updates, this validation must be enforced by every router that connects the CDN to the unconstrained portion of the network. For TCP updates, the initial SYN-SYN+ACK handshake prevents updates being forged from off-network. In order to ensure that this handshake happens, Service Discovery Protocol servers MUST NOT accept 0-RTT TCP payloads. Note that these rules only apply to the validation of DNS-SD registration protocol updates. A server that accepts updates from DNS-SD registration protocol clients may also accept other DNS updates, and those DNS updates may be validated using different rules. However, in the case of a DNS service that accepts automatic updates, the intersection of the DNS-SD service registration update rules and whatever other update rules are present must be considered very carefully. For example, a normal, authenticated RFC2136 update to any RR that was added using the Registration protocol, but that is authenticated using a different key, could be used to override a promise made by the registration protocol, by replacing all or part of the service registration information with information provided by a different client. An implementation that allows both kinds of updates should not allow updates to records added by Registrations using different authentication and authorization credentials. 4. Privacy Considerations 5. Acknowledgments Thanks to Toke Hoeiland-Joergensen for a thorough technical review, to Tamara Kemper for doing a nice developmental edit, Tim Wattenberg for doing a service implementation at the Montreal Hackathon at IETF 102, and [...] more reviewers to come, hopefully. 6. References5.1.6.1. Normative References [RFC6763] Cheshire, S. and M. Krochmal, "DNS-Based Service Discovery", RFC 6763, DOI 10.17487/RFC6763, February 2013, <https://www.rfc-editor.org/info/rfc6763>.5.2.[I-D.sekar-dns-ul] Sekar, K., "Dynamic DNS Update Leases", draft-sekar-dns- ul-01 (work in progress), August 2006. 6.2. Informative References [RFC1034] Mockapetris, P., "Domain names - concepts and facilities", STD 13, RFC 1034, DOI 10.17487/RFC1034, November 1987, <https://www.rfc-editor.org/info/rfc1034>. [RFC1035] Mockapetris, P., "Domain names - implementation and specification", STD 13, RFC 1035, DOI 10.17487/RFC1035, November 1987, <https://www.rfc-editor.org/info/rfc1035>. [RFC2131] Droms, R., "Dynamic Host Configuration Protocol", RFC 2131, DOI 10.17487/RFC2131, March 1997, <https://www.rfc-editor.org/info/rfc2131>. [RFC2136] Vixie, P., Ed., Thomson, S., Rekhter, Y., and J. Bound, "Dynamic Updates in the Domain Name System (DNS UPDATE)", RFC 2136, DOI 10.17487/RFC2136, April 1997, <https://www.rfc-editor.org/info/rfc2136>. [RFC2181] Elz, R. and R. Bush, "Clarifications to the DNS Specification", RFC 2181, DOI 10.17487/RFC2181, July 1997, <https://www.rfc-editor.org/info/rfc2181>. [RFC2931] Eastlake 3rd, D., "DNS Request and Transaction Signatures ( SIG(0)s )", RFC 2931, DOI 10.17487/RFC2931, September 2000, <https://www.rfc-editor.org/info/rfc2931>. [RFC3007] Wellington, B., "Secure Domain Name System (DNS) Dynamic Update", RFC 3007, DOI 10.17487/RFC3007, November 2000, <https://www.rfc-editor.org/info/rfc3007>. [RFC3152] Bush, R., "Delegation of IP6.ARPA", BCP 49, RFC 3152, DOI 10.17487/RFC3152, August 2001, <https://www.rfc-editor.org/info/rfc3152>. [RFC6760] Cheshire, S. and M. Krochmal, "Requirements for a Protocol to Replace the AppleTalk Name Binding Protocol (NBP)", RFC 6760, DOI 10.17487/RFC6760, February 2013, <https://www.rfc-editor.org/info/rfc6760>. [RFC6761] Cheshire, S. and M. Krochmal, "Special-Use Domain Names", RFC 6761, DOI 10.17487/RFC6761, February 2013, <https://www.rfc-editor.org/info/rfc6761>. [RFC6762] Cheshire, S. and M. Krochmal, "Multicast DNS", RFC 6762, DOI 10.17487/RFC6762, February 2013, <https://www.rfc-editor.org/info/rfc6762>. [RFC7228] Bormann, C., Ersue, M., and A. Keranen, "Terminology for Constrained-Node Networks", RFC 7228, DOI 10.17487/RFC7228, May 2014, <https://www.rfc-editor.org/info/rfc7228>. [I-D.ietf-dnssd-hybrid] Cheshire, S., "Discovery Proxy for Multicast DNS-Based Service Discovery", draft-ietf-dnssd-hybrid-08 (work in progress), March 2018.[I-D.sekar-dns-ul] Sekar, K., "Dynamic DNS Update Leases", draft-sekar-dns- ul-01[I-D.ietf-dnssd-push] Pusateri, T. and S. Cheshire, "DNS Push Notifications", draft-ietf-dnssd-push-14 (work in progress),August 2006.March 2018. [I-D.cheshire-dnssd-roadmap] Cheshire, S., "Service Discovery Road Map", draft- cheshire-dnssd-roadmap-01 (work in progress), March 2018. [I-D.cheshire-edns0-owner-option] Cheshire, S. and M. Krochmal, "EDNS0 OWNER Option", draft- cheshire-edns0-owner-option-01 (work in progress), July 2017. [ZC] Cheshire, S. and D. Steinberg, "Zero Configuration Networking: The Definitive Guide", O'Reilly Media, Inc. , ISBN 0-596-10100-7, December 2005. Authors' Addresses Stuart Cheshire Apple Inc.1 Infinite LoopOne Apple Park Way Cupertino, California 95014 USA Phone: +1 408 974 3207 Email: cheshire@apple.com Ted Lemon Nibbhaya Consulting P.O. Box 958 Brattleboro, Vermont 05302 United States of America Email: mellon@fugue.com