Closed
Bug 1189086
Opened 9 years ago
Closed 8 years ago
Eliminate nsIPrincipal::jarPrefix
Categories
(Core :: DOM: Security, defect, P3)
Core
DOM: Security
Tracking
()
RESOLVED
FIXED
mozilla52
Tracking | Status | |
---|---|---|
firefox52 | --- | fixed |
People
(Reporter: englehardt, Assigned: huseby)
References
Details
(Whiteboard: [OA][domsecurity-backlog1])
Attachments
(1 file, 3 obsolete files)
(deleted),
patch
|
huseby
:
review+
|
Details | Diff | Splinter Review |
jarPrefix is currently a concatenation of appId and inMozBrowser as cookieJar was removed in Bug 1182347. Bug 1179985 seeks to replace this with origin/originSuffix. Once the remaining consumers (Bug 1165219, Bug 1165277, and Bug 1165217) are migrated to originSuffix, jarPrefix can be removed.
Reporter | ||
Updated•9 years ago
|
Reporter | ||
Updated•9 years ago
|
Assignee: nobody → senglehardt
Status: NEW → ASSIGNED
Reporter | ||
Comment 1•9 years ago
|
||
Sample patch. Will do additional testing once dependent bugs are fixed.
Reporter | ||
Comment 2•9 years ago
|
||
Yoshi, would you mind to let me know if I missed any dependent bugs?
Flags: needinfo?(allstars.chh)
Yeah, I think the bugs you listed are enough.
Flags: needinfo?(allstars.chh)
Comment 4•9 years ago
|
||
Bug 1165217 is just about fixing nsIUsageCallback. Quota manager uses jarPrefix + originNoSuffix to find storage directories (for example: <profile>/storage/persistent/1007+f+app+++system.gaiamobile.org). So we need to fix it/convert it somehow before jarPrefix can be removed.
Updated•8 years ago
|
Component: Security: CAPS → DOM: Security
Priority: -- → P3
Whiteboard: [OA]
Updated•8 years ago
|
Whiteboard: [OA] → [OA][domsecurity-backlog1]
Updated•8 years ago
|
Assignee: bugzilla → nobody
Status: ASSIGNED → NEW
Assignee | ||
Updated•8 years ago
|
Assignee: nobody → huseby
Assignee | ||
Comment 6•8 years ago
|
||
I rebased and built, try: https://treeherder.mozilla.org/#/jobs?repo=try&revision=3a2927ae61782be1ec1bae55dd56aa841271051c
Assignee | ||
Comment 7•8 years ago
|
||
the WIP patch covered everything except the ActorParent.cpp GetJarPrefix function.
Assignee | ||
Comment 8•8 years ago
|
||
rebased, fixed build issues, try: https://treeherder.mozilla.org/#/jobs?repo=try&revision=f883ae8a26b966dd75d3367a21f902d3cbc204db
Assignee | ||
Comment 9•8 years ago
|
||
this is the updated WIP rebased and fixed. it completely removes the GetJarPrefix code. The only thing that is of concern to me are the changes I made CreateDirectoryMetadata to remove the calls to GetJarPrefix. I assume that the suffix created from the origin attributes should be sufficient since it includes the origin attributes that were being fed into GetJarPrefix. I'm just not sure what changing the metadata string will do to stored state.
Attachment #8640760 -
Attachment is obsolete: true
Comment 10•8 years ago
|
||
(In reply to Dave Huseby [:huseby] from comment #9)
> Created attachment 8799544 [details] [diff] [review]
> WIP patch
>
> this is the updated WIP rebased and fixed. it completely removes the
> GetJarPrefix code. The only thing that is of concern to me are the changes
> I made CreateDirectoryMetadata to remove the calls to GetJarPrefix. I
> assume that the suffix created from the origin attributes should be
> sufficient since it includes the origin attributes that were being fed into
> GetJarPrefix. I'm just not sure what changing the metadata string will do
> to stored state.
Please don't remove it from ActorsParent.cpp
The code there handles reading/upgrading of .metadata (version 1) files in user profile which were created in an older FF.
I forked the GetJarPrefix() method because I knew it will be removed at some point.
Assignee | ||
Comment 11•8 years ago
|
||
Jan,
Do you have a plan for removing it from ActorsParent.cpp?
Flags: needinfo?(jvarga)
Assignee | ||
Comment 12•8 years ago
|
||
updated patch to revert the removal of the function from ActorsParent.cpp. Try:
https://treeherder.mozilla.org/#/jobs?repo=try&revision=a5fa6014db2b145456d4a30c32c4c19653d33d26
Assignee | ||
Comment 13•8 years ago
|
||
updated the patch
Attachment #8799544 -
Attachment is obsolete: true
Flags: needinfo?(jvarga)
Attachment #8799578 -
Flags: review?(jvarga)
Comment 14•8 years ago
|
||
(In reply to Dave Huseby [:huseby] from comment #11)
> Jan,
>
> Do you have a plan for removing it from ActorsParent.cpp?
Why would I want to remove it ?
Those .metadata files were created in an older FF and we need to read/upgrade them in newer FF.
The old format didn't use origin attributes, it used origin and group prefixed with a jar prefix.
The code is self contained, it's not exported anywhere, I don't see why we need a plan to remove it.
Comment 15•8 years ago
|
||
Comment on attachment 8799578 [details] [diff] [review]
Removes the jar prefix code that is no longer needed.
Review of attachment 8799578 [details] [diff] [review]:
-----------------------------------------------------------------
I'm a reviewer for dom/quota, that's why I commented on ActorsParent.cpp changes, but I'm not a reviewer for dom/caps.
You need to find some one else, sorry about that.
Attachment #8799578 -
Flags: review?(jvarga)
Assignee | ||
Comment 16•8 years ago
|
||
Comment on attachment 8799578 [details] [diff] [review]
Removes the jar prefix code that is no longer needed.
Hi Dan,
According to the modules list, you're a peer for DOM/Security/Caps which this patch is a part of. Would you mind reviewing it for me?
Thanks,
--dave
Attachment #8799578 -
Flags: review?(dveditz)
Comment 17•8 years ago
|
||
Comment on attachment 8799578 [details] [diff] [review]
Removes the jar prefix code that is no longer needed.
Review of attachment 8799578 [details] [diff] [review]:
-----------------------------------------------------------------
r=dveditz
I worry about changing the binary compatibility of nsIPrincipal and nsIScriptSecurityManager because in the past external apps hooked into those and we caused crashes. Maybe that doesn't happen as much anymore, but we should keep an eye out for hints of it when we hit Beta.
Attachment #8799578 -
Flags: review?(dveditz) → review+
Assignee | ||
Comment 18•8 years ago
|
||
(In reply to Daniel Veditz [:dveditz] from comment #17)
> we should keep an eye out for hints of it when we hit Beta.
Can you elaborate on what that looks like? I'd like to better understand what you mean by that.
Flags: needinfo?(dveditz)
Assignee | ||
Comment 19•8 years ago
|
||
Comment 20•8 years ago
|
||
(In reply to Dave Huseby [:huseby] from comment #18)
> (In reply to Daniel Veditz [:dveditz] from comment #17)
> > we should keep an eye out for hints of it when we hit Beta.
>
> Can you elaborate on what that looks like? I'd like to better understand
> what you mean by that.
New crashes, possibly in 3rd party .dll's, possibly in principal or ScriptSecurityManager code. It /should/ be OK.
Flags: needinfo?(dveditz)
Assignee | ||
Comment 21•8 years ago
|
||
The try push looks good.
Assignee | ||
Comment 22•8 years ago
|
||
already r+, rebased. try push looks good.
Attachment #8799578 -
Attachment is obsolete: true
Attachment #8804041 -
Flags: review+
Assignee | ||
Updated•8 years ago
|
Keywords: checkin-needed
Comment 23•8 years ago
|
||
Pushed by cbook@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/f19085b4d55b
Eliminate nsIPrincipal::jarPrefix. r=dveditz
Keywords: checkin-needed
Comment 24•8 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox52:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla52
You need to log in
before you can comment on or make changes to this bug.
Description
•