Incorrect warning about request to access cookie or storage
Categories
(Core :: Networking: Cookies, defect, P2)
Tracking
()
People
(Reporter: kusmabite, Assigned: ehsan.akhgari)
References
Details
(Keywords: regression, Whiteboard: [necko-triaged])
Attachments
(3 files, 2 obsolete files)
User Agent: Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:66.0) Gecko/20100101 Firefox/66.0
Steps to reproduce:
Open up https://gitlab.freedesktop.org/ in Firefox, and open up the javacript console.
Actual results:
The following warning was output:
"Request to access cookie or storage on “https://storage.googleapis.com/fdo-gitlab-uploads/appearance/favicon/1/fdo-favicon.ico?GoogleAccessId=GOOGOEXJKVLVDILPMJ5V2WSY&Signature=o4KMVULFqD27NzCV3h7SxRSyZfY%3D&Expires=1553863896” was blocked because we are blocking all third-party storage access requests and content blocking is enabled."
Expected results:
No warning should have been output, as the request does not request storage.
If I capture the output with the network tab in the debug tools, I can see that these are the headers:
---8<---
HTTP/2.0 200 OK
x-guploader-uploadid: AEnB2UqG3JMKZNA2-QYjtkjLbBbhUt2GCZw61CuEN4ZjkXFrOCqhbIaJnABHkQQzik_gRaq2a1QO6_GddB0pLO9n90ISWL618eaY-EGvKDCgB7ewjdEjTsI
expires: Fri, 29 Mar 2019 12:44:03 GMT
date: Fri, 29 Mar 2019 12:44:03 GMT
cache-control: private, max-age=0
last-modified: Wed, 08 Aug 2018 15:23:27 GMT
etag: "ab3d69c106187c3a7df54a3a17cf9c29"
x-goog-generation: 1533741807914952
x-goog-metageneration: 1
x-goog-stored-content-encoding: identity
x-goog-stored-content-length: 1406
content-type: image/vnd.microsoft.icon
x-goog-hash: crc32c=BFcn5w==
x-goog-hash: md5=qz1pwQYYfDp99Uo6F8+cKQ==
x-goog-storage-class: REGIONAL
accept-ranges: bytes
content-length: 1406
server: UploadServer
alt-svc: quic=":443"; ma=2592000; v="46,44,43,39"
X-Firefox-Spdy: h2
---8<---
Nothing in here looks like cookies or storage to me. Perhaps it's a false-positive due to the "x-goog-storage-class: REGIONAL" or something along those lines?
Comment 1•6 years ago
|
||
I cannot reproduce your issue.
- Does this issue occur on Fedora? Which version of Fedora?
- Is it the Release version of Firefox that reproduces the issue? Please post the exact version.
- Does this issue occur on the latest Nightly browser?
Get it from here: http://archive.mozilla.org/pub/firefox/nightly/2019/03/2019-03-30-09-33-31-mozilla-central/Firefox%20Installer.en-US.exe - Which one is the JavaScript console?
Thank you for your contribution!
Reporter | ||
Comment 2•6 years ago
|
||
- Yes, it happens on Fedora 29.
- It's the current distro-package of Fedora 29. The About dialog reports:
"Firefox Quantum
66.0.1 (64-bit)
Mozilla Firefox for Fedora
fedora - 1.0". - That download-link is for Windows, I'm using Linux. If I download the Linux nightly from https://www.mozilla.org/en-US/firefox/channel/desktop/, the problem still occurs.
- Control + Shift + K, or "Web Developer" -> "Web Console" under the hamburger menu. You may have to reload the page with this open to see the warning.
But: I think I missed one step for reproduction: You also need to enable blocking of all 3rd party cookies. You can do so by going to "Settings" -> "Privacy and Security" -> "Content Blocking", and selecting the "Custom" radio-button. Then you check "Cookies" and choose "All third-party cookies (may cause websites to break)". With the "Standard" setting, no warning is emitted.
Reporter | ||
Comment 3•6 years ago
|
||
That should have been "Options" -> "Privacy and Security" -> "Content Blocking", not "Settings" [...].
Comment 4•6 years ago
|
||
I confirm the reproduction of the behavior described by the reporter, however, I do not know whether it is valid or not.
I will set this bug's component as (Core) DOM. Hopefully, a developer will pick it up and decide how to address it.
I have to mention that this issue is not Fedora specific as it occurs on all platforms and versions.
Thank you for your contribution!
Updated•6 years ago
|
Updated•6 years ago
|
Updated•6 years ago
|
Comment 5•6 years ago
|
||
Can you still reproduce the issue? I cannot in the latest nightly.
Reporter | ||
Comment 6•6 years ago
|
||
Still fails for me on Firefox 68.0.
Comment 7•5 years ago
|
||
I have tested main versions on Windows 10 and found that it does not reproduce in Nightly v70.0a1, but it does reproduce in Beta v69.0b6.
Furthermore, I have attempted to find the fix using mozregression and these are my results:
2019-07-23T14:03:46: INFO : Narrowed inbound regression window from [8cc6bacf, 80e58bbe] (3 builds) to [8cc6bacf, a39c6716] (2 builds) (~1 steps left)
2019-07-23T14:03:46: DEBUG : Starting merge handling...
2019-07-23T14:03:46: DEBUG : Using url: https://hg.mozilla.org/integration/autoland/json-pushes?changeset=a39c67169747c1dbd184c14c11aa6bdd3d61db93&full=1
2019-07-23T14:03:47: DEBUG : Found commit message:
Bug 1544864 - Enable Show Content Messages in browser console. r=bgrins.
This patch removes the preference we were using to
display the checkbox in the Browser Console; it's now
always displayed there.
We flip the pref to show content messages ini tests that need them.
Differential Revision: https://phabricator.services.mozilla.com/D34996
2019-07-23T14:03:47: DEBUG : Did not find a branch, checking all integration branches
2019-07-23T14:03:47: INFO : The bisection is done.
2019-07-23T14:03:47: INFO : Stopped
Assignee | ||
Comment 8•5 years ago
|
||
(In reply to Erik Faye-Lund from comment #0)
Open up https://gitlab.freedesktop.org/ in Firefox, and open up the javacript console.
Actual results:
The following warning was output:
"Request to access cookie or storage on “https://storage.googleapis.com/fdo-gitlab-uploads/appearance/favicon/1/fdo-favicon.ico?GoogleAccessId=GOOGOEXJKVLVDILPMJ5V2WSY&Signature=o4KMVULFqD27NzCV3h7SxRSyZfY%3D&Expires=1553863896” was blocked because we are blocking all third-party storage access requests and content blocking is enabled."
Note here in the log message we're saying because we are blocking all third-party storage access requests. This means that in Preferences, Privacy & Security, Content Blocking, Custom, Cookies you have selected "All third-party cookies (may cause websites to break)".
This tells Firefox to strip all cookies and storage access from any third-party context, including the request from the URL above.
Expected results:
No warning should have been output, as the request does not request storage.
In fact all HTTP requests internally "request" storage, in the sense that they look up the cookies database to see if a matching cookie should be attached to them. The problem is that when that request fails, we notify that we "rejected" the request (which will eventually result in this console warning) even if there was no cookie to begin with.
This should be easy to fix...
Updated•5 years ago
|
Comment 9•5 years ago
|
||
Bugbug thinks this bug is a regression, but please revert this change in case of error.
Assignee | ||
Comment 10•5 years ago
|
||
Assignee | ||
Comment 11•5 years ago
|
||
This pref will be used in tests only.
Assignee | ||
Comment 12•5 years ago
|
||
Comment 13•5 years ago
|
||
Comment 14•5 years ago
•
|
||
Backed out 3 changesets (Bug 1540117) for failures in browser_storageAccessPrivateWindow.js
Push with failures: https://treeherder.mozilla.org/#/jobs?repo=autoland&resultStatus=testfailed%2Cbusted%2Cexception&revision=1dcf5956a3f13c0a83a5585ff732c4be60894436&selectedJob=263699182
Failure log: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=263699182&repo=autoland&lineNumber=5154
https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=263704728&repo=autoland&lineNumber=6165
Backout: https://hg.mozilla.org/integration/autoland/rev/8c771ad2ef1ea634e2c15ea6b9e7ff84fb365d7e
Assignee | ||
Updated•5 years ago
|
Comment 15•5 years ago
|
||
Updated•5 years ago
|
Assignee | ||
Comment 16•5 years ago
|
||
Comment 17•5 years ago
|
||
Assignee | ||
Comment 18•5 years ago
|
||
Comment 19•5 years ago
|
||
Comment 20•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/11837979956b
https://hg.mozilla.org/mozilla-central/rev/fcc060bc9677
https://hg.mozilla.org/mozilla-central/rev/1f918cd124a8
https://hg.mozilla.org/mozilla-central/rev/e30c654504e6
https://hg.mozilla.org/mozilla-central/rev/c72fb6d63304
Comment 21•5 years ago
|
||
Since the status are different for nightly and release, what's the status for beta?
For more information, please visit auto_nag documentation.
Assignee | ||
Updated•5 years ago
|
Updated•5 years ago
|
Updated•5 years ago
|
Updated•5 years ago
|
Description
•