Closed
Bug 1287347
Opened 8 years ago
Closed 8 years ago
browser.downloads.download with blob:-URL: Access denied for URL blob:moz-extension
Categories
(WebExtensions :: Untriaged, defect)
WebExtensions
Untriaged
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 1271345
People
(Reporter: robwu, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
1.79 KB,
application/zip
|
Details |
1. Load the attached extension.
2. The extension opens a tab with instructions, follow those instructions and you will basically try different ways of running
chrome.downloads.download({url:'blob:moz-extension://...'});
where the URL is actually created using URL.createObjectURL(blob),
and one <a download> test.
Expected:
At each of the four attempt, a download dialog should appear.
Actual (Firefox 47.0.1 and Firefox Nightly (50)):
- The chrome.downloads.download invocation fails with:
Error: Type error for parameter options (Error processing url: Error: Access denied for URL blob:moz-extension://9089d5f0-2813-4a73-b5aa-733b8d777294/6e0c929e-3e68-46ab-870c-894bec0df00b) for downloads.download.
- The dialog appears as expected when I use <a download> (unless e10s is enabled - see bug 1287346).
The failure originates from
http://searchfox.org/mozilla-central/rev/bfcc10319e4e3ce78367fa9bba9316f7eb5248b6/toolkit/components/extensions/Schemas.jsm#140
|this.principal| references |this.params.principal|, but the latter is not set.
http://searchfox.org/mozilla-central/rev/bfcc10319e4e3ce78367fa9bba9316f7eb5248b6/toolkit/components/extensions/Schemas.jsm#137
... because Schema.inject has callers that don't set the principal on |wrapperFunc|.
http://searchfox.org/mozilla-central/rev/bfcc10319e4e3ce78367fa9bba9316f7eb5248b6/toolkit/components/extensions/Schemas.jsm#1618
Reporter | ||
Updated•8 years ago
|
Blocks: webextensions-chrome-gaps
Comment 1•8 years ago
|
||
This should work since bug 1271345, and we definitely have tests for it.
Reporter | ||
Comment 2•8 years ago
|
||
Just tested again on the latest build, it works. I guess that I only tested with 47 and an old Nightly 49, and not 50 itself. Sorry for the noise.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → DUPLICATE
Updated•6 years ago
|
Product: Toolkit → WebExtensions
You need to log in
before you can comment on or make changes to this bug.
Description
•