I am developing some privacy protect add-ons on Firefox. But recently I noticed that my add-on met the content blocking, which impact the normal working of it. My add-on could create a new blank page on Firefox, then it will try to ajax some information to get the setting of customers in some websites , and show the information in the blank page. But now when I open the add-on and do the function , I found there was a shield on new page called “content blocking”, which lead to the issue on my add-on.
Could you please help me to avoid it or give me some method about it? Thank you very much.
When you check the drop-down panel, does Firefox show that it is blocking trackers? If so, click that line (see red box in the following screenshot) to find out what the blocked sites are. I suggest not using scripts or other resources from blocked sites.
Thank you for your answer. I still have some problems after I check the list and found the website.
1.I try to ajax some website to get user’s login information from the new page, does this action lead to the content blocking?
2.May I get some suggest about how to avoid the content blocking because the add-on must do some ajax to get some information.
I don’t understand the context, so these questions are difficult to understand. What is the exact error message you’re getting in the console? Messages from different contexts may be reported in different consoles:
IF you are looking to make your extension exempt from content blocking for its requests you will have to request the host permission for the specific host you want to avoid it for. See
Thank you for your answer. I have wrote the code as follow in “manifest.json”:
“permissions”: [
“http:///”,
“https:///”,
“tabs”,
“nativeMessaging”,
“webRequestBlocking”,
“webRequest”,
“webNavigation”,
“storage”
]
but the content blocking still happened in Firefox, should I add some other code in this file? Thank you.
I quote the linked documentation (emphasis mine):
bypass tracking protection if the host is a full domain without wildcards
Thank you very much. After adding the full domain url my add-on could work normally.