Bug 1545033 - P1. Pass matched hash values to ProcessChannel. r=baku
authordlee <dlee@mozilla.com>
Fri, 26 Apr 2019 13:02:35 +0000
changeset 471792 979eea4eabff8099015c4df4d4df4e66b75f262d
parent 471791 9b16812e723e3dff41c118cd9bcd1f7535452f36
child 471793 77ca645609fac557eec6aef7ec388ece129d5554
push id35935
push usershindli@mozilla.com
push dateTue, 30 Apr 2019 03:46:04 +0000
treeherdermozilla-central@f3c2a7206699 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbaku
bugs1545033
milestone68.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1545033 - P1. Pass matched hash values to ProcessChannel. r=baku In origin telemetry, we want to record the matching statistic of each entry in our tracking tables. To identify which entry a given URL matches, it needs the hash value that matches the safe browsing database. This patch passes the hash value to ProcessChannel so Features can obtain the information and pass it. Note that it is possible that an URL may find multiple matches. If an URL matches hash A of list 1 and hash B of list 2, the parameter in ProcessChannel looks like: aList = [list 1, list2] aHashes = [hash A, hash B] Differential Revision: https://phabricator.services.mozilla.com/D28789
dom/ipc/URLClassifierParent.cpp
netwerk/url-classifier/AsyncUrlChannelClassifier.cpp
netwerk/url-classifier/UrlClassifierFeatureCryptominingAnnotation.cpp
netwerk/url-classifier/UrlClassifierFeatureCryptominingAnnotation.h
netwerk/url-classifier/UrlClassifierFeatureCryptominingProtection.cpp
netwerk/url-classifier/UrlClassifierFeatureCryptominingProtection.h
netwerk/url-classifier/UrlClassifierFeatureCustomTables.cpp
netwerk/url-classifier/UrlClassifierFeatureFingerprintingAnnotation.cpp
netwerk/url-classifier/UrlClassifierFeatureFingerprintingAnnotation.h
netwerk/url-classifier/UrlClassifierFeatureFingerprintingProtection.cpp
netwerk/url-classifier/UrlClassifierFeatureFingerprintingProtection.h
netwerk/url-classifier/UrlClassifierFeatureFlash.cpp
netwerk/url-classifier/UrlClassifierFeatureFlash.h
netwerk/url-classifier/UrlClassifierFeatureLoginReputation.cpp
netwerk/url-classifier/UrlClassifierFeatureLoginReputation.h
netwerk/url-classifier/UrlClassifierFeaturePhishingProtection.cpp
netwerk/url-classifier/UrlClassifierFeaturePhishingProtection.h
netwerk/url-classifier/UrlClassifierFeatureTrackingAnnotation.cpp
netwerk/url-classifier/UrlClassifierFeatureTrackingAnnotation.h
netwerk/url-classifier/UrlClassifierFeatureTrackingProtection.cpp
netwerk/url-classifier/UrlClassifierFeatureTrackingProtection.h
netwerk/url-classifier/nsIUrlClassifierFeature.idl
--- a/dom/ipc/URLClassifierParent.cpp
+++ b/dom/ipc/URLClassifierParent.cpp
@@ -90,16 +90,17 @@ class IPCFeature final : public nsIUrlCl
   NS_IMETHOD
   GetSkipHostList(nsACString& aList) override {
     aList = mIPCFeature.skipHostList();
     return NS_OK;
   }
 
   NS_IMETHOD
   ProcessChannel(nsIChannel* aChannel, const nsTArray<nsCString>& aList,
+                 const nsTArray<nsCString>& aHashes,
                  bool* aShouldContinue) override {
     NS_ENSURE_ARG_POINTER(aShouldContinue);
     *aShouldContinue = true;
 
     // Nothing to do here.
     return NS_OK;
   }
 
--- a/netwerk/url-classifier/AsyncUrlChannelClassifier.cpp
+++ b/netwerk/url-classifier/AsyncUrlChannelClassifier.cpp
@@ -160,16 +160,18 @@ class TableData {
   };
 
   TableData(URIData* aURIData, const nsACString& aTable);
 
   nsIURI* URI() const;
 
   const nsACString& Table() const;
 
+  const LookupResultArray& Result() const;
+
   State MatchState() const;
 
   bool IsEqual(URIData* aURIData, const nsACString& aTable) const;
 
   // Returns true if the table classifies the URI. This method must be called
   // on hte classifier worker thread.
   bool DoLookup(nsUrlClassifierDBServiceWorker* aWorkerClassifier);
 
@@ -199,16 +201,21 @@ nsIURI* TableData::URI() const {
   return mURIData->URI();
 }
 
 const nsACString& TableData::Table() const {
   MOZ_ASSERT(NS_IsMainThread());
   return mTable;
 }
 
+const LookupResultArray& TableData::Result() const {
+  MOZ_ASSERT(NS_IsMainThread());
+  return mResults;
+}
+
 TableData::State TableData::MatchState() const {
   MOZ_ASSERT(NS_IsMainThread());
   return mState;
 }
 
 bool TableData::IsEqual(URIData* aURIData, const nsACString& aTable) const {
   MOZ_ASSERT(NS_IsMainThread());
   return mURIData == aURIData && mTable == aTable;
@@ -420,29 +427,35 @@ bool FeatureData::MaybeCompleteClassific
       nsContentUtils::IsURIInList(mBlacklistTables[0]->URI(), skipList)) {
     UC_LOG(
         ("FeatureData::MaybeCompleteClassification[%p] - uri found in skiplist",
          this));
     return true;
   }
 
   nsTArray<nsCString> list;
+  nsTArray<nsCString> hashes;
   list.AppendElement(mHostInPrefTables[nsIUrlClassifierFeature::blacklist]);
 
   for (TableData* tableData : mBlacklistTables) {
     if (tableData->MatchState() == TableData::eMatch) {
       list.AppendElement(tableData->Table());
+
+      for (const auto& r : tableData->Result()) {
+        nsCString* hash = hashes.AppendElement();
+        r->hash.complete.ToString(*hash);
+      }
     }
   }
 
   UC_LOG(("FeatureData::MaybeCompleteClassification[%p] - process channel %p",
           this, aChannel));
 
   bool shouldContinue = false;
-  rv = mFeature->ProcessChannel(aChannel, list, &shouldContinue);
+  rv = mFeature->ProcessChannel(aChannel, list, hashes, &shouldContinue);
   Unused << NS_WARN_IF(NS_FAILED(rv));
 
   return shouldContinue;
 }
 
 // CallbackHolder
 // ----------------------------------------------------------------------------
 
--- a/netwerk/url-classifier/UrlClassifierFeatureCryptominingAnnotation.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureCryptominingAnnotation.cpp
@@ -119,17 +119,17 @@ UrlClassifierFeatureCryptominingAnnotati
   RefPtr<UrlClassifierFeatureCryptominingAnnotation> self =
       gFeatureCryptominingAnnotation;
   return self.forget();
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureCryptominingAnnotation::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   // This is not a blocking feature.
   *aShouldContinue = true;
 
   UC_LOG(
       ("UrlClassifierFeatureCryptominingAnnotation::ProcessChannel, annotating "
--- a/netwerk/url-classifier/UrlClassifierFeatureCryptominingAnnotation.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureCryptominingAnnotation.h
@@ -24,16 +24,17 @@ class UrlClassifierFeatureCryptominingAn
   static already_AddRefed<UrlClassifierFeatureCryptominingAnnotation>
   MaybeCreate(nsIChannel* aChannel);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD ProcessChannel(nsIChannel* aChannel,
                             const nsTArray<nsCString>& aList,
+                            const nsTArray<nsCString>& aHashes,
                             bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   UrlClassifierFeatureCryptominingAnnotation();
--- a/netwerk/url-classifier/UrlClassifierFeatureCryptominingProtection.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureCryptominingProtection.cpp
@@ -137,17 +137,17 @@ UrlClassifierFeatureCryptominingProtecti
   RefPtr<UrlClassifierFeatureCryptominingProtection> self =
       gFeatureCryptominingProtection;
   return self.forget();
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureCryptominingProtection::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   bool isAllowListed = UrlClassifierCommon::IsAllowListed(
       aChannel, AntiTrackingCommon::eCryptomining);
 
   // This is a blocking feature.
   *aShouldContinue = isAllowListed;
--- a/netwerk/url-classifier/UrlClassifierFeatureCryptominingProtection.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureCryptominingProtection.h
@@ -24,16 +24,17 @@ class UrlClassifierFeatureCryptominingPr
   static already_AddRefed<UrlClassifierFeatureCryptominingProtection>
   MaybeCreate(nsIChannel* aChannel);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD ProcessChannel(nsIChannel* aChannel,
                             const nsTArray<nsCString>& aList,
+                            const nsTArray<nsCString>& aHashes,
                             bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   UrlClassifierFeatureCryptominingProtection();
--- a/netwerk/url-classifier/UrlClassifierFeatureCustomTables.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureCustomTables.cpp
@@ -78,17 +78,17 @@ UrlClassifierFeatureCustomTables::HasHos
 NS_IMETHODIMP
 UrlClassifierFeatureCustomTables::GetSkipHostList(nsACString& aList) {
   return NS_OK;
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureCustomTables::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   // This is not a blocking feature.
   *aShouldContinue = true;
 
   return NS_OK;
 }
--- a/netwerk/url-classifier/UrlClassifierFeatureFingerprintingAnnotation.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureFingerprintingAnnotation.cpp
@@ -121,17 +121,17 @@ UrlClassifierFeatureFingerprintingAnnota
   RefPtr<UrlClassifierFeatureFingerprintingAnnotation> self =
       gFeatureFingerprintingAnnotation;
   return self.forget();
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureFingerprintingAnnotation::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   // This is not a blocking feature.
   *aShouldContinue = true;
 
   UC_LOG(
       ("UrlClassifierFeatureFingerprintingAnnotation::ProcessChannel, "
--- a/netwerk/url-classifier/UrlClassifierFeatureFingerprintingAnnotation.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureFingerprintingAnnotation.h
@@ -24,16 +24,17 @@ class UrlClassifierFeatureFingerprinting
   static already_AddRefed<UrlClassifierFeatureFingerprintingAnnotation>
   MaybeCreate(nsIChannel* aChannel);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD ProcessChannel(nsIChannel* aChannel,
                             const nsTArray<nsCString>& aList,
+                            const nsTArray<nsCString>& aHashes,
                             bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   UrlClassifierFeatureFingerprintingAnnotation();
--- a/netwerk/url-classifier/UrlClassifierFeatureFingerprintingProtection.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureFingerprintingProtection.cpp
@@ -141,17 +141,17 @@ UrlClassifierFeatureFingerprintingProtec
   RefPtr<UrlClassifierFeatureFingerprintingProtection> self =
       gFeatureFingerprintingProtection;
   return self.forget();
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureFingerprintingProtection::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   bool isAllowListed = UrlClassifierCommon::IsAllowListed(
       aChannel, AntiTrackingCommon::eFingerprinting);
 
   // This is a blocking feature.
   *aShouldContinue = isAllowListed;
--- a/netwerk/url-classifier/UrlClassifierFeatureFingerprintingProtection.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureFingerprintingProtection.h
@@ -24,16 +24,17 @@ class UrlClassifierFeatureFingerprinting
   static already_AddRefed<UrlClassifierFeatureFingerprintingProtection>
   MaybeCreate(nsIChannel* aChannel);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD ProcessChannel(nsIChannel* aChannel,
                             const nsTArray<nsCString>& aList,
+                            const nsTArray<nsCString>& aHashes,
                             bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   UrlClassifierFeatureFingerprintingProtection();
--- a/netwerk/url-classifier/UrlClassifierFeatureFlash.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureFlash.cpp
@@ -143,16 +143,17 @@ UrlClassifierFeatureFlash::GetIfNameMatc
   }
 
   return nullptr;
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureFlash::ProcessChannel(nsIChannel* aChannel,
                                           const nsTArray<nsCString>& aList,
+                                          const nsTArray<nsCString>& aHashes,
                                           bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   // This is not a blocking feature.
   *aShouldContinue = true;
 
   UC_LOG(("UrlClassifierFeatureFlash::ProcessChannel, annotating channel[%p]",
--- a/netwerk/url-classifier/UrlClassifierFeatureFlash.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureFlash.h
@@ -24,16 +24,17 @@ class UrlClassifierFeatureFlash final : 
       nsIChannel* aChannel,
       nsTArray<nsCOMPtr<nsIUrlClassifierFeature>>& aFeatures);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD
   ProcessChannel(nsIChannel* aChannel, const nsTArray<nsCString>& aList,
+                 const nsTArray<nsCString>& aHashes,
                  bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   explicit UrlClassifierFeatureFlash(const FlashFeature& aFlashFeature);
--- a/netwerk/url-classifier/UrlClassifierFeatureLoginReputation.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureLoginReputation.cpp
@@ -73,17 +73,17 @@ UrlClassifierFeatureLoginReputation::Get
 
   nsCOMPtr<nsIUrlClassifierFeature> self = MaybeGetOrCreate();
   return self.forget();
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureLoginReputation::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   MOZ_CRASH(
       "UrlClassifierFeatureLoginReputation::ProcessChannel should never be "
       "called");
   return NS_OK;
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureLoginReputation::GetURIByListType(
--- a/netwerk/url-classifier/UrlClassifierFeatureLoginReputation.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureLoginReputation.h
@@ -23,16 +23,17 @@ class UrlClassifierFeatureLoginReputatio
 
   static nsIUrlClassifierFeature* MaybeGetOrCreate();
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD ProcessChannel(nsIChannel* aChannel,
                             const nsTArray<nsCString>& aList,
+                            const nsTArray<nsCString>& aHashes,
                             bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   UrlClassifierFeatureLoginReputation();
--- a/netwerk/url-classifier/UrlClassifierFeaturePhishingProtection.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeaturePhishingProtection.cpp
@@ -106,17 +106,17 @@ UrlClassifierFeaturePhishingProtection::
   }
 
   return nullptr;
 }
 
 NS_IMETHODIMP
 UrlClassifierFeaturePhishingProtection::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   return NS_ERROR_NOT_IMPLEMENTED;
 }
 
 NS_IMETHODIMP
 UrlClassifierFeaturePhishingProtection::GetURIByListType(
     nsIChannel* aChannel, nsIUrlClassifierFeature::listType aListType,
     nsIURI** aURI) {
   return NS_ERROR_NOT_IMPLEMENTED;
--- a/netwerk/url-classifier/UrlClassifierFeaturePhishingProtection.h
+++ b/netwerk/url-classifier/UrlClassifierFeaturePhishingProtection.h
@@ -23,16 +23,17 @@ class UrlClassifierFeaturePhishingProtec
 
   static void MaybeCreate(nsTArray<RefPtr<nsIUrlClassifierFeature>>& aFeatures);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD
   ProcessChannel(nsIChannel* aChannel, const nsTArray<nsCString>& aList,
+                 const nsTArray<nsCString>& aHashes,
                  bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   explicit UrlClassifierFeaturePhishingProtection(
--- a/netwerk/url-classifier/UrlClassifierFeatureTrackingAnnotation.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureTrackingAnnotation.cpp
@@ -112,17 +112,17 @@ UrlClassifierFeatureTrackingAnnotation::
   RefPtr<UrlClassifierFeatureTrackingAnnotation> self =
       gFeatureTrackingAnnotation;
   return self.forget();
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureTrackingAnnotation::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   // This is not a blocking feature.
   *aShouldContinue = true;
 
   static std::vector<UrlClassifierCommon::ClassificationData>
       sClassificationData = {
--- a/netwerk/url-classifier/UrlClassifierFeatureTrackingAnnotation.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureTrackingAnnotation.h
@@ -24,16 +24,17 @@ class UrlClassifierFeatureTrackingAnnota
   static already_AddRefed<UrlClassifierFeatureTrackingAnnotation> MaybeCreate(
       nsIChannel* aChannel);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD ProcessChannel(nsIChannel* aChannel,
                             const nsTArray<nsCString>& aList,
+                            const nsTArray<nsCString>& aHashes,
                             bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   UrlClassifierFeatureTrackingAnnotation();
--- a/netwerk/url-classifier/UrlClassifierFeatureTrackingProtection.cpp
+++ b/netwerk/url-classifier/UrlClassifierFeatureTrackingProtection.cpp
@@ -133,17 +133,17 @@ UrlClassifierFeatureTrackingProtection::
   RefPtr<UrlClassifierFeatureTrackingProtection> self =
       gFeatureTrackingProtection;
   return self.forget();
 }
 
 NS_IMETHODIMP
 UrlClassifierFeatureTrackingProtection::ProcessChannel(
     nsIChannel* aChannel, const nsTArray<nsCString>& aList,
-    bool* aShouldContinue) {
+    const nsTArray<nsCString>& aHashes, bool* aShouldContinue) {
   NS_ENSURE_ARG_POINTER(aChannel);
   NS_ENSURE_ARG_POINTER(aShouldContinue);
 
   bool isAllowListed = UrlClassifierCommon::IsAllowListed(
       aChannel, AntiTrackingCommon::eTrackingProtection);
 
   // This is a blocking feature.
   *aShouldContinue = isAllowListed;
--- a/netwerk/url-classifier/UrlClassifierFeatureTrackingProtection.h
+++ b/netwerk/url-classifier/UrlClassifierFeatureTrackingProtection.h
@@ -24,16 +24,17 @@ class UrlClassifierFeatureTrackingProtec
   static already_AddRefed<UrlClassifierFeatureTrackingProtection> MaybeCreate(
       nsIChannel* aChannel);
 
   static already_AddRefed<nsIUrlClassifierFeature> GetIfNameMatches(
       const nsACString& aName);
 
   NS_IMETHOD ProcessChannel(nsIChannel* aChannel,
                             const nsTArray<nsCString>& aList,
+                            const nsTArray<nsCString>& aHashes,
                             bool* aShouldContinue) override;
 
   NS_IMETHOD GetURIByListType(nsIChannel* aChannel,
                               nsIUrlClassifierFeature::listType aListType,
                               nsIURI** aURI) override;
 
  private:
   UrlClassifierFeatureTrackingProtection();
--- a/netwerk/url-classifier/nsIUrlClassifierFeature.idl
+++ b/netwerk/url-classifier/nsIUrlClassifierFeature.idl
@@ -59,17 +59,18 @@ interface nsIUrlClassifierFeature : nsIS
    * 'something' on the channel. For instance, a tracking-annotation feature
    * would mark the channel as tracker, a tracking-protection feature would
    * cancel the channel.
    * Returns if we should process other feature results or not. For instance,
    * tracking-protection cancel the channel, and after that we should stop
    * processing other features.
    */
   [noscript] boolean processChannel(in nsIChannel aChannel,
-                                    in ConstStringArrayRef aList);
+                                    in ConstStringArrayRef aList,
+                                    in ConstStringArrayRef aHashes);
 
   /**
    * Features can work with different URLs from a channel (channel url, or
    * top-level, or something else). This method returns what we need to use for
    * the current list.
    */
   [noscript] nsIURI getURIByListType(in nsIChannel channel,
                                      in nsIUrlClassifierFeature_listType listType);