Commit Graph

17569 Commits

Author SHA1 Message Date
Valentin Gosu
785fc97f60 Bug 1518208 - Respect network.trr.excluded-domains in TRR-only mode r=dragana
Normally you wouldn't want localhost or *.local domain to be resolved by a
remote resolver.
This patch makes sure that even if we are in TRR-only mode, we still
successfully resolve the domains specified by network.trr.excluded-domains
using native DNS.

Also fixes bug in TRRService::ReadPrefs where we didn't clear mExcludedDomains
before reading the pref.

Differential Revision: https://phabricator.services.mozilla.com/D24380

--HG--
extra : moz-landing-system : lando
2019-03-28 13:15:05 +00:00
Mark Banner
dba6983e75 Bug 1415265 - Remove now unnecessary .eslintrc.js files or entries. r=mossop
Differential Revision: https://phabricator.services.mozilla.com/D23850

--HG--
extra : moz-landing-system : lando
2019-03-28 09:38:14 +00:00
Haik Aftandilian
77b79862cf Bug 1452278 - Part 1 - Make macOS nsOSHelperAppService::GetFromTypeAndExtension() not call OS MIME API's in content r=bzbarsky,froydnj
Add a new nsExternalHelperAppService derived class named nsOSHelperAppServiceChild to be used for the MIME service, external helper app service, and external protocol service interfaces in child processes. nsOSHelperAppServiceChild overrides some methods used to get MIME and external protocol handler information from the OS and implements these methods by remoting the calls to the parent process.

This is necessary because, on Mac, querying the OS for helper application info from sandboxed content processes is unreliable and has buggy side effects.

For now, only use the new class on Mac.

Android and unix file changes r+ by gcp.
Windows files changes r+ by bobowen.
Sync messages review r+ by nfroyd.

MozReview-Commit-ID: 63BiS6VCxfn

Differential Revision: https://phabricator.services.mozilla.com/D15620

--HG--
extra : moz-landing-system : lando
2019-03-27 22:49:33 +00:00
arthur.iakab
7654bfed1e Backed out 2 changesets (bug 1452278) for mingwclang build bustages on win/nsOSHelperAppService.h CLOSED TREE
Backed out changeset f11d78387bd9 (bug 1452278)
Backed out changeset 656f17a2553b (bug 1452278)
2019-03-27 22:03:07 +02:00
Haik Aftandilian
b8118af581 Bug 1452278 - Part 1 - Make macOS nsOSHelperAppService::GetFromTypeAndExtension() not call OS MIME API's in content r=bzbarsky,froydnj
Add a new nsExternalHelperAppService derived class named nsOSHelperAppServiceChild to be used for the MIME service, external helper app service, and external protocol service interfaces in child processes. nsOSHelperAppServiceChild overrides some methods used to get MIME and external protocol handler information from the OS and implements these methods by remoting the calls to the parent process.

This is necessary because, on Mac, querying the OS for helper application info from sandboxed content processes is unreliable and has buggy side effects.

For now, only use the new class on Mac.

Android and unix file changes r+ by gcp.
Windows files changes r+ by bobowen.
Sync messages review r+ by nfroyd.

MozReview-Commit-ID: 63BiS6VCxfn

Differential Revision: https://phabricator.services.mozilla.com/D15620

--HG--
extra : moz-landing-system : lando
2019-03-27 19:23:32 +00:00
Michal Novotny
98cbfe2ba6 Bug 1533369 - Add content type to cache index, r=mayhemer
This patch adds content-type to metadata in cache entry and it is then propagated down to the cache index.

Differential Revision: https://phabricator.services.mozilla.com/D23504

--HG--
extra : moz-landing-system : lando
2019-03-27 14:32:12 +00:00
Andrea Marchesini
b4a2e3cb6d Bug 1536488 - Tracking-annotation should use strict list always, r=dimi
Differential Revision: https://phabricator.services.mozilla.com/D24053

--HG--
extra : moz-landing-system : lando
2019-03-27 13:51:27 +00:00
Kershaw Chang
2efb2d1bce Bug 1539148 - Make sure http channel is release on main thread when calling NS_ShouldSecureUpgrade r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D25028

--HG--
extra : moz-landing-system : lando
2019-03-27 12:09:01 +00:00
Sebastian Streich
82fb5d3ddf Bug 1386214 - Remove require-sri from the CSP-Module r=ckerschb,qdot
Differential Revision: https://phabricator.services.mozilla.com/D24880

--HG--
extra : moz-landing-system : lando
2019-03-26 21:58:48 +00:00
Matthew Noorenberghe
edd6809d0c Bug 1533925 - Allow about: pages to be forced into the extension process. r=kmag
Some extensions want to implement about: pages and we want those pages to be loaded in the extension process, not in the web content process, so that:
1) a compromised web process won't get access to the about: page content
2) the extension page can use all the APIs that extension pages normally get, instead of only content script APIs.

Post-Fission we will need to know which extension process to choose.

Differential Revision: https://phabricator.services.mozilla.com/D24989

--HG--
extra : moz-landing-system : lando
2019-03-27 04:07:15 +00:00
Cosmin Sabou
78fc71e3c3 Backed out changeset 7fa7d6e6dedc (bug 1442778) for devtools failures on browser_webconsole_check_stubs_console_api.js CLOSED TREE 2019-03-26 20:27:55 +02:00
Eden Chuang
5e4df764d9 Bug 1442778 - Add "chromeContext" parameter to console API and console service messages. r=smaug
1. Adding a new attribute chromeContext in ConsoleEvent
2. Adding a new boolean attribute isFromChromeContext in nsIConsoleMessage
3. Sending IsFromChromeContext to the parent process

Differential Revision: https://phabricator.services.mozilla.com/D23330

--HG--
extra : moz-landing-system : lando
2019-03-26 15:18:20 +00:00
Andrea Marchesini
a8466fb647 Bug 1487113 - nsHttpChannel should return the Content-Length even when alt-data is available if not delivered, r=valentin
Without this patch, content-length getter returns 0 if we have an available
alt-data because we don't distinguish between having and using it.

Differential Revision: https://phabricator.services.mozilla.com/D24875

--HG--
extra : moz-landing-system : lando
2019-03-26 12:00:42 +00:00
Honza Bambas
0d286523d2 Bug 1527712 - Move I/O in nsFileChannel::OpenContentStream to a background thread, r=kershaw,dragana
Differential Revision: https://phabricator.services.mozilla.com/D23352

--HG--
extra : moz-landing-system : lando
2019-03-25 19:31:06 +00:00
Valentin Gosu
784b4209b8 Bug 1532395 - Clear the DNS cache before each TRR test r=JuniorHsu
It is likely that the test is flaky because we resolve the same host with a different TRR endpoint and sometimes we use a cached record.
We should clear the DNS cache before each test to ensure that we're actually checking the right thing.

Differential Revision: https://phabricator.services.mozilla.com/D24355

--HG--
extra : moz-landing-system : lando
2019-03-25 17:55:45 +00:00
Christoph Kerschbaumer
6417ca1ace Bug 1537883: Dump JS Stacktace in case aPrincipal is null within nsIOService::SpeculativeConnectInternal. r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D24704

--HG--
extra : moz-landing-system : lando
2019-03-25 14:08:13 +00:00
dlee
dabe54958d Bug 1522412 - P5. Do not use system principal in testcase to test tracking protection. r=Ehsan
Some testcases are chrome scope testcase hence the resources it loads are triggered by
"system principal". This will exempt the resource from classification.

So in this patch, we used a new window to for the tracker test frame.
The window creation code is referenced from test_privatebrowsing_trackingprotection.html.

Differential Revision: https://phabricator.services.mozilla.com/D22114

--HG--
extra : moz-landing-system : lando
2019-03-25 12:49:28 +00:00
dlee
d7d67be8c9 Bug 1522412 - P3. Adopt nsIChannel.LOAD_BYPASS_URL_CLASSIFIER in the algorithm determining if we should classify a channel's URI. r=Ehsan,mayhemer
This patch uses the flag to exempt channels from classification, but it
doesn't include the use cases of this flag.

See Bug 1442496 for the list of the call sites should use this flag.

Differential Revision: https://phabricator.services.mozilla.com/D22112

--HG--
extra : moz-landing-system : lando
2019-03-25 12:48:25 +00:00
dlee
9878ae650d Bug 1522412 - P2. Remove nsIChannel.LOAD_CLASSIFY_URI flag. r=Ehsan
nsIChannel.LOAD_CLASSIFY_URI is no longer required so we can remove it from
the codebase.
In the mean time, we add a new LOAD_BYPASS_URL_CLASSIFIER load flag for
channel creator to be able to force channel to bypass URL classifier check.
The use of the new LOAD_BYPASS_URL_CLASSIFIER flag will be addressed in
the other patches.

Differential Revision: https://phabricator.services.mozilla.com/D22111

--HG--
extra : moz-landing-system : lando
2019-03-25 12:47:57 +00:00
dlee
5f710bb93b Bug 1522412 - P1. Replace LOAD_CLASSIFY_URI flag with a heuristic algorithm. r=Ehsan,mayhemer
In this patch, we move from a model where URL classification is opt-in
(by specifying LOAD_CLASSIFIER_URI) to a model where it is enforced by
default unless a channel opts out or is deemed to be a critical channel
based on simple heuristics.

The heuristics exempt a channel from classification if it is triggered
by system with an exception when it is a top level load.

To ensure critical channels are never classified, we also exempt
channels which are flagged as "BeConservative" (implemented in bug 1321783).
Another load flag LOAD_BYPASS_URL_CLASSIFIER is also introduced
for the same reason.

Differential Revision: https://phabricator.services.mozilla.com/D22110

--HG--
extra : moz-landing-system : lando
2019-03-25 12:47:29 +00:00
Kershaw Chang
4311c49299 Bug 1536236 - Make sure mDNSPrefetch is always released on main thread r=valentin
This patch should make mDNSPrefetch to be released always on main thread.

Differential Revision: https://phabricator.services.mozilla.com/D24685

--HG--
extra : moz-landing-system : lando
2019-03-25 12:39:45 +00:00
Honza Bambas
5d737c4b15 Bug 1538535 - backout bug 1527712 2019-03-24 11:51:36 +01:00
Sylvestre Ledru
289f40d6de Bug 1538199 - Remove an useless declaration in TRR.cpp r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D24506

--HG--
extra : moz-landing-system : lando
2019-03-23 18:24:04 +00:00
Honza Bambas
3db65d831e Bug 1536387 - Part 2: enhance the range for allowed http cache storage key tag character values, r=michal
Differential Revision: https://phabricator.services.mozilla.com/D24342

--HG--
extra : moz-landing-system : lando
2019-03-22 23:22:37 +00:00
Emilio Cobos Álvarez
a841bd0f2a Bug 1538207 - Don't call into the prefs service OMT. r=decoder
Use a VarCache instead.

Differential Revision: https://phabricator.services.mozilla.com/D24514

--HG--
extra : moz-landing-system : lando
2019-03-22 16:29:27 +00:00
Valentin Gosu
2bcda024e0 Bug 1536236 - Release mDNSPrefetch in OnStopRequest (on the main thread) r=kershaw
nsDNSPrefetch holds a weak reference to nsHttpChannel. Weak references are not thread safe so, nsDNSPrefetch needs to be released on the main thread, in OnStopRequest.
Otherwise it gets released when the last reference to nsHttpChannel is dropped, which could be from another thread.

Differential Revision: https://phabricator.services.mozilla.com/D24174

--HG--
extra : moz-landing-system : lando
2019-03-21 16:48:32 +00:00
Christian Holler
91f594a077 Bug 1526258 - Implement fuzzing layer in networking for socket emulation. r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D23194

--HG--
extra : moz-landing-system : lando
2019-03-20 14:40:44 +00:00
Gurzau Raul
f6782a38fb Backed out changeset 3e21362cd4dc (bug 1536387) for build bustage at CacheFileUtils.cpp on a CLOSED TREE. 2019-03-21 18:21:43 +02:00
Valentin Gosu
8a11162b6b Bug 1450893 - Add pref for list of domains excluded from TRR r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D24291

--HG--
extra : moz-landing-system : lando
2019-03-21 12:41:41 +00:00
Valentin Gosu
50597c68ef Bug 1450893 - Add way to clear DNS cache r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D24300

--HG--
extra : moz-landing-system : lando
2019-03-21 12:41:39 +00:00
Honza Bambas
dee2f46076 Bug 1536387 - Part 2: enhance the range for allowed http cache storage key tag character values, r=michal
Differential Revision: https://phabricator.services.mozilla.com/D24342

--HG--
extra : moz-landing-system : lando
2019-03-21 13:01:15 +00:00
Gurzau Raul
2666e16a53 Backed out 7 changesets (bug 1522412) for xpcshell failures at test_shouldclassify.js on a CLOSED TREE.
Backed out changeset 7c998456e1fd (bug 1522412)
Backed out changeset ebb581ddf1d1 (bug 1522412)
Backed out changeset 850e1c68d978 (bug 1522412)
Backed out changeset fe288a48cecb (bug 1522412)
Backed out changeset 5399bca472b1 (bug 1522412)
Backed out changeset 91e5b339fe11 (bug 1522412)
Backed out changeset b80098d0a5c4 (bug 1522412)
2019-03-21 11:02:09 +02:00
dlee
baafcf7605 Bug 1522412 - P5. Do not use system principal in testcase to test tracking protection. r=Ehsan
Some testcases are chrome scope testcase hence the resources it loads are triggered by
"system principal". This will exempt the resource from classification.

So in this patch, we used a new window to for the tracker test frame.
The window creation code is referenced from test_privatebrowsing_trackingprotection.html.

Differential Revision: https://phabricator.services.mozilla.com/D22114

--HG--
extra : moz-landing-system : lando
2019-03-21 07:34:17 +00:00
Dimi Lee
fe284ca3d4 Bug 1522412 - P3. Adopt nsIChannel.LOAD_BYPASS_URL_CLASSIFIER in the algorithm determining if we should classify a channel's URI. r=Ehsan,mayhemer
This patch uses the flag to exempt channels from classification, but it
doesn't include the use cases of this flag.

See Bug 1442496 for the list of the call sites should use this flag.

Differential Revision: https://phabricator.services.mozilla.com/D22112

--HG--
extra : moz-landing-system : lando
2019-03-21 07:32:46 +00:00
Dimi Lee
8f1caf4049 Bug 1522412 - P2. Remove nsIChannel.LOAD_CLASSIFY_URI flag. r=Ehsan
nsIChannel.LOAD_CLASSIFY_URI is no longer required so we can remove it from
the codebase.
In the mean time, we add a new LOAD_BYPASS_URL_CLASSIFIER load flag for
channel creator to be able to force channel to bypass URL classifier check.
The use of the new LOAD_BYPASS_URL_CLASSIFIER flag will be addressed in
the other patches.

Differential Revision: https://phabricator.services.mozilla.com/D22111

--HG--
extra : moz-landing-system : lando
2019-03-21 07:30:51 +00:00
Dimi Lee
d97a1a7436 Bug 1522412 - P1. Replace LOAD_CLASSIFY_URI flag with a heuristic algorithm. r=Ehsan,mayhemer
In this patch, we move from a model where URL classification is opt-in
(by specifying LOAD_CLASSIFIER_URI) to a model where it is enforced by
default unless a channel opts out or is deemed to be a critical channel
based on simple heuristics.

The heuristics exempt a channel from classification if it is triggered
by system with an exception when it is a top level load.

To ensure critical channels are never classified, we also exempt
channels which are flagged as "BeConservative" (implemented in bug 1321783).
Another load flag LOAD_BYPASS_URL_CLASSIFIER is also introduced
for the same reason.

Differential Revision: https://phabricator.services.mozilla.com/D22110

--HG--
extra : moz-landing-system : lando
2019-03-21 07:29:48 +00:00
Andrea Marchesini
6449f116c4 Bug 1534343 - Document should check if its mCookieSettings exists before using it, r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D23764

--HG--
extra : moz-landing-system : lando
2019-03-21 06:44:00 +00:00
Alex Gaynor
1ad3f60e94 Bug 1536163 - Part 2 - use native Maybe syntax in place of MaybePrefValue in IPDL; r=mccr8
--HG--
extra : rebase_source : 9c93e3b61ceef67e33242af4415e144ff16ba49d
2019-03-21 06:51:43 +02:00
Mark Goodwin
50887394d6 Bug 1429796 Cleanup storage in CertBlocklist to allow easy addition of new types of pair (e.g. whitelist entries) r=keeler
Differential Revision: https://phabricator.services.mozilla.com/D17668

--HG--
extra : moz-landing-system : lando
2019-03-20 17:00:47 +00:00
Honza Bambas
5ffebc7b88 Bug 1536387 - Append a regular HTTP cache key tag of value 0x7f to distinguish memory-only entries, r=michal
Differential Revision: https://phabricator.services.mozilla.com/D24170

--HG--
extra : moz-landing-system : lando
2019-03-20 13:54:57 +00:00
Andreea Pavel
c3cd918c5c Backed out 2 changesets (bug 1429796) for failing xperf on a CLOSED TREE
Backed out changeset b0d08863f7a5 (bug 1429796)
Backed out changeset 1bd54f8dfd9e (bug 1429796)
2019-03-20 00:03:49 +02:00
Edwin Gao
fed5f980bc Bug 1536211 - disable tests in netwerk/test/unit/ that requires http/2 server r=jmaher
Disable the following tests, with 1536211 serving as the tracking bug:
- test_header_Server_Timing.js (1530871)
- test_trr.js (1532395)
- test_esni_dns_fetch.js (1530752)

Differential Revision: https://phabricator.services.mozilla.com/D23922

--HG--
extra : moz-landing-system : lando
2019-03-19 01:12:28 +00:00
Mark Goodwin
59e0c373c3 Bug 1429796 Cleanup storage in CertBlocklist to allow easy addition of new types of pair (e.g. whitelist entries) r=keeler
Differential Revision: https://phabricator.services.mozilla.com/D17668

--HG--
extra : moz-landing-system : lando
2019-03-19 17:48:04 +00:00
Rob Wu
0bf802b216 Bug 1536504 - Update outdated comment about _blank.html r=mixedpuppy
Differential Revision: https://phabricator.services.mozilla.com/D24058

--HG--
extra : moz-landing-system : lando
2019-03-19 16:51:50 +00:00
Honza Bambas
87dbb69b5b Bug 1535361 - Let stream transport service idle with 5 threads instead of only one to not create/kill threads in quick bursts; add option to thread pool to shorten the idle timeout progressively with number of idle thread to save memory, r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D23845

--HG--
extra : moz-landing-system : lando
2019-03-19 14:35:12 +00:00
Honza Bambas
44f895e1f6 Bug 1527712 - Move I/O in nsFileChannel::OpenContentStream to a background thread, r=kershaw,dragana
Differential Revision: https://phabricator.services.mozilla.com/D23352

--HG--
extra : moz-landing-system : lando
2019-03-19 15:25:47 +00:00
Coroiu Cristina
5f875389c3 Backed out changeset bdefd9c7fc99 (bug 1534343) for mochitest failures at netwerk/cookie/test/mochitest/test_xmlDocument.html on Android on a CLOSED TREE 2019-03-19 17:50:08 +02:00
Valentin Gosu
b7c2ade2f2 Bug 1532253 - Add threadsafe BlobURLProtocolHandler::CreateNewURI r=baku
Differential Revision: https://phabricator.services.mozilla.com/D22135

--HG--
extra : moz-landing-system : lando
2019-03-19 15:13:47 +00:00
Valentin Gosu
87e9bbff49 Bug 1532253 - Add NS_NewURIOnAnyThread r=baku
Differential Revision: https://phabricator.services.mozilla.com/D22137

--HG--
extra : moz-landing-system : lando
2019-03-19 15:11:31 +00:00
Andrea Marchesini
7f2e25b635 Bug 1534340 - Fix a nullptr check in CookieServiceChild::RequireThirdPartyCheck, r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D23873

--HG--
extra : moz-landing-system : lando
2019-03-19 13:23:28 +00:00