Surface storage access API exceptions in the content blocking log
Categories
(Core :: Privacy: Anti-Tracking, enhancement, P2)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox68 | --- | fixed |
People
(Reporter: englehardt, Assigned: xeonchen)
References
(Blocks 1 open bug)
Details
Attachments
(2 files)
Document::mContentBlockingLog does not currently include any information about why a blocking exception is granted. There are currently three causes https://searchfox.org/mozilla-central/rev/2c912888e3b7ae4baf161d98d7a01434f31830aa/toolkit/components/antitracking/AntiTrackingCommon.h#70.
Surfacing this information might be helpful when debugging, and could also be collected in Origin Telemetry.
| Assignee | ||
Comment 1•7 years ago
|
||
Hi Baku, do you think the patch is on the right direction?
Comment 2•7 years ago
|
||
Updated•7 years ago
|
Comment 3•7 years ago
|
||
Gary, I think this could be done in a much cleaner way.
Here I assume aReason is StorageAccessGrantedReason, right? You actually don't need to pass it down to all of the ContentBlockingLog recording methods like you are doing now. StorageAccessGrantedReason is only meaningful when storage access is being granted (note the name of the type!). That means you only need to pass it down from here https://searchfox.org/mozilla-central/rev/6db0a6a56653355fcbb25c4fa79c6e7ffc6f88e9/toolkit/components/antitracking/AntiTrackingCommon.cpp#871 and for STATE_COOKIES_BLOCKED_TRACKER. That means you only need to modify Document::SetHasTrackingCookiesBlocked() and none of the other similar methods on Document. Inside that method you should probably assert that Nothing() is always passed when aBlocked != false.
I'd like to review your final patch here, if possible. Thanks!
| Assignee | ||
Comment 4•7 years ago
|
||
Comment 6•7 years ago
|
||
| bugherder | ||
Description
•