Chapter 6. Getting Started with Bonjour/Zeroconf
The previous chapters presented an overview of how the Zeroconf infrastructure works. The remainder of the book contains information on creating Zeroconf applications in a variety of settings. This chapter introduces the dns-sd command-line test tool, which lets you, the human user, perform common DNS-SD operations such as advertising services, browsing, and resolving. The dns-sd tool is not something you’d ever use in a shipping product, and it’s not intended to be used from shell scripts; it’s provided as a testing, development, and troubleshooting tool. It serves three main purposes.
First, if you’re a developer toying with the idea of adding Zeroconf to your product, the dns-sd tool allows you to experiment with “what if” scenarios, without writing a single line of code. If your product is a network camera that already supports RTSP and RTP video streaming, then the dns-sd tool lets you create a proxy advertisement for that camera, so that you can make it appear in the Open URL...menu in QuickTime Player 7, so you can get a feel for how the user experience could be for end users if the product had native Zeroconf support. When making a project proposal to management, being able to show a demo like this, interoperating with existing real-world software, is very compelling.
Second, when you’re ready to add Zeroconf to your product, the source code for the dns-sd tool (available from the Darwin open source repository) provides useful ...
Get Zero Configuration Networking: The Definitive Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.