gecko-dev/netwerk/base/nsIParentChannel.idl

64 строки
1.8 KiB
Plaintext
Исходник Обычный вид История

2012-05-21 15:12:37 +04:00
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsIStreamListener.idl"
interface nsITabParent;
%{C++
namespace mozilla {
namespace net {
class HttpChannelParentListener;
}
}
%}
[ptr] native HttpChannelParentListener(mozilla::net::HttpChannelParentListener);
/**
* Implemented by chrome side of IPC protocols.
*/
[scriptable, uuid(e0fc4801-6030-4653-a59f-1fb282bd1a04)]
interface nsIParentChannel : nsIStreamListener
{
/**
* Called to set the HttpChannelParentListener object (optional).
*/
[noscript] void setParentListener(in HttpChannelParentListener listener);
/**
* Called to notify the HttpChannelChild that tracking protection was
* disabled for this load.
*/
[noscript] void notifyTrackingProtectionDisabled();
/**
* Called to set matched information when URL matches SafeBrowsing list.
* @param aList
* Name of the list that matched
* @param aProvider
* Name of provider that matched
* @param aFullHash
* String represents full hash that matched
*/
[noscript] void setClassifierMatchedInfo(in ACString aList,
in ACString aProvider,
in ACString aFullHash);
/**
* Called to notify the HttpChannelChild that the resource being loaded
* is on the tracking protection list.
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-21 02:53:45 +03:00
* @param aIsThirdParty
* Whether or not the resourced is considered first-party
* with the URI of the window.
*/
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-21 02:53:45 +03:00
[noscript] void notifyTrackingResource(in bool aIsThirdParty);
/**
* Called to invoke deletion of the IPC protocol.
*/
void delete();
};