how to parse MDNS response?

3.1k views Asked by At

We have some devices (Like IP cameras) on network. I am writing APIs in C to find these cameras. These cameras support multicast DNS query. I have the format for query, but I do not have the general response format. so that I could write API that can parse MDNS query responses. Can someone have MDNS parser, preferably implemented in C or exact format of the response. Thanks

1

There are 1 answers

1
caf On BEST ANSWER

mDNS responses are formatted as per standard DNS responses, described in RFC1035.

See also the Multicast DNS RFC6762, in particular sections 16, 17, 18 and 19, which cover some differences with Unicast DNS (eg. longer messages are allowed, a wider character set is allowed).