fix: AutistMask does not work in Firefox private windows (closes #646)
Firefox gives an extension page in a private window locks of its own, so a popup there could save between the background's read and its write and undo a network switch the background saved. `manifest/firefox.json` now sets `"incognito": "not_allowed"`, so such a page cannot read or write extension storage, and `tests/manifest.test.js` pins the key. README and the user guide say AutistMask does not work in Firefox private windows. Chrome needs no change: in its default incognito mode an extension page shares the background's lock. A Firefox user on "Never remember history" can no longer run AutistMask at all. Model: opus-5-5
This commit was merged in pull request #678.
This commit is contained in:
@@ -165,6 +165,15 @@ describe("declared icons", () => {
|
||||
});
|
||||
});
|
||||
|
||||
// Firefox gives a page in a private window locks of its own, so that page's
|
||||
// save could land between the background's read and its write (README,
|
||||
// "Stored state and its version").
|
||||
describe("private windows", () => {
|
||||
test("a page in a firefox private window cannot read or write extension storage", () => {
|
||||
expect(readManifest("firefox").incognito).toBe("not_allowed");
|
||||
});
|
||||
});
|
||||
|
||||
describe("shipped Content Security Policy", () => {
|
||||
// MV3 takes an object and applies extension_pages to the popup and the
|
||||
// background service worker, which is where libsodium runs.
|
||||
|
||||
Reference in New Issue
Block a user