Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to search for all kinds of services? #58

Open
probonopd opened this issue Oct 28, 2022 · 4 comments
Open

How to search for all kinds of services? #58

probonopd opened this issue Oct 28, 2022 · 4 comments

Comments

@probonopd
Copy link
Contributor

How to search for all kinds of services?

This works, but only finds one type of service:

zeroConf.startBrowser("_http._tcp");

This doesn't work:

zeroConf.startBrowser(nullptr);
zeroConf.startBrowser("");
zeroConf.startBrowser("*");
zeroConf.startBrowser("*._tcp");

So if I need to find any service on the network regardless of its type or protocol, how would I do that? And how would I find all services on TCP?

@jbagg
Copy link
Owner

jbagg commented Oct 28, 2022

This is not supported in any form. startBrowser() is for only one service type at a time.

@probonopd
Copy link
Contributor Author

Thanks @jbagg. How hard would this be to implement?

@jbagg
Copy link
Owner

jbagg commented Oct 28, 2022

I don't know. I would suggest looking at avahi-discover. It is not a usual use case for ZeroConf as the app knows the service name it is looking for.

@probonopd
Copy link
Contributor Author

probonopd commented Nov 13, 2022

Possibly something along the lines of _services._dns-sd._udp.local. - that's at least what https://github.com/nitroshare/qmdnsengine is using in their example to find all services.

This is what Apple says:
https://developer.apple.com/library/archive/qa/qa1337/_index.html

Issuing a Multicast DNS PTR record query for the name _services._dns-sd._udp.local. will return a list of service types being advertised on the local network.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants