AdguardBrowserExtension icon indicating copy to clipboard operation
AdguardBrowserExtension copied to clipboard

Referrer hidden even when rule unblocks it

Open BlazDT opened this issue 2 years ago • 8 comments

AdGuard Extension version

4.2.240

Browser version

Chrome 120.0.6099.110

OS version

Windows 11

What filters do you have enabled?

AdGuard Base filter

What Stealth Mode options do you have enabled?

Block trackers, Remove tracking parameters, Hide your search queries, Send websites signals not to track you, Self-destruction of third-party cookies, Hide Referrer from third parties, Remove X-Client-Data header, Disable WebRTC

Issue Details

https://venushd.click/live/stream-21.php

This website shows error: Referrer check failed, null referrer not allowed

This rule should disable every stealth option: @@||*.*$stealth,important

When I manually disable referrer option in stealth option it works. It also works when I block their script via this rule: ||weblivehdplay.ru/blast.js

Expected Behavior

Rule disables every stealth mode

Screenshots

image

Additional Information

You have to unblock the mentioned script file with rule (or disable base filter): @@||weblivehdplay.ru/blast.js

BlazDT avatar Dec 14 '23 19:12 BlazDT

@AdamWr did you experience this issue in the past already?

BlazDT avatar Dec 14 '23 19:12 BlazDT

No, I didn't and I cannot reproduce it with version 4.2.228 (in Opera and Firefox).

As far as I can see, 4.2.240 is a new version - https://github.com/AdguardTeam/AdguardBrowserExtension/releases/tag/v4.2.240-beta, marked as beta, though in Chrome and in Edge I have stable version installed and it's already updated to version 4.2.240. In changes there is Remove referrer from the document.referrer - https://github.com/AdguardTeam/AdguardBrowserExtension/issues/1844, I'm not sure, but I suppose that it may be related to this issue.

I think that if there is an exclusion with $stealth modifier then hideDocumentReferrer function should be disabled. https://github.com/AdguardTeam/tsurlfilter/blob/c0ea1cad19c2d45f99bb6ef0b58818fdfffe9ef8/packages/tswebextension/src/lib/common/stealth-helper.ts#L36-L50

AdamWr avatar Dec 14 '23 21:12 AdamWr

var _0x2c4597 = document.referrer; if (typeof _0x2c4597 === "undefined" || !_0x2c4597) { window.alert("Referrer check failed, null referrer not allowed"); throw new Error("Referrer check failed"); }

This part is causing the error on that site (i replace bgbody with window.alert). Though when I add a rule to show document.referrer in a window.alert it shows something.

ATM the site seems to be broken (jquery loading error even though file is loading). Still strange it worked with referrer option disabled. Just checked the site without any adblockers and error was displayed too. So probably site issue and beta issue.

BlazDT avatar Dec 14 '23 22:12 BlazDT

Same issue on https://jra.webcdn.stream.ne.jp/web/jra/onetag2020/eqPcPlayer2.html?target=202401060711 (probably geo-restricted). Even @@||stream.ne.jp^$stealth doesn't work, I have to turn the feature off to make the player work.

Yuki2718 avatar Jan 28 '24 13:01 Yuki2718

@Yuki2718, could you please elaborate on how to access the player? Direct link is not working for me

Screenshot:

image


stanislav-atr avatar Jan 29 '24 11:01 stanislav-atr

@stanislav-atr Whoops, sorry. Here the STR:

Screenshots

Access https://www.jra.go.jp/.

jra1

jra2

jra3

Yuki2718 avatar Jan 29 '24 12:01 Yuki2718

@Yuki2718, thanks for the str, what version is this? @@||stream.ne.jp^$stealth works fine on v4.3.10

stanislav-atr avatar Jan 29 '24 13:01 stanislav-atr

what version is this?

4.2.241. Confirmed it's fixed in 4.3.11

Yuki2718 avatar Jan 29 '24 13:01 Yuki2718