Zero-configuration networking

From Wikipedia, the free encyclopedia
  (Redirected from Zeroconf)
Jump to: navigation, search

Zero-configuration networking (zeroconf) is a set of technologies that automatically creates a usable computer network based on the Internet Protocol Suite (TCP/IP) when computers or network peripherals are interconnected. It does not require manual operator intervention or special configuration servers.

Zeroconf is built on three core technologies: assignment of numeric network addresses for networked devices, automatic distribution and resolution of computer hostnames, and automatic location of network services, such as printing devices. Without zeroconf, a network administrator must set up services, such as Dynamic Host Configuration Protocol (DHCP) and Domain Name System (DNS), or configure each computer's network settings manually.


Computer networks use numerical addresses to identify communications endpoints in a network of participating devices. This is similar to the telephone network, which assigns a string of digits to identify each telephone. In modern networking protocols, information to be transmitted is divided into a series of network packets. Every packet contains the source and destination addresses. Network routers examine these addresses to determine the best network path in forwarding the data packet at each step toward its destination.

Similarly to telephones displaying a number card, it was a common practice in early networks to attach an address label to networked devices. The dynamic nature of modern networks, especially residential networks in which devices are power up only when needed, requires ad-hoc, dynamic address assignment mechanisms that do not require user involvement for initialization and management. These systems automatically assign addresses to common names chosen either by the equipment manufacturer, such as a brand and model number, or chosen by users for identifying their equipment. The names and addresses are automatically entered into a directory service.

The early history of computer networking built upon technologies of the telecommunications networks and thus, protocols tended to fall into two groups, those intended to connect local devices into a local area network (LAN), and those intended primarily for long-distance communications. Wide area network (WAN) systems tended to have centralized setup, where an authority would assign addresses and names, often using manual means.

LAN systems tended to provide more automation of these tasks, so that new equipment could be added to a LAN with a minimum of operator intervention. An early example of a zero-configuration LAN system is AppleTalk, a protocol introduced by Apple Inc. for the early Macintosh computers in the 1980s. Macs, as well as other devices supporting the protocol like the Apple IIGS and a variety of printers and file servers, could be added to the network by plugging them in, all further configuration was automated. Network addresses were automatically selected by each device using a protocol known as AARP, while each machine built its own local directory service using a protocol known as NBP. NBP included not only a name, but the type of device and any additional user-provided information like its physical location or device status. Users could look up any device on the network with the application Chooser, which filtered names based on the device type.

On Internet Protocol networks, the Domain Name System was typically maintained manually by a network administrator. This led to the introduction of a number of new protocols providing automated services, such as the Dynamic Host Configuration Protocol (DHCP).

Address selection[edit]

Internet protocols assign objects in the network one or more unique IP addresses that identify them to other devices on the same network. These addresses operate in a fashion similar to telephone numbers, allowing devices to connect to each other by identifying the remote device by its address in the same way that a telephone call is connected by dialling in a telephone number.

Unlike the phone system, an IP network does not necessarily include some sort of central authority that assigns these addresses as new devices are added. Mechanisms were introduced to handle this task, and both IPv4 and IPv6 now include systems for address autoconfiguration, which allows a device to determine a safe address to use through simple mechanisms. For link-local addressing, IPv4 uses the special block as described in RFC 3927 while IPv6 hosts use the prefix fe80::/10. More commonly, in modern networks addresses are assigned by a DHCP server, often built-in to common networking hardware like computer hosts or routers.

Most IPv4 hosts use link-local addressing only as a last resort when a DHCP server is unavailable. An IPv4 host otherwise uses its DHCP-assigned address for all communications, global or link-local. One reason is that IPv4 hosts are not required to support multiple addresses per interface, although many do. Another is that not every IPv4 host implements distributed name resolution (e.g., multicast DNS), so discovering the autoconfigured link-local address of another host on the network can be difficult. However, discovering the DHCP-assigned address of another host also requires either distributed name resolution or a unicast DNS server with this information, and some networks feature DNS servers that are automatically updated with DHCP-assigned host and address information.

IPv6 hosts are required to support multiple addresses per interface; moreover, every IPv6 host is required to configure a link-local address even when global addresses are available. IPv6 hosts may additionally self-configure additional addresses on receipt of router advertisement messages, thus eliminating the need for a DHCP server.[1]

Both IPv4 and IPv6 hosts may randomly generate the host-specific part of an autoconfigured address. IPv6 hosts generally combine a prefix of up to 64 bits with a 64-bit EUI-64 derived from the factory-assigned 48-bit IEEE MAC address. The MAC address has the advantage of being globally unique, a property inherited by the EUI-64. The IPV6 protocol stack includes duplicate address detection to avoid conflicts with other hosts. In IPv4, the method is called link-local address autoconfiguration.[2] However, Microsoft refers to this as Automatic Private IP Addressing (APIPA)[3] or Internet Protocol Automatic Configuration (IPAC) (supported since at least Windows 98[4]).

Name resolution[edit]

Internet protocols use IP addresses for communications, but these are not really human-readable; IPv6 in particular uses very long strings of digits that are not easily entered manually. To address this issue, the internet has long used the Domain Name System (DNS), which allows human-readable names to be associated with IP addresses, and includes code for looking up these names from a hierarchical database system. Users type in common names, like, which the computer's DNS software looks up in the remote DNS databases, translates to the proper IP address, and then hands off that address to the networking software for further communications.[5]

Looking up a DNS address requires the IP address of the DNS server to be known. This has normally been accomplished by typing in the address of a known server into a field in one of the devices on the network. In early systems this was normally required on every device, but this has been pushed up one layer in the hierarchy to the DHCP servers or wide-area network devices like cable modems that receive this information from their IP provider. This has reduced the user-side administration load and provides a key element of zero-configuration access.[5]

DNS was intended to provide uniform names to groups of devices within the same administration realm, such as, provided by a name service. Assigning an address to a local device, e.g.,, normally requires administrator access to the DNS server and is often accomplished manually. Additionally, traditional DNS servers are not expected to automatically correct for changes in configuration. For instance, if a printer is moved from one floor to another it might be assigned a new IP address by the local DHCP server.[5]

To address the need for automatic configuration, Microsoft implemented NetBIOS Name Service part of which is the Computer Browser Service already in Microsoft Windows for Workgroups 3.11[6] as early as 1992, well before DNS or even the Internet was in common use. NetBIOS Name Service is zero-configuration on networks with a single subnet and may be used in conjunction with a WINS server or a (Microsoft) DNS server that supports (secure) automatic registration of addresses to have a management overhead that is small but not zero even on very large (enterprise) networks. The protocols NetBIOS can use are part of the CIFS suite of open protocols[6] which are implemented on Linux and iOS, although Windows typically supports a wider range of so called dialects which can be negotiated between (Windows) clients that support it. For example, Computer Browser Services running on server operating systems or later versions of Windows will be elected as so called Master Browser over those that are not running a server operating system or run older versions of Windows.[6]

In 2000, Bill Manning and Bill Woodcock described the Multicast Domain Name Service[7] which spawned the implementations by Apple and Microsoft. Both implementations are very similar. Apple's Multicast DNS (mDNS) is published as a standards track proposal (RFC 6762), while Microsoft's Link-local Multicast Name Resolution (LLMNR) is published as informational RFC 4795. LLMNR is included in every Windows version from Windows Vista onwards[8] and acts as a side-by-side alternative for Microsoft's NetBIOS Name Service over IPv4 and as a replacement over IPv6, since NetBIOS is not available over IPv6. Apples implementation is available as the Bonjour Service, previously Rendezvous, since 2002 in Mac OS X v10.2, but it comes with a limited use license and requires the signing of a license with Apple to redistribute.

Use of either NetBIOS or LLMNR services on Windows is essentially automatic, since using standard DNS client API's will result in the use of either NetBIOS or LLMNR depending on what name is being resolved (whether the name is a local name or not), the network configuration in effect (e.g. DNS suffixes in effect) and (in corporate networks) the policies in effect (whether LLMNR or NetBIOS are disabled), although developers may opt into bypassing these services for individual address lookups.

The mDNS and LLMNR protocols have minor differences in their approach to name resolution. mDNS allows a network device to choose a domain name in the local DNS namespace and announce it using a special multicast IP address. This introduces special semantics for the domain local,[9] which is considered a problem by some members of the IETF.[10] The current LLMNR draft allows a network device to choose any domain name, which is considered a security risk by some members of the IETF.[11] mDNS is compatible with DNS-SD as described in the next section, while LLMNR is not.[12]

Service discovery [edit]

Name services such as mDNS, LLMNR and others do not provide information about the type of device or its status. A user looking for a nearby printer, for instance, might be stymied if the printer was given the name "Bob". Service discovery provides additional information about devices. Service discovery is sometimes combined with a name service, as in Apple's name binding protocol and Microsoft's NetBIOS (including CIFS as supported on non-Microsoft operating systems).

NetBIOS Service Discovery[edit]

NetBIOS on Windows and its sibling CIFS on other operating systems, supports individual hosts on the network to advertise services, such as file shares and printers. It also supports for example a network printer to advertise itself as a host sharing a printer device and any related services it supports. Depending on how a device is attached (to the network directly, or to the host which shares it) and which protocols are supported however, Windows clients connecting to it may prefer to use SSDP or WSD over using NetBIOS. NetBIOS is one of the providers on Windows implementing the more general discovery process dubbed 'Function Discovery' which includes built-in providers for PnP, Registry, NetBIOS, SSDP and WSD[13] of which the former two are local-only and the latter three support discovery of networked devices. None of these need any configuration for use on the local subnet. NetBIOS has traditionally been supported only in expensive printers for use in companies and the cheapest devices of some brands today still don't have support for it, but home and SOHO users would connect printers to a computer over say a parallel port or USB and share it from the computer. However, today even entry-level printers with Wi-Fi or Ethernet support of some brands support it natively, allowing the printer to be used without configuration even on very old operating systems (combined with a generic PostScript driver, for example).


Web Services Dynamic Discovery (WS-Discovery) is a technical specification that defines a multicast discovery protocol to locate services on a local network. It operates over TCP and UDP port 3702 and uses IP multicast address As the name suggests, the actual communication between nodes is done using web services standards, notably SOAP over UDP. Windows supports it in the form of WSD and WPDS and many device and appliance manufacturers support it, such as HP and Brother printers.

DNS-based service discovery[edit]

DNS-SD allows clients to discover a named list of service instances, given a service type, and to resolve those services to hostnames using standard DNS queries. The specification is compatible with existing unicast DNS server and client software, but works equally well with Multicast DNS in a zero-configuration environment. Each service instance is described using a DNS SRV (RFC 2782) and DNS TXT (RFC 1035) record. A client discovers the list of available instances for a given service type by querying the DNS PTR (RFC 1035) record of that service type's name; the server returns zero or more names of the form "<Service>.<Domain>", each corresponding to a SRV/TXT record pair. The SRV record resolves to the domain name providing the instance, while the TXT can contain service-specific configuration parameter. A client can then resolve the A/AAAA record for the domain name and connect to the service.


In 1997 Stuart Cheshire proposed[14][self-published source?] adapting Apple's mature Name Binding Protocol to IP networks to address the lack of service discovery capability. Cheshire subsequently joined Apple and authored IETF draft proposals for Multicast DNS and DNS-based Service Discovery, supporting the transition from AppleTalk to IP networking. In 2002,[15] Apple announced an implementation of both protocols under the name Rendezvous (later renamed Bonjour), included in Mac OS X 10.2 and replacing the Service Location Protocol used in 10.1.[citation needed] In 2013, the proposals were ratified as RFC 6762[16] and RFC 6763.[17]

DNS-SD with multicast[edit]

Multicast DNS (mDNS) is a protocol that uses packets similar to unicast DNS except sent over a multicast link to resolve hostnames. Each host listens on the mDNS port, 5353, and resolves requests for the DNS record of its .local hostname (e.g. the A, AAAA, CNAME) to its IP address. When an mDNS client needs to resolve a local hostname to an the IP address, it sends a DNS request for that name to a well-known multicast address; the computer with the corresponding A/AAAA record replies with its IP address. The mDNS multicast address is for IPv4 and ff02::fb for IPv6 link-local addressing.

DNS service discovery (DNS-SD) requests can also be sent over a multicast link,[18] and it can be combined with mDNS to yield zero-configuration DNS-SD. It still uses DNS PTR, SRV, TXT records to advertise instances of service types, domain names for those instances, and optional configuration parameters for connecting to those instances. But SRV records can now resolve to multicastable .local domain names, which mDNS can resolve to local IP addresses.


DNS-SD is used by Apple products, most network printers, many Linux distributions including Debian and Ubuntu,[19] and a number of third party products for various operating systems. For example, many OS X network applications written by Apple, including Safari, iChat, and Messages, can use DNS-SD to locate nearby servers and peer-to-peer clients. On Windows, the operating system includes support for DNS-SD at least on Windows 10 for applications written using JavaScript[20] and other languages may be supported shortly. Individual applications may include their own support in older versions of the operating system, such that most instant messaging and VoIP clients on Windows support DNS-SD. Some Unix, BSD, and Linux distributions also include DNS-SD. For example, Ubuntu ships Avahi, an mDNS/DNS-SD implementation, in its base distribution.

Service types are given on a first-serve basis. A service type registry was originally maintained by,[21] but has since been merged into IANA's registry for DNS SRV records.[22]


UPnP has some protocol variants with the purpose of service discovery.


Simple Service Discovery Protocol (SSDP) is a UPnP protocol, used in Windows XP and later. SSDP uses HTTP notification announcements that give a service-type URI and a Unique Service Name (USN). Service types are regulated by the Universal Plug and Play Steering Committee. SSDP is supported by many printer, NAS and appliance manufacturers such as Brother, certain brands of network equipment, and in many SOHO firewall appliances, where host computers behind it may pierce holes for applications. It is also used in home theater PC systems, where media exchange between host computers and the media center is facilitated using SSDP.


DLNA is another suite of standards that uses UPnP for its discovery of networked devices, which has a long list of manufacturers producing devices that support it, such as TVs from most if not all large brands, NAS devices and so forth. As such, it is also supported by all major operating systems.

Efforts toward an IETF standard protocol[edit]

Service Location Protocol (SLP) is supported by Hewlett-Packard's network printers, Novell, and Sun Microsystems. SLP is described in RFC 2608 and RFC 3224 and implementations are available for both Solaris and Linux.


AllJoyn is an open source software stack for a myriad of devices, ranging from the tinyest IoT devices to the largest computers, for discovery and control of devices on networks (Wifi, Ethernet) and other links (Bluetooth, ZigBee, etc). It uses (amongst others) mDNS and HTTP over UDP.


RFC 3927, a standard for choosing addresses for networked items, was published in March 2005 by the Zeroconf IETF working group, which included individuals from Apple, Sun, and Microsoft.[23]

LLMNR was submitted for official adoption in the DNSEXT IETF working group, however failed to gain consensus and thus has been published as informational RFC only: RFC 4795.[24]

Following the failure of LLMNR to become an Internet standard, Apple was asked by the IETF to submit the mDNS/DNS-SD specs for publication as informational RFC as well, given that mDNS/DNS-SD is used much more widely than LLMNR. In February 2013 mDNS and DNS-SD were published as Standards Track Proposals RFC 6762 and RFC 6763.

RFC 2608, the SLP standard for figuring out where to get services, was published by the SVRLOC IETF working group.[25]

Security issues[edit]

Because mDNS operates under a different trust model than unicast DNS—trusting the entire network rather than a designated DNS server, it is vulnerable to spoofing attacks by any system within the multicast IP range. Like SNMP and many other network management protocols, it can also be used by attackers to quickly gain detailed knowledge of the network and its machines.[26] Because of this, applications should still authenticate and encrypt traffic to remote hosts (e.g. via RSA, SSH, etc.) after discovering and resolving them through DNS-SD/mDNS.

Major implementations[edit]

Apple Bonjour[edit]

Bonjour (formerly known as Rendezvous) from Apple Inc., uses multicast DNS and DNS Service Discovery. Apple changed its preferred zeroconf technology from SLP to mDNS and DNS-SD between Mac OS X 10.1 and 10.2, though SLP continues to be supported by Mac OS X.

Apple's mDNSResponder has interfaces for C and Java[27] and is available on BSD, Apple Mac OS X, Linux, other POSIX based operating systems and MS Windows. The Windows downloads are available from Apple's website.[28]


Avahi is a Zeroconf implementation for Linux and BSDs. It implements IPv4LL, mDNS and DNS-SD. It is part of most Linux distributions, and is installed by default on some. If run in conjunction with nss-mdns it also offers host name resolution.[29]

Avahi also implements binary compatibility libraries that emulate Bonjour and the historical mDNS implementation Howl, so software made to use those implementations can also utilize Avahi through the emulation interfaces.

MS Windows CE 5.0[edit]

Microsoft Windows CE 5.0 includes Microsoft's own implementation of LLMNR.

Link-local IPv4 addresses[edit]

There are some link-local IPv4 address implementations available:

  • Apple Mac OS and MS Windows have supported link-local addresses since 1998.[citation needed] Apple released its open-source implementation in the Darwin bootp package.
  • Avahi contains an implementation of IPv4LL in the avahi-autoipd tool.
  • Zero-Conf IP (zcip).[30]
  • BusyBox can embed a simple IPv4LL implementation.
  • Stablebox,[31] a fork from Busybox, offers a slightly modified IPv4LL implementation named llad.
  • Zeroconf,[32] a package based on Simple IPv4LL, a shorter implementation by Arthur van Hoff.[33]

The above implementations are all stand-alone daemons or plugins for DHCP clients that only deal with link-local IP addresses. Another approach is to include support in new or existing DHCP clients:

  • Elvis Pfützenreuter has written a patch for the uDHCP client/server.[34]
  • dhcpcd[35] is an opensource DHCP client for Linux and BSD that includes IPv4LL support. It is included as standard in NetBSD.

Neither of these implementations addresses kernel issues like broadcasting ARP replies[36] or closing existing network connections.

See also[edit]



  1. ^ RFC 4862, IETF 
  2. ^ RFC 3927, IETF 
  3. ^ "Apipa", MS Developer Network, Microsoft 
  4. ^ "How to use automatic TCP/IP addressing without a DHCP server", Knowledge base, Microsoft 
  5. ^ a b c Marshall Brain and Stephanie Crawford, "How Domain Name Servers Work", howstuffworks
  6. ^ a b c "Description of the Microsoft Computer Browser Service". Microsoft Knowledge Base. Microsoft. Retrieved 1 November 2015. 
  7. ^ Manning, Multicast Domain Name Service (draft), Water springs 
  8. ^ Microsoft TechNet Library Link-Local Multicast Name Resolution (webpage), Microsoft 
  9. ^ Re: Last Call: 'Linklocal Multicast Name Resolution (LLMNR)' to Proposed Standard (electronic mail message), IETF 
  10. ^ Re: Summary of the LLMNR Last Call (electronic mail message), IETF 
  11. ^ Summary of the LLMNR Last Call (electronic mail message), IETF 
  12. ^ More details on the differences (electronic mail message), IETF 
  13. ^ "About Function Discovery". Windows Dev Center. Microsoft. Retrieved 1 November 2015. 
  14. ^ Cheshire, Stuart, Name Binding Protocol over IP (rant) 
  15. ^ Zero conf 
  16. ^ "RFC 6762 Document History". IETF. 
  17. ^ "RFC 6763 Document History". IETF. 
  18. ^ RFC 6763, IETF 
  19. ^ "Ubuntu 15.10 desktop manifest". Ubuntu. Retrieved 23 October 2015. 
  20. ^ "Windows.Networking.ServiceDiscovery.Dnssd namespace". Windows Dev Center. Microsoft. Retrieved 1 November 2015. 
  21. ^ DNS-SD 
  22. ^ Service types, DNS-SD 
  23. ^ Zero Configuration Networking (zeroconf) Charter, IETF 
  24. ^ DNS Extensions (dnsext) Charter, IETF 
  25. ^ Service Location Protocol (svrloc) Charter, IETF 
  26. ^ Name (MDNS) Poisoning Attacks Inside the LAN (World Wide Web log), GNU citizen 
  27. ^ A Rendezvous with Java, Mac Dev Center, 2004-08-31 
  28. ^ "Bonjour for MS Windows 1.0.4", Support, Apple 
  29. ^ Lennart, nss-mdns 0.10, DE: 0 pointer 
  30. ^ zcip, Source forge 
  31. ^ "Stable box", Code, Google 
  32. ^ Zeroconf, AU: UTS 
  33. ^ AVH IPv4LL (C source code), Zero conf 
  34. ^ "Zeroconf in udhcpc", udhcpc (electronic mail message), Busy box, May 2005 
  35. ^ Marples, Roy, dhcpcd (wiki) (project) 
  36. ^ "Link-Local ARP Measurements", AIR (wiki), NE: UVA 
  37. ^ "Mac OS X v10.6: About Wake on Demand (Apple Article HT3774)". Apple. 2009-08-27. Retrieved 2009-09-15. Setting up Wake on Demand", "Setting up a Bonjour Sleep Proxy 


  • Guttman, Erik (2001), "Autoconfiguration for IP Networking: Enabling Local Communication", IEEE Internet Computing 5 (3): 81–86, doi:10.1109/4236.935181 

External links[edit]