Last Comment Bug 668558 - remove JSSecurityCallbacks::subsumePrincipals
: remove JSSecurityCallbacks::subsumePrincipals
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: JavaScript Engine (show other bugs)
: unspecified
: All All
: -- normal (vote)
: mozilla17
Assigned To: Luke Wagner [:luke]
:
:
Mentors:
Depends on: cpg
Blocks:
  Show dependency treegraph
 
Reported: 2011-06-30 10:15 PDT by Luke Wagner [:luke]
Modified: 2012-08-23 19:19 PDT (History)
6 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
removed (8.36 KB, patch)
2011-08-22 11:14 PDT, Luke Wagner [:luke]
no flags Details | Diff | Splinter Review
rm (4.98 KB, patch)
2012-08-21 16:29 PDT, Luke Wagner [:luke]
no flags Details | Diff | Splinter Review
rm (4.04 KB, patch)
2012-08-21 16:33 PDT, Luke Wagner [:luke]
no flags Details | Diff | Splinter Review
rm (4.71 KB, patch)
2012-08-22 15:23 PDT, Luke Wagner [:luke]
mrbkap: review+
Details | Diff | Splinter Review

Description Luke Wagner [:luke] 2011-06-30 10:15:15 PDT
With compartments we've been ripping out JSPrincipals::subsume calls.  There are only two remaining uses: EvalCacheLookup and obj_watch_handler.  The former is probably unnecessary since the table is per-compartment.  The latter may be as well but Jason remembers that we failed to remove it earlier for some reason that perhaps Blake knows...

With JSPrincipals::subsume removed, JSPrincipals is just an opaque ref-counted annotation on scripts which is a heck of a lot less scary from a JS-hacker's perspective.  (With compartment-per-global, script->principals can be removed which (as well as all these principal-taking JSAPIs) since the principal will necessarily be == compartment->principals.)
Comment 1 Luke Wagner [:luke] 2011-08-22 11:14:27 PDT
Created attachment 554911 [details] [diff] [review]
removed

Here's the patch to do it.  With document.domain, the EvalCacheLookup subsume check seems to want compartment-per-global.  Any chance I'm wrong mrbkap?
Comment 2 Luke Wagner [:luke] 2012-08-21 16:29:44 PDT
Created attachment 654006 [details] [diff] [review]
rm

Let's do this.
Comment 3 Luke Wagner [:luke] 2012-08-21 16:33:18 PDT
Created attachment 654008 [details] [diff] [review]
rm

Err, not that, this.
Comment 4 Luke Wagner [:luke] 2012-08-22 15:23:41 PDT
Created attachment 654386 [details] [diff] [review]
rm

Rebased
Comment 5 Blake Kaplan (:mrbkap) 2012-08-22 15:50:23 PDT
Comment on attachment 654386 [details] [diff] [review]
rm

Nice to see this go.
Comment 7 Ryan VanderMeulen [:RyanVM] 2012-08-23 19:19:03 PDT
https://hg.mozilla.org/mozilla-central/rev/00646164061d

Note You need to log in before you can comment on or make changes to this bug.