Closed
Bug 1294767
Opened 8 years ago
Closed 8 years ago
Add assertions that type inference data structures don't contain cross compartment pointers
Categories
(Core :: JavaScript: GC, defect)
Core
JavaScript: GC
Tracking
()
RESOLVED
FIXED
mozilla52
People
(Reporter: jonco, Assigned: jonco)
References
Details
(Keywords: sec-audit, Whiteboard: [adv-main52-])
Attachments
(1 file)
8.31 KB,
patch
|
jandem
:
review+
|
Details | Diff | Splinter Review |
Following bug 1294241, we should investigate adding assertions that type sets don't contain cross compartment pointers as this is a sure-fire way get UAF bugs.
Assignee | ||
Comment 1•8 years ago
|
||
Here's a patch to add some compartment checking asserts to type inference. The aim of this is to prevent UAF bugs like that referenced above and also to hopefully shed some light on bug 1220385.
Attachment #8792552 -
Flags: review?(jdemooij)
Comment 2•8 years ago
|
||
Comment on attachment 8792552 [details] [diff] [review] bug1294767-type-set-asserts Review of attachment 8792552 [details] [diff] [review]: ----------------------------------------------------------------- Nice. ::: js/src/vm/TypeInference-inl.h @@ +1017,5 @@ > return nullptr; > } > > +inline JSCompartment* > +TypeSet::maybeCompartment() Nit: maybe move to the cpp file, as it's only called there AFAICS and it's pretty large.
Attachment #8792552 -
Flags: review?(jdemooij) → review+
Assignee | ||
Comment 3•8 years ago
|
||
I don't think this needs to be s-s as it only adds asserts and doesn't highlight any specific vulnerability. Try is green with this patch.
Group: javascript-core-security
Pushed by jcoppeard@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/ed8f6b83ebed Add assertions that type sets do not contain cross compartment pointers r=jandem
Comment 5•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/ed8f6b83ebed
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox52:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla52
Comment 6•8 years ago
|
||
Should this land on 51 as well or can it ride the trains?
Flags: needinfo?(jcoppeard)
Assignee | ||
Comment 7•8 years ago
|
||
This doesn't seem to have shown up any problems. I'd say just let it ride.
Flags: needinfo?(jcoppeard)
Updated•8 years ago
|
status-firefox50:
--- → wontfix
status-firefox51:
--- → wontfix
Updated•7 years ago
|
Whiteboard: [adv-main52-]
You need to log in
before you can comment on or make changes to this bug.
Description
•