Closed Bug 1185174 Opened 9 years ago Closed 9 years ago

Add addonId to originAttributes of principal for extension URLs

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1161831
Tracking Status
firefox42 --- affected

People

(Reporter: billm, Unassigned)

References

(Blocks 1 open bug)

Details

I forgot that we need this for the extension stuff. Basically, when you have an extension URL (as in bug 1161831) we want the principal for it to include the addon ID from the URL. The XHR stuff isn't really useful without this, since the principal for most addon code comes from a web page rather than a sandbox. And those pages are loaded normally via LoadURI. Bobby, can you take care of this?
Flags: needinfo?(bobbyholley)
(In reply to Bill McCloskey (:billm) from comment #0) > I forgot that we need this for the extension stuff. Basically, when you have > an extension URL (as in bug 1161831) we want the principal for it to include > the addon ID from the URL. The XHR stuff isn't really useful without this, > since the principal for most addon code comes from a web page rather than a > sandbox. And those pages are loaded normally via LoadURI. > > Bobby, can you take care of this? Sure. Should I add an |extensionURLToAddonId| callback to nsIAddonPolicy (which your code would set), or do you want to hook it up some other way?
Flags: needinfo?(wmccloskey)
It's up to you. My thinking was that the new URL scheme would be moz-extension://<extensionID>/path. So we could just QI and then pull out the host component. But your way would be more generic.
Flags: needinfo?(wmccloskey)
I folded this into bug 1161831.
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: needinfo?(bobbyholley)
Resolution: --- → DUPLICATE
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.