Disabling Content Blocking for a site hides the tracking icons in Netmonitor
Categories
(DevTools :: Netmonitor, defect, P2)
Tracking
(Not tracked)
People
(Reporter: Harald, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
(deleted),
image/png
|
Details |
Comment 1•6 years ago
|
||
Comment 2•6 years ago
|
||
Comment 3•6 years ago
|
||
Comment 4•6 years ago
|
||
Reporter | ||
Comment 5•6 years ago
|
||
If this is intentional, it is probably not the right source for the network panel; which should always represent some insight into which resources might be affected.
Given that CB now has more levels of granularity, maybe Network panel should always check against the strictest/largest set. The objective of the feature is to make developers aware of potential failures.
Is there another function that we can use to match resources against the TP list?
Comment 6•6 years ago
|
||
Is there another function that we can use to match resources against the TP list?
Yes, you can do this:
let feature = classifierService.getFeatureByName("tracking-annotation");
if (feature) {
classifierService.asyncClassifyLocalWithFeatures(uri, [feature],
Ci.nsIUrlClassifierFeature.blacklist,
list => {
// list is an array. if empty, the URL is not in the tracking-protection list
});
}
Comment 7•6 years ago
|
||
Comment 6 I think is part of the answer but may not be the full answer... For example, it doesn't take into account whether the URL is a third-party tracking resource or not (e.g. doubleclick.net isn't considered a third-party tracking resource on youtube.com because both are owned by Google).
Andrea, is there a way to query the url classifier service taking the entity list into consideration?
Comment 8•6 years ago
|
||
I don't think so. We can add something, of course. Let's ask dimi.
Comment 9•6 years ago
|
||
(In reply to Andrea Marchesini [:baku] from comment #8)
I don't think so. We can add something, of course. Let's ask dimi.
If you are asking if URL Classifer has a simple API to do that, I would say no.
Please correct me if I am wrong.
I think what we really need, is not an URL Classifer API, is to separate this use case from tracking annotation. One of the requirement(or goal) for the listmanager revamp, is to support this.
Originally, the tracking annotation is used by all the new features and it is hard to maintain and evolve. With baku's work recently, we can easily add a new Feature(ex. FeatureTrackerInfo) in netwerk/url-classifer , with the same tables as tracking annotation and without checking ::ShouldEnableClassifier[1]. The ultimate goal, is every feature uses its own "url classifier feature".
So I guess what we need to do, is:
- Add a new UrlClassifierFeature[2], add a new preference to turn it on/off.
- most of the code should be the same as FeatureTrackingAnnotation[3]
- Write the classified information somewhere as we did in tracking annotation.
- Network panel read the information.
Does this make sense?
[1] https://searchfox.org/mozilla-central/rev/bee8cf15c901b9f4b0c074c9977da4bbebc506e3/netwerk/url-classifier/UrlClassifierCommon.cpp#90
[2] https://searchfox.org/mozilla-central/rev/bee8cf15c901b9f4b0c074c9977da4bbebc506e3/netwerk/url-classifier/UrlClassifierFeatureBase.h#17
[3] https://searchfox.org/mozilla-central/rev/bee8cf15c901b9f4b0c074c9977da4bbebc506e3/netwerk/url-classifier/UrlClassifierFeatureTrackingAnnotation.cpp
Comment 10•6 years ago
|
||
That sounds like a good plan I think. It will allow us to also make sure we're using the basic list not the strict list, which is another problem the network monitor had come across (not sure if there is a bug on file for it, I can't find one right now...)
Reporter | ||
Comment 11•6 years ago
|
||
Pardon if this is completely now how the new URL-Classifier and the features work. My assumption would be that a URL can be annotated by various features, as shown in about:url-classifier.
Could we provide the same annotations for a given URL to DevTools. With this list, the Network panel can then highlight the important ones (and provide the others for debugging purposes). This could also link to about:url-classifier for any advanced inspection/editing capabilities.
Comment 12•6 years ago
|
||
(In reply to :Harald Kirschner :digitarald from comment #11)
Pardon if this is completely now how the new URL-Classifier and the features work. My assumption would be that a URL can be annotated by various features, as shown in about:url-classifier.
Yes
Could we provide the same annotations for a given URL to DevTools. With this list, the Network panel can then highlight the important ones (and provide the others for debugging purposes). This could also link to about:url-classifier for any advanced inspection/editing capabilities.
I think this is also Yes.
Comment 13•6 years ago
|
||
Hello!
Is a regression window still required? Based on comment 7 I am a bit confused.
Thank you!
Comment 14•6 years ago
|
||
No, I don't think so. Thanks!
Comment 15•2 years ago
|
||
The severity isn't "major" here, changing to S3
But, it would still be great to properly mark all trackers in the Network panel and perhaps even more - show annotations for individual URLs in the panel.
Dimi it's been a while, do we have good APIs to read all anotations for given URL and show them in the DevTools Network panel now?
I am looking at API like isTracker
here: https://searchfox.org/mozilla-central/rev/31368c7795f44b7a15531d6c5e52dc97f82cf2d5/toolkit/components/antitracking/PurgeTrackerService.jsm#74
But according to the comment #7 this isn't enough and we need more, is that still correct?
Comment 16•2 years ago
|
||
(In reply to Jan Honza Odvarko [:Honza] (always need-info? me) from comment #15)
Dimi it's been a while, do we have good APIs to read all anotations for given URL and show them in the DevTools Network panel now?
I am looking at API like
isTracker
here: https://searchfox.org/mozilla-central/rev/31368c7795f44b7a15531d6c5e52dc97f82cf2d5/toolkit/components/antitracking/PurgeTrackerService.jsm#74But according to the comment #7 this isn't enough and we need more, is that still correct?
I think we can use these APIs now. If i remember correctly, we still set classification flag even if you turn off ETP for a site.
Comment 17•2 years ago
|
||
(In reply to Dimi Lee [:dimi][:dlee] from comment #16)
(In reply to Jan Honza Odvarko [:Honza] (always need-info? me) from comment #15)
Dimi it's been a while, do we have good APIs to read all anotations for given URL and show them in the DevTools Network panel now?
I am looking at API like
isTracker
here: https://searchfox.org/mozilla-central/rev/31368c7795f44b7a15531d6c5e52dc97f82cf2d5/toolkit/components/antitracking/PurgeTrackerService.jsm#74But according to the comment #7 this isn't enough and we need more, is that still correct?
I think we can use these APIs now. If i remember correctly, we still set classification flag even if you turn off ETP for a site.
Thanks Dimi. I'll try this out and see.
Updated•2 years ago
|
Comment 18•2 years ago
|
||
Hi Hubert,
I've looked at all comments and try to figure out how necko team can help, but it's not clear to me what kind of support you need from necko. Could you explain more?
Thanks.
Comment 19•2 years ago
|
||
(In reply to Hubert Boma Manilla (:bomsy) from comment #17)
I think we can use these APIs now. If i remember correctly, we still set classification flag even if you turn off ETP for a site.
Thanks Dimi. I'll try this out and see.
Not sure if this bug is about more than what devtools already does here.
If anyone has more info let me know.
Comment 20•2 years ago
|
||
Hi Kershaw and Valentin,
Thanks for taking a look.
So the original issue seems to be fixed as there are already tracking icons for most tracker resources in the netmonitor for cnn.com.
But the outstanding issue is that mentioned in the example in Comment 7 where doubleclick.net isn't considered a third-party tracking resource on youtube.com, as double click is owned by google.
I think might be best to close this bug as done and open another that focuses on the specific issue (i'll do that).
Comment 21•2 years ago
|
||
Closing this as the related main issue has been fixed. Opened Bug 1795649 for the outstanding issue.
Description
•