Whitelisted site allows all cookies requested by site to be saved when blocking all cookies
Categories
(Core :: Privacy: Anti-Tracking, defect)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr60 | --- | unaffected |
firefox65 | --- | wontfix |
firefox66 | + | fixed |
firefox67 | --- | fixed |
People
(Reporter: nevsjs, Assigned: baku)
References
()
Details
(Keywords: privacy, regression)
Attachments
(1 file)
47 bytes,
text/x-phabricator-request
|
lizzard
:
approval-mozilla-beta+
|
Details | Review |
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.119 Safari/537.36
Steps to reproduce:
Versions tested: 65.0.1, 67.0a1
- Create new profile
- In 'Privacy & Security', select custom option to block all cookies
- Set site 'https://microsoft.com' to 'Allow' in 'Manage Permissions...'
- Visit site 'https://microsoft.com/'
- Open privacy options again and open 'Manage Data...' to view sites with saved data
Actual results:
Cookies are saved for websites not in whitelist. eg. In the case above, cookies from live.com & bing.com (plus others) are saved when these have not been explicitly allowed.
Expected results:
Only the cookies from microsoft.com should've been saved. This was the behavior of the 'block all cookies' setting prior to version 65.0.
Updated•6 years ago
|
Comment 2•6 years ago
|
||
Hi David,
Is it possible to get a regression range on this bug to see which changeset regressed it please? Thanks!
Updated•6 years ago
|
![]() |
||
Comment 3•6 years ago
|
||
regression-window |
I can reproduce the issue on Firefox65 and Nightly67.0a1 windows10 as well.
Regression Window:
https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=591fefb0f99c9d50325fe8e4b151aab7e1ba8691&tochange=bec76d96700206177d42ca13e789519bc7eb313a
Regressed By:
bec76d967002 Ehsan Akhgari — Bug 1502240 - Ensure that Content Blocking allow list is applied to all cookie policies r=baku
![]() |
||
Updated•6 years ago
|
Comment 4•6 years ago
|
||
Thanks a lot for the regression range, Alice!
So we start here: https://searchfox.org/mozilla-central/rev/2a6f3dde00801374d3b2a704232de54a132af389/netwerk/cookie/nsCookieService.cpp#2087 and try to do an anti-tracking check. That results in us taking this early return path from this branch https://searchfox.org/mozilla-central/rev/2a6f3dde00801374d3b2a704232de54a132af389/toolkit/components/antitracking/AntiTrackingCommon.cpp#1336 because there is a cookie permission for the top-level domain (microsoft.com).
Then we get to this check: https://searchfox.org/mozilla-central/rev/2a6f3dde00801374d3b2a704232de54a132af389/netwerk/cookie/nsCookieService.cpp#4046. But here we have the wrong information. We accept the cookie but we should actually reject it because the result of the anti-tracking check should be a failure.
I think this shows a bug in the anti-tracking backend... It seems to me that we shouldn't be calling CheckCookiePermissionForPrincipal() on the top-level principal, since that means performing a cookie permission check on the origin of the top-level page rather than the channel performing the load. Andrea, what do you think?
Updated•6 years ago
|
Comment 6•6 years ago
|
||
Ehsan is this something you might work on? I can keep tracking it into the 66 release. Since it is a privacy issue we could potentially consider including a fix in late beta or even in a dot release.
Comment 7•6 years ago
|
||
I'm waiting on Andrea to respond to my question in comment 4, I'm not yet sure how to proceed here... Let me email him to remind him.
Assignee | ||
Comment 8•6 years ago
|
||
Assignee | ||
Comment 9•6 years ago
|
||
This regression was introduced by bug 1480780. I think it's resoneable to consider just the current cookie permission and not the top-level one.
Comment 10•6 years ago
|
||
Great, yes, this is exactly what I had in mind too. Thanks for confirming.
I actually posted your patch to try yesterday and it's green. :-)
https://treeherder.mozilla.org/#/jobs?repo=try&revision=9912c7022822c8efdf4f1c72e8c90a7396c681b2
Comment 11•6 years ago
|
||
I'm gonna land this on inbound to expedite things. Can you please ask for approval for beta?
Comment 12•6 years ago
|
||
Assignee | ||
Comment 13•6 years ago
|
||
Comment on attachment 9049088 [details]
Bug 1530132 - Consider the cookie permission for the current request, ignoring the top-level one, r?ehsan
Beta/Release Uplift Approval Request
- Feature/Bug causing the regression: Bug 1480780
- User impact if declined: More cookies are stored then what we should if the user has custom cookie permissions
- Is this code covered by automated tests?: No
- Has the fix been verified in Nightly?: Yes
- Needs manual test from QE?: Yes
- If yes, steps to reproduce: There is a STR on the bug descritpion
- List of other uplifts needed: None
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): The patch removes a cookie permission check. That was introduced wrongly and it's about Anti-Tracking only. Low risk.
- String changes made/needed: none
Comment 14•6 years ago
|
||
Comment 15•6 years ago
|
||
bugherder |
Comment 16•6 years ago
|
||
bugherder |
Updated•6 years ago
|
Comment 17•6 years ago
|
||
Comment on attachment 9049088 [details]
Bug 1530132 - Consider the cookie permission for the current request, ignoring the top-level one, r?ehsan
I'd like this in the RC, and it's the last minute,
so let's uplift now and verify after.
Comment 18•6 years ago
|
||
bugherder uplift |
Updated•6 years ago
|
Comment 19•6 years ago
|
||
I managed to reproduce the issue using an older version on Nightly (2019-02-23) on Windows 10 x63.
I verified the fix using latest Nightly on macOS 10.13 and Ubuntu 18.04 x64 and the bug is not reproducing.
HOwever on Windows 10 x64 I can still reproduce the issue using the latest Nightly 67.0a1.
Updated•6 years ago
|
Comment 20•6 years ago
|
||
This isn't a platform specific regression but rather an intermittent one. I'll file another bug on it.
Comment 21•6 years ago
|
||
BTW that's a regression from bug 1525245 not this one, so it doesn't affect beta.
Comment 22•6 years ago
|
||
Bug 1535380 is the said bug.
Comment 23•6 years ago
|
||
I will take out the qe-verify + flag from this bug and I will follow the Bug 1535380.
Description
•