Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to advertise a Bonjour Service in Visual C++

I'm trying to figure out if this is even possible, but what's the simplest way of advertising a Bonjour service through Visual C++?

like image 456
David26th Avatar asked Aug 11 '10 22:08

David26th


People also ask

What are Bonjour services?

Bonjour, also known as zero-configuration networking, enables automatic discovery of devices and services on a local network using industry standard IP protocols.

What is Bonjour service in Task Manager?

Bonjour, meaning hello in French, allows for zero-configuration networking between different types of devices. You can use it to find other Apple services on a network, connect to other devices like network printers (that provide Bonjour support), or access shared drives.


1 Answers

You can use the DNS Service Discovery client: dns-sd.

Windows Bonjour Installer puts it in C:\Windows\system32\dns-sd.exe

Its synopsis is:

 dns-sd -R name type domain port [key=value ...]

 dns-sd -B type domain

 dns-sd -L name type domain

There isn't any easy way to find indepth Bonjour windows documentation, (and it's a serious shame) but here's the manpage for its mac equivalent:
http://developer.apple.com/.../dns-sd.1.html

There is also C:\Windows\system32\dnssd.dll whose API, I unfortunately have to suppose, conforms to this document:
http://developer.apple.com/.../dns_sd_h/

like image 87
ZJR Avatar answered Nov 15 '22 02:11

ZJR