Closed Bug 1324115 Opened 8 years ago Closed 8 years ago

Add a way to get C++ origin attributes from nsIPrincipal

Categories

(Core :: Security, defect)

50 Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla53
Tracking Status
firefox53 --- fixed

People

(Reporter: smaug, Assigned: allstars.chh)

References

(Blocks 1 open bug)

Details

(Whiteboard: [OA])

Attachments

(2 files, 2 obsolete files)

For some unclear to me reason we need to always cast nsIPrincipal to BasePrincipal to get OA in C++ friendly way. Why can't we just have [noscript, notxpcom] getter in nsIPrincipal?
Assignee: nobody → allstars.chh
Status: NEW → ASSIGNED
Comment on attachment 8820105 [details] [diff] [review] Part 1: add a C++ helper in nsIPrincipal. I guess binaryOriginAttributesRef could be called also OriginAttributesRef, but doesn't matter since the binary name is anyhow the right one.
Attachment #8820105 - Flags: review?(bugs) → review+
Comment on attachment 8820106 [details] [diff] [review] Part 2: replace the callers to use C++ helper. Thanks.
Attachment #8820106 - Flags: review?(bugs) → review+
s/binaryOriginAttributesRef/OriginAttributesRef/
Attachment #8820105 - Attachment is obsolete: true
Attachment #8820216 - Flags: review+
added 'override' OriginAttributesRef() in BasePrincipal.h, otherwise we will have static analysis failure.
Attachment #8820216 - Attachment is obsolete: true
Attachment #8820573 - Flags: review+
Pushed by yhuang@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/b44e3a356480 Part 1: add a C++ helper in nsIPrincipal. r=smaug https://hg.mozilla.org/integration/mozilla-inbound/rev/26fedcf94afe Part 2: replace the callers to use C++ helper. r=smaug
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla53
Whiteboard: [OA]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: