Chrome 42.0.2311.87 MutationObserver::disconnect Use-after-free

2015.05.03
Credit: kouhei
Risk: High
Local: No
Remote: Yes
CWE: N/A


CVSS Base Score: 7.5/10
Impact Subscore: 6.4/10
Exploitability Subscore: 10/10
Exploit range: Remote
Attack complexity: Low
Authentication: No required
Confidentiality impact: Partial
Integrity impact: Partial
Availability impact: Partial

Use-after-free vulnerability in the MutationObserver::disconnect function in core/dom/MutationObserver.cpp in the DOM implementation in Blink, as used in Google Chrome before 42.0.2311.135, allows remote attackers to cause a denial of service or possibly have unspecified other impact by triggering an attempt to unregister a MutationObserver object that is not currently registered. MutationObserver: add a check that iterating registration still exists in original set The MutationObserver registration may be unregistered from the original set while iterating on the cloned set. Add a check so that it would only call unregister() on active registrations. --- trunk/Source/core/dom/MutationObserver.cpp 2015/03/27 07:09:14 192654 +++ trunk/Source/core/dom/MutationObserver.cpp 2015/03/27 07:16:44 192655 @@ -156,8 +156,12 @@ m_records.clear(); InspectorInstrumentation::didClearAllMutationRecords(m_callback->executionContext(), this); MutationObserverRegistrationSet registrations(m_registrations); - for (auto& registration : registrations) - registration->unregister(); + for (auto& registration : registrations) { + // The registration may be already unregistered while iteration. + // Only call unregister if it is still in the original set. + if (m_registrations.contains(registration)) + registration->unregister(); + } ASSERT(m_registrations.isEmpty()); }

References:

https://src.chromium.org/viewvc/blink?revision=192655&view=revision
https://code.google.com/p/chromium/issues/detail?id=453279
http://googlechromereleases.blogspot.com/2015/04/stable-channel-update_28.html


Vote for this issue:
100%
0%


 

Thanks for you vote!


 

Thanks for you comment!
Your message is in quarantine 48 hours.

Comment it here.


(*) - required fields.  
{{ x.nick }} | Date: {{ x.ux * 1000 | date:'yyyy-MM-dd' }} {{ x.ux * 1000 | date:'HH:mm' }} CET+1
{{ x.comment }}

Copyright 2024, cxsecurity.com

 

Back to Top