Commit Graph

15 Commits

Author SHA1 Message Date
Francois Marier
309a23afc3 Bug 1482950 - Use the correct 3rdparty check in tracking annotations. r=dimi,Ehsan,mayhemer!,ehsan!
The mIsTrackingResource flag on nsIHttpChannel was split into two separate
flags depending on whether or not the resource is third-party. The correct
flag will be set by the channel classifier. Similarly, a new function was
introduced, GetIsThirdPartyTrackingResource(), for those consumers (like TP)
who only care about third-party trackers.

The existing function, GetIsTracking(), will continue to look at both
first-party and third-party trackers (the behavior since first party
tracking was added to annotations in bug 1476324).

The OverrideTrackingResource() function now allows nsHTMLDocument to
override both mIsFirstPartyTrackingResource and
mIsThirdPartyTrackingResource, but since this function is a little dangerous
and only has a single user, I added an assert to make future callers think
twice about using it to opt out of tracking annotations.

Currently, only the default storage restrictions need to look at first-party
trackers so every other consumer has been moved to
mIsThirdPartyTrackingResource or GetIsThirdPartyTrackingResource().

This effectively reverts the third-party checks added in bug 1476715 and
replaces them with the more complicated check that was added in bug 1108017.
It follows the approach that Ehsan initially suggested in bug 1476715. It
also reverts the changes in the expected values of the tracking annotation
test since these were, in hindsight, a warning about this regression.

Depends on D3722

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

--HG--
extra : moz-landing-system : lando
2018-08-20 23:53:45 +00:00
Kershaw Chang
62a41d6974 Bug 1413999 - Part3: IPC part, send trailers to child process r=dragana
The aim of this patch is to send trailers to child process via SendOnStopRequest.

--HG--
extra : rebase_source : 1a5e16e140ef20cfe2e723c3800d7feeebd9a5af
2018-01-03 02:05:00 +02:00
Honza Bambas
4eab23cce4 Bug 1411632 - Introduce onload and DOMContentLoaded telemetry for active tab and network optimization. r=valentin, r=francois 2017-12-02 18:13:43 -05:00
Thomas Nguyen
651c28ca53 Bug 1351147 - Use fullhash instead of prefix in OnClassifyComplete r=francois
In order to optionally report the full hash back to Google, we need to keep it
around in the callback. While a prefix is not the same as a full hash (multiple
full hashes can map to the same prefix), in this case, the callback will only be
called when the full hash matches.

MozReview-Commit-ID: F4WSLZpYrXB

--HG--
extra : rebase_source : da3b16b00729d0aa6ff1765a135b751fcf44c012
2017-08-04 18:20:13 +08:00
Shih-Chiang Chien
8ee3df7d5c Bug 1382103 - ensure thread-safe access to HttpBackgroundChannelParent::mBackgroundThread. r=mayhemer
mBackgroundThread is an nsCOMPtr write on PBackground thread but read on main thread. We need to use
Mutex to ensure memory sync between multiple threads.

MozReview-Commit-ID: 2CJ359ivhQh

--HG--
extra : rebase_source : 53c9087220a15d225d07272815cc1bdd6f75859e
2017-07-17 16:36:30 +08:00
Bill McCloskey
f115503a0b Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-26 14:19:58 -07:00
Carsten "Tomcat" Book
8a1350b5a6 Backed out changeset 4f6302a98ae4 (bug 1372405)
--HG--
extra : rebase_source : 41632f3158e88e692809731394a683d065a73dfb
2017-06-21 13:59:26 +02:00
Bill McCloskey
6b3e84ed5f Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-20 21:44:11 -07:00
Carsten "Tomcat" Book
ea1b86680c Backed out changeset 9846de3bd954 (bug 1372405)
--HG--
extra : rebase_source : 5d4a48e8ec394c329994689d938d2a6e9b2752b0
2017-06-20 08:27:02 +02:00
Bill McCloskey
4592152411 Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-19 22:25:47 -07:00
Shih-Chiang Chien
e4a31c0691 Bug 1369878 - background channel might be closed in the middle of init procedure during shutdown. r=mayhemer
MozReview-Commit-ID: L1Om8h4fBfU

--HG--
extra : rebase_source : de87b3ff00b5af6c863d607209d076145e324669
2017-06-03 14:29:37 +08:00
Shih-Chiang Chien
738f6da3cf Bug 1015466 - Part 5, move tracking protection and safe browsing state update IPC to PBackground. r=mayhemer
NotifyTrackingProtectionDisabled/NotifyTrackingResource/SetClassifierMatchedInfo updates tracking protection and safe browsing states from parent to child.
They should at least handled by child process before OnStopRequest. Move them to PHttpBackgroundChannel can ensure that.

MozReview-Commit-ID: 8T6k9z9FgrI

--HG--
extra : rebase_source : fd26e2b4309a31e0a9bb16c9236eb4a1875518dc
2017-05-26 11:04:03 +08:00
Shih-Chiang Chien
2be0682f1d Bug 1015466 - Part 4, implement OnStartRequestSent/OnStopRequest/OnTransportAndData/OnDiversion on background channel. r=mayhemer
OnStartRequestSent is used to ensure the execution order between OnStartRequest and all other messsages sent over PBackground.
IPC messages sent before OnStartRequestSent can be processed immediately while received by content process.
IPC messages sent after OnSartRequestSent need to be pending until OnStartRequestReceived is called.

MozReview-Commit-ID: 5Vbb8SBQmW8

--HG--
extra : rebase_source : 81ddce949d2a658e227e1e67d7d4313f7c66513f
2017-05-15 18:58:31 +08:00
Shih-Chiang Chien
e7a014adc4 Bug 1015466 - Part 3, PHttpBackgroundChannel lifecycle management. r=mayhemer
PHttpBackgroundChannel is created by content process because PBackground IPDL
can only be initiated from content process. The background channel deletion is
controlled by chrome process while PHttpChannel is going to be closed or canceled.

BackgroundChannelRegistrar is introduced for pairing HttpChannelParent and
HttpBackgroundChannelParent since they are created over different IPDL
asynchronously.

nsIParentRedirectingChannel.continueVerification is introduced to asynchronously
wait for background channel to be established on the new channel during the
Redirect2Verify phase.

MozReview-Commit-ID: 41l8ivan8iA

--HG--
extra : rebase_source : b8b6d7e7c037efaa9fc13df14191205c603e833a
2017-04-24 11:09:35 +08:00
Shih-Chiang Chien
c878e800ea Bug 1015466 - Part 1, skeleton of PHttpBackgroundChannel. r=mayhemer
PHttpBackgroundChannel is introduced to deliver OnStopRequest/OnTransportAndData/OnProgress/OnStatus on background thread.
FlushedForDiversion/DivertMessages is moved to PHttpBackgroundChannel to ensure no more channel event are delivered after these two messages on the background channel.
OnStartRequestSent is introduced to synchronize the execution order between OnStartRequest (main thread IPC) and all other messages on PHttpBackgroundChannel.

MozReview-Commit-ID: HfqvPML6EKw

--HG--
extra : rebase_source : 423709763e1abf1362347bc2d3141e2d33aed46a
2017-05-15 16:01:10 +08:00