geekman / mdns-repeater

mDNS repeater
GNU General Public License v2.0
193 stars 58 forks source link

mdns-repeater does not set TTL to 255 #10

Closed JeffFaer closed 2 years ago

JeffFaer commented 2 years ago

Poking around a bit, this looks like this is the official repository for mdns-repeater. Please correct me if I'm wrong, I saw a couple other copies of it floating around in github


I've been splitting my home network into multiple VLANs for security. I use a Unifi Security Gateway (USG) as a router. USGs offer mdns-repeater to rebroadcast mDNS packets between VLANs. I ran into an issue with mdns-repeater on the USG, and after some digging I think I've finally tracked down the problem: https://community.ui.com/questions/mDNS-repeater-doesnt-work-but-mDNS-reflector-does/646a3583-a510-4296-9b46-84c10bbe94be

The mDNS packets coming from mdns-repeater have an IP TTL of 1, when it's supposed to be 255: https://www.wireshark.org/lists/wireshark-bugs/201002/msg00513.html

All Multicast DNS responses (including responses sent via unicast) SHOULD be sent with IP TTL set to 255.

mdns-repeater should explicitly set an IP TTL of 255

I'm going to take a crack at resolving this, unless there are any objections

kennylevinsen commented 2 years ago

Poking around a bit, this looks like this is the official repository for mdns-repeater.

I guess what matters is what people are using. This fork of geekman's original code adds whitelist/blacklist and some fixes. If your mdns-repeater has that feature, then it might be this one.

JeffFaer commented 2 years ago

Ah, not sure how I missed that as the original one. I'll go ahead and try to patch both :shrug: