mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-20 16:55:40 +00:00
Bug 1545273 - User-Interaction required for trackers only for some urls, set in privacy.restrict3rdpartystorage.userInteractionRequiredForHosts, r=Ehsan
This patch fixes a bug about when the privacy.restrict3rdpartystorage.userInteractionRequiredForHosts should be considered. Differential Revision: https://phabricator.services.mozilla.com/D28155 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
79f14c2299
commit
f8b91466be
@ -860,10 +860,9 @@ AntiTrackingCommon::AddFirstPartyStorageAccessGrantedFor(
|
||||
enum : uint32_t {
|
||||
blockReason = nsIWebProgressListener::STATE_COOKIES_BLOCKED_TRACKER
|
||||
};
|
||||
if ((aReason != eOpenerAfterUserInteraction ||
|
||||
nsContentUtils::IsURIInPrefList(trackingURI,
|
||||
"privacy.restrict3rdpartystorage."
|
||||
"userInteractionRequiredForHosts")) &&
|
||||
if (nsContentUtils::IsURIInPrefList(trackingURI,
|
||||
"privacy.restrict3rdpartystorage."
|
||||
"userInteractionRequiredForHosts") &&
|
||||
!HasUserInteraction(trackingPrincipal)) {
|
||||
LOG_SPEC(("Tracking principal (%s) hasn't been interacted with before, "
|
||||
"refusing to add a first-party storage permission to access it",
|
||||
|
@ -20,6 +20,7 @@ this.StoragePrincipalHelper = {
|
||||
["privacy.trackingprotection.pbmode.enabled", false],
|
||||
["privacy.trackingprotection.annotate_channels", true],
|
||||
["privacy.storagePrincipal.enabledForTrackers", true],
|
||||
["privacy.restrict3rdpartystorage.userInteractionRequiredForHosts", "tracking.example.com,tracking.example.org"],
|
||||
]});
|
||||
|
||||
if (extraPrefs && Array.isArray(extraPrefs) && extraPrefs.length) {
|
||||
|
Loading…
Reference in New Issue
Block a user