nsISerialEventTarget is more semantically accurate for these uses, as the
dispatched runnables cannot run in parallel. It also allows us to use
InvokeAsync in future patches, as that function only takes nsISerialEventTarget.
Differential Revision: https://phabricator.services.mozilla.com/D49262
--HG--
extra : moz-landing-system : lando
nsISerialEventTarget is more semantically accurate for these uses, as the
dispatched runnables cannot run in parallel. It also allows us to use
InvokeAsync in future patches, as that function only takes nsISerialEventTarget.
Differential Revision: https://phabricator.services.mozilla.com/D49262
--HG--
extra : moz-landing-system : lando
If there are multiple pending queries, this allows up to five of them to be
sent in a single packet. This also adds a check to ensure we don't already have
a pending query for a hostname prior to sending a new query.
Differential Revision: https://phabricator.services.mozilla.com/D46983
--HG--
extra : moz-landing-system : lando
We need to join the multicast group on all network interfaces or we may end up
missing packets. There is a limit on the number of groups joinable by a single
socket (20 on my Linux system) but it doesn't seem worth worrying about
hitting that limit at the moment as it seems unlikely that many users would
have more than 20 network interfaces on a system on which they are running
Firefox.
Differential Revision: https://phabricator.services.mozilla.com/D46981
--HG--
extra : moz-landing-system : lando
This adds Rust unit tests for some of the edge cases in handling queries
like limits and retries.
Differential Revision: https://phabricator.services.mozilla.com/D46980
--HG--
extra : moz-landing-system : lando
This limits the number of pending mDNS queries to 50, adds support for
retrying queries if they timeout, and support for reporting failure if a query
times out twice in a row.
Differential Revision: https://phabricator.services.mozilla.com/D46979
--HG--
extra : moz-landing-system : lando
We don't want web content to use mDNS to map out the local network, so
we only support registering and querying hostnames that are valid
UUIDs (followed by .local).
Differential Revision: https://phabricator.services.mozilla.com/D46978
--HG--
extra : moz-landing-system : lando
This adds basic query support to the mdns_service. Support for limiting
the number of pending queries, timeouts and retries is added in
another commit in this series.
Differential Revision: https://phabricator.services.mozilla.com/D46975
--HG--
extra : moz-landing-system : lando
Also, since OnProxyAvailable always happens on main regardless of the target we
set, don't bother setting the target.
Differential Revision: https://phabricator.services.mozilla.com/D46603
--HG--
extra : moz-landing-system : lando
The Rust get_if_addrs library previously used does not build on Android with
our build system. Since we're already using nICEr to determine the local
interface addresses, rather than fix the Rust library, we can use those
addresses to set the interface on which mdns_service listens.
Differential Revision: https://phabricator.services.mozilla.com/D42760
--HG--
extra : moz-landing-system : lando
The current code causes one mDNS service to be created for each PeerConnection.
Due to Bug 1569311, the services persist until shutdown, which can lead to a
lot of mDNS threads running on sites which use WebRTC for fingerprinting. This
change makes it so we start at most one mDNS service.
I've filed Bug 1569955 to look at shutting down the mDNS service after the
last hostname is unregistered. As an alternative, if we fix Bug 1569311, we
could also use refcounting and stop the mDNS service after the last
StunAddrsRequestParent is freed.
Differential Revision: https://phabricator.services.mozilla.com/D42151
--HG--
extra : moz-landing-system : lando
With the move to the socket process, the UUID service is no longer available
in nricectx. This adds a pair of helper functions to mdns_service to generate
UUIDs and uses them to generate hostnames inside nricectx.
Differential Revision: https://phabricator.services.mozilla.com/D42150
--HG--
extra : moz-landing-system : lando
This only enables mDNS on OS X for now. Some versions of Windows lack mDNS
support, there are some oddities with resolving IPv6 addresses on Linux, and
Android has not yet been tested. All of these will be addressed in follow on
bugs.
Differential Revision: https://phabricator.services.mozilla.com/D38496
--HG--
extra : moz-landing-system : lando
This adds a mdns_service to mtransport to handle responding to mDNS queries.
All hostnames will be generated from UUIDs, so the responder assumes that it
is the only responder for a hostname which is registered with it. Because of
this, the responder does not first make a DNS query itself to see if any other
responder is handling a hostname, and does not wait a random amount of time
before replying, both of which are required by the specification to avoid
collisions with other responders.
Differential Revision: https://phabricator.services.mozilla.com/D38489
--HG--
extra : moz-landing-system : lando
The Rust get_if_addrs library previously used does not build on Android with
our build system. Since we're already using nICEr to determine the local
interface addresses, rather than fix the Rust library, we can use those
addresses to set the interface on which mdns_service listens.
Differential Revision: https://phabricator.services.mozilla.com/D42760
--HG--
extra : moz-landing-system : lando
The current code causes one mDNS service to be created for each PeerConnection.
Due to Bug 1569311, the services persist until shutdown, which can lead to a
lot of mDNS threads running on sites which use WebRTC for fingerprinting. This
change makes it so we start at most one mDNS service.
I've filed Bug 1569955 to look at shutting down the mDNS service after the
last hostname is unregistered. As an alternative, if we fix Bug 1569311, we
could also use refcounting and stop the mDNS service after the last
StunAddrsRequestParent is freed.
Differential Revision: https://phabricator.services.mozilla.com/D42151
--HG--
extra : moz-landing-system : lando
With the move to the socket process, the UUID service is no longer available
in nricectx. This adds a pair of helper functions to mdns_service to generate
UUIDs and uses them to generate hostnames inside nricectx.
Differential Revision: https://phabricator.services.mozilla.com/D42150
--HG--
extra : moz-landing-system : lando
This only enables mDNS on OS X for now. Some versions of Windows lack mDNS
support, there are some oddities with resolving IPv6 addresses on Linux, and
Android has not yet been tested. All of these will be addressed in follow on
bugs.
Differential Revision: https://phabricator.services.mozilla.com/D38496
--HG--
extra : moz-landing-system : lando
This adds a mdns_service to mtransport to handle responding to mDNS queries.
All hostnames will be generated from UUIDs, so the responder assumes that it
is the only responder for a hostname which is registered with it. Because of
this, the responder does not first make a DNS query itself to see if any other
responder is handling a hostname, and does not wait a random amount of time
before replying, both of which are required by the specification to avoid
collisions with other responders.
Differential Revision: https://phabricator.services.mozilla.com/D38489
--HG--
extra : moz-landing-system : lando