Closed Bug 776140 Opened 12 years ago Closed 12 years ago

Add GetExtendedOrigin method to nsILoadContext

Categories

(Core :: General, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla17

People

(Reporter: jduell.mcbugs, Assigned: jduell.mcbugs)

References

Details

Attachments

(1 file, 2 obsolete files)

Attached patch v1 (obsolete) (deleted) — Splinter Review
Jonas suggests we make it easy for channels on the parent to get the ExtendedOrigin while keeping the code centralized. I saw 3 ways of doing it 1) Having nsNetUtil (or other necko code) call into nsScriptSecurityManager::GetExtendedOrigin. But necko doesn't currently know about nsScriptSecurityManager, and biesi is not happy about changing that. 2) moving the logic from nsScriptSecurityManager::GetExtendedOrigin to nsNetUtil.h. Mounir is opposed on the principle that this is security code, not necko logic. And there are some nsScriptSecurityManager constants that the method uses, so we'd still have to include nsScriptSecurityManager.h, or dupe the constant definitions. 3) Adding a GetExtendedOrigin method to nsILoadContext (it can't be an attribute, as it needs to take a Channel/URI for the origin). We've already got the infrastructure to send nsILoadContext fields across IPDL to the parent (to this will be another string across the wire). Biesi seems to prefer this. And that's what this patch does. (minus the IPDL parts--that patch would be a separate bug)
Attachment #644498 - Flags: superreview?(jonas)
Attachment #644498 - Flags: review?(justin.lebar+bug)
Attached patch v2: pass URI instead of channel (obsolete) (deleted) — Splinter Review
Turns out nsIWebSocket is not an nsIChannel, so this needs to take the URI directly.
Assignee: nobody → jduell.mcbugs
Attachment #644498 - Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #644498 - Flags: superreview?(jonas)
Attachment #644498 - Flags: review?(justin.lebar+bug)
Attachment #644535 - Flags: superreview?(jonas)
Attachment #644535 - Flags: review?(justin.lebar+bug)
Attached patch v3: forgot to run qref (deleted) — Splinter Review
Attachment #644535 - Attachment is obsolete: true
Attachment #644535 - Flags: superreview?(jonas)
Attachment #644535 - Flags: review?(justin.lebar+bug)
Attachment #644536 - Flags: superreview?(jonas)
Attachment #644536 - Flags: review?(justin.lebar+bug)
Blocks: 776176
Attachment #644536 - Flags: superreview?(jonas) → superreview+
Attachment #644536 - Flags: review?(justin.lebar+bug) → review+
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla17
Blocks: 780818
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: