moz-extension:-URLs cannot be loaded by default, unless an extension
explicitly lists the resource in web_accessible_resources. At that
point, a URL is considered world-readable, and the load should succeed
regardless of the requested CORS mode in the fetch/request.
Differential Revision: https://phabricator.services.mozilla.com/D111016
For webcompat reasons, we have determined that we should only limit the length
of URIs in specific cases. We're going to handle this on the GV side instead.
Differential Revision: https://phabricator.services.mozilla.com/D109426
We only need to react to a completed captive portal check when the captive
portal was previously locked. When not in a captive portal, this notification
only means the check has completed - no network properties have changed.
Differential Revision: https://phabricator.services.mozilla.com/D109723
A TRR request is created and dispatched to the handling thread.
If we want to cancel it, we may do so before the runnable has been handled
and there's no HTTP channel - so the cancel was a NO-OP.
Here we add mCancelled which is consulted in SendHTTPRequest to check
if the request has already been cancelled.
Differential Revision: https://phabricator.services.mozilla.com/D109590
This patch consists of the changes generated by running
`./mach static-analysis check --fix` on `netwerk/dns` after adding the
`modernize-use-default-member-init` clang-tidy lint.
Some additional changes were made by hand to ensure consistent results.
This patch ensures that all member variables are initialized in the header,
so when adding or changing constructors we don't miss one resulting in
uninitialized memory.
Differential Revision: https://phabricator.services.mozilla.com/D109339
The reason this worked previously is that we initialized `recPtr = rec;` in
the for loop iterating through callbacks.
Records that were in the evictionQ did not have any callbacks, so we never
entered this block.
Differential Revision: https://phabricator.services.mozilla.com/D109338
When mTargetThread is WebSocketImpl it must be released on main since it
implements nsISupportsWeakReference, and clearing weak references is not
threadsafe.
Differential Revision: https://phabricator.services.mozilla.com/D109783
This adds support for nsIDelayedRunnableObserver to nsStreamTransportService.
This is a bit special because nsStreamTransportService uses an nsThreadPool.
Because of race conditions we cannot dispatch a final cleanup task to cancel any
pending DelayedRunnables.
Because of the inherent raciness of threads in the thread pool we assume that
any pending DelayedRunnables can handle being released on any thread. Thus we
dispatch the cleanup task to the background event target once the thread pool
has been shut down and processed all its events. This ensures no races can occur
between the cleanup task and OnDelayedRunnableScheduled.
Differential Revision: https://phabricator.services.mozilla.com/D109782
This change constitutes a way we can redirect users to an actual page that
explains what captive portals are and why we are making these requests.
Normally users should not see this page, as we only compare the contents
of a small html file. The meta redirect only happens when loaded in a
page.
The SUMO URL https://support.mozilla.org/kb/captive-portal will automatically
redirect to the appropriate locale.
Differential Revision: https://phabricator.services.mozilla.com/D99773
We only need to react to a completed captive portal check when the captive
portal was previously locked. When not in a captive portal, this notification
only means the check has completed - no network properties have changed.
Differential Revision: https://phabricator.services.mozilla.com/D109723
A TRR request is created and dispatched to the handling thread.
If we want to cancel it, we may do so before the runnable has been handled
and there's no HTTP channel - so the cancel was a NO-OP.
Here we add mCancelled which is consulted in SendHTTPRequest to check
if the request has already been cancelled.
Differential Revision: https://phabricator.services.mozilla.com/D109590