AdguardTeam / CoreLibs

Core Adguard libraries
https://adguard.com/
Apache License 2.0
39 stars 7 forks source link

Source of request is not detected on sonyliv.com #1576

Closed AdamWr closed 2 years ago

AdamWr commented 2 years ago

Steps to reproduce:

  1. Add these rules to user rules:
    ||sonyliv.com/App.*.chunk.js$replace=/\,\{url:"https:\/\/imasdk\.googleapis\.com\/js\/sdkloader\/ima3\.js"\,type:"script"\}//,badfilter
    @@||imasdk.googleapis.com/js/sdkloader/ima3.js$domain=sonyliv.com
  2. Go to - https://www.sonyliv.com/shows/tryst-with-destiny-1700000814/fair-and-fine-1000142673?watch=true

Source of imasdk.googleapis.com/js/sdkloader/ima3.js is not detected, so request is blocked, but should be unblocked by this rule:

@@||imasdk.googleapis.com/js/sdkloader/ima3.js$domain=sonyliv.com
Screenshot ![image](https://user-images.githubusercontent.com/29142494/147770029-fb857b61-3145-482e-9886-3f26c4b45829.png)

AdGuard for Windows Version 7.9 nightly 2 (build 3787, CL 1.9.0)

ameshkov commented 2 years ago

Quick note: European VPN is needed to reproduce this issue.

ameshkov commented 2 years ago

@AdamWr could you please try this rule? $$meta[name="referrer"][content="never"]

AdamWr commented 2 years ago

It works fine with this rule :)

ameshkov commented 2 years ago

Well, that's the solution then. The website removes the referrer forcibly and we shouldn't let it do that.

For now I think we could keep this a website-specific rule, but if there are many cases, we'll need to make is a wider rule or even do that automatically.