Comments (4)
To me it makes sense what you say, but maybe somebody more familiar with the mDNS spec can comment as well?
from jmdns.
I further investigated this issue and here are some results and thoughts:
Linux does not even allow multicasts on the loopback device, so I think it is fine to ignore loopback devices in general. The only situation where it could be useful is if you have a Service and Client both on the same machine without network interfaces. I cannot think of many such situations.
I tried to find the culprit why the local loopback address is propagated in other networks. Therefor I skimmed the mDNS RFC. I think this issue comes from another issue with the Windows loopback device and IPv6.
I think that there is a bug in the Windows IPv6 implementation of the loopback device. If I multicast a link-local IPv6 packet to the loopback, it is also propagated to other ethernet devices. It does not with IPv4 link-local packets. So I also skimmed the IPv6 RFC where it's said:
Link-Local addresses are designed to be used for addressing on a single link for purposes such as auto-address configuration, neighbor discovery, or when no routers are present.Routers must not forward any packets with link-local source or destination addresses to other links.
IMHO this seems to be done wrong in Windows (10). As multicasts are not only propagated to the local ethernet interface but also through the network of the ethernet interface, a client gets the loopback IP address. This is whats causing me problems with iOS.
To sum it up: I suggest to not bind a JmDNS instance to a loopback device. So if you agree with it, I can create a pull-request of my changes.
from jmdns.
Hi @dhufnagel, sorry for my late response. Yes, I am fine with your suggested change - please create a PR for it!
from jmdns.
Actually, I just did, assuming this is the fix you wanted to propose: #87
from jmdns.
Related Issues (20)
- serviceResolved called infinitely for a single service registration
- Registered service not discoverable by Windows 10 Pro
- Make mdns group address configurable HOT 2
- Overly extensive and superfluous Logging in DNSIncoming.readAnswer
- Sending malformed packets when ServiceInfo.setText(byte[] text)
- Unable to see ChromeCast after reboot
- Fail to get correct Bonjour Name. 4byte character is not coverted correctly. HOT 9
- Call getServiceInfo periodially, it returns null sometimes HOT 4
- ServiceInfo returns address as null:8080 and unable to access .local address
- www.jmdns.org website is offline HOT 4
- Is potential issue for updating service info from TYPE_PTR record?
- Unable to detect service restart HOT 1
- Threads won't finish after closing the instance
- JmDNS.create() fails when IPv6 protocol of my network interface is disabled in Windows 10 and JRE 17.0.5 HOT 2
- IPv6 related NPE in ServiceInfoImpl.getHostAddresses() HOT 4
- Rare StringIndexOutOfBoundsException in ServiceTypeDecoder.originalCase() HOT 5
- JmDNS seems not bind the specified IP to the source socket
- Resolving too many services at once causes performance degradation
- com.google.inject.ProvisionException: Unable to provision
- ServiceListener serviceAdded not always called
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jmdns.