-
Notifications
You must be signed in to change notification settings - Fork 345
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Website CSP can block AdGuard scripts in Firefox #1733
Comments
Hello! It looks like there should be no CSP check for extension resources. |
I constantly see a red Content Security Policy warning in Firefox Console during the normal navigation on Github.com too. I'm using Firefox 84.0.2 x64. With the same browser I can't make more than 5 edits to a comment because my changes are not correctly retained between an edit and another. Currently I'm waiting official Github confirmation about it. I've already tried without success:
|
I don't think this is related. CSP errors means exactly the opposite: Adguard scripts don't work at this website. So there is literally nothing to interfere with. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
А я то думал, - почему scriptlet'ы на некоторых сайтах не работают, а тут вон оно что...
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Workaround this bug in FireFox is put Странно, но GreaseMonkey как-то обходит эту проблему, а AdGuard и TamperMonkey - нет. Почему и, самое главное, Как? |
Довольно жестоко глобально отключать CSP, безопасность страдает.
Точно? Тогда нужно покопаться в его исходнике просто. |
Точно! Использую версию 4.11 на FireFox v78.13 ESR, только он в iframe'ах скрипты не запускает. А TamperMonkey работает в iframe'ах, но не работает при строгом CSP. А в коде я настолько сильно не разбираюсь - надо более опытного кодера. |
AdguardTeam/AdguardBrowserExtension#1733 Squashed commit of the following: commit c88fe90 Author: Slava Leleka <[email protected]> Date: Mon Apr 15 15:01:32 2024 +0400 fix comment commit b6947c5 Merge: f156e6a cb4a3a6 Author: Slava Leleka <[email protected]> Date: Mon Apr 15 15:00:03 2024 +0400 merge master into the branch, resolve conflicts commit f156e6a Author: Slava Leleka <[email protected]> Date: Mon Apr 15 14:58:32 2024 +0400 fix script rules applying in ff
Squashed commit of the following: commit c7014e6 Merge: 9c5c0b8 ceb809c Author: Slava Leleka <[email protected]> Date: Thu Apr 18 14:59:30 2024 +0400 merge master into the branch, resolve conflicts commit 9c5c0b8 Author: Slava Leleka <[email protected]> Date: Mon Apr 15 21:05:45 2024 +0400 update tswebextension to v1.0.24
…n readme Merge in EXTENSIONS/browser-extension from feature/template_update to master Squashed commit of the following: commit 9ee7a1e Author: Maria Giganova <[email protected]> Date: Wed May 15 18:52:05 2024 +0300 📜 Docs: fix typos commit 7e86dde Author: Maria Giganova <[email protected]> Date: Wed May 15 17:55:04 2024 +0300 📜 Docs: fix link commit 98122a4 Author: Maria Giganova <[email protected]> Date: Wed May 15 14:54:12 2024 +0300 📜 Docs: update templates, add badge for mozilla in readme
Some websites using strict CSP rules can block AdGuard scripts injection.
E.g. here at
github.com
AdGuard can't make it's own scripts to work.So all JS-related filters doesn't work with the such websites.
I've tried to override this behavior with a rule like this:
github.com^$csp=script-src 'unsafe-inline' 'unsafe-eval' *
But it doesn't work for some reason.
This is Firefox-only issue. Seems like Chrome allows extensions to inject scripts regardless of CSP.
For a practical example, try to use a such rule:
github.com#%#alert('Hi')
It works in Chrome, but not in Firefox.
The text was updated successfully, but these errors were encountered: