AddressSanitizer: heap-use-after-free in [@ mozilla::PresShell::RemoveRefreshObserver]
A heap-use-after-free occurs in Firefox's PresShell::RemoveRefreshObserver when accessibility is enabled and a cycle collection runs during a selection operation. An attacker could potentially crash the browser tab, but the report does not demonstrate code execution or data theft.
Originally disclosed on Mozilla
- Fixed in 33 days
- Paid in 40 days
- Disclosed after 33 days
Created attachment 9220726 asan.archlinux.txt
While fuzzing on Firefox ASan fuzzing build, the tab crashed on Arch Linux with SUMMARY: AddressSanitizer: heap-use-after-free RefPtr.h:286:27 in get and Windows 10 with heap-use-after-free gecko/layout/base/PresShell.cpp:9914 in mozilla::PresShell::RemoveRefreshObserver
The testcase is still intermittent it require FuzzingFunctions.enableAccessibility() function and few interaction. Currently I'm still refactor the code in hope it able to reproduce easily. I'll attach the testcase once I'm done with it =).
Reproduced on
- Firefox Nightly 90.0a1 (m-c-20210506092558-fuzzing-asan-opt) (64-bit) on Arch Linux
- Firefox Nightly 90.0a1 (m-c-20210506214311-fuzzing-asan-opt) (64-bit) on Windows 10
ASan
Arch Linux
=================================================================
==1607538==ERROR: AddressSanitizer: heap-use-after-free on address 0x622000051170 at pc 0x7fbf691d93a9 bp 0x7ffc02fc2f20 sp 0x7ffc02fc2f18
READ of size 8 at 0x622000051170 thread T0 (Web Content)
#0 0x7fbf691d93a8 in get /builds/worker/workspace/obj-build/dist/include/mozilla/RefPtr.h:286:27
#1 0x7fbf691d93a8 in operator nsPresContext * /builds/worker/workspace/obj-build/dist/include/mozilla/RefPtr.h:299:12
#2 0x7fbf691d93a8 in GetPresContext /builds/worker/workspace/obj-build/dist/include/mozilla/PresShell.h:285:50
#3 0x7fbf691d93a8 in mozilla::PresShell::RemoveRefreshObserver(nsARefreshObserver*, mozilla::FlushType) /builds/worker/checkouts/gecko/layout/base/PresShell.cpp:9913:32
#4 0x7fbf6c554c63 in mozilla::a11y::NotificationController::Shutdown() /builds/worker/checkouts/gecko/accessible/base/NotificationController.cpp:82:19
#5 0x7fbf6c5af1ef in mozilla::a11y::DocAccessible::Shutdown() /builds/worker/checkouts/gecko/accessible/generic/DocAccessible.cpp:397:30
#6 0x7fbf6c5ab4ed in Unlink /builds/worker/checkouts/gecko/accessible/generic/LocalAccessible.cpp:93:8
#7 0x7fbf6c5ab4ed in mozilla::a11y::DocAccessible::cycleCollection::Unlink(void*) /builds/worker/checkouts/gecko/accessible/generic/DocAccessible.cpp:140:1
#8 0x7fbf6128d1e5 in nsCycleCollector::CollectWhite() /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:3081:26
#9 0x7fbf6128ffa3 in nsCycleCollector::Collect(ccType, js::SliceBudget&, nsICycleCollectorListener*, bool) /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:3435:26
#10 0x7fbf6129319d in nsCycleCollector_collect(nsICycleCollectorListener*) /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:3910:28
#11 0x7fbf64a42e5e in nsJSContext::CycleCollectNow(nsICycleCollectorListener*) /builds/worker/checkouts/gecko/dom/base/nsJSEnvironment.cpp:1411:3
#12 0x7fbf66081c82 in mozilla::dom::FuzzingFunctions_Binding::cycleCollect(JSContext*, unsigned int, JS::Value*) /builds/worker/workspace/obj-build/dom/bindings/FuzzingFunctionsBinding.cpp:96:3
#13 0x7fbf6d0e6022 in CallJSNative /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:427:13
#14 0x7fbf6d0e6022 in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512:12
#15 0x7fbf6d0cd7c5 in CallFromStack /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:576:10
#16 0x7fbf6d0cd7c5 in Interpret(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227:16
#17 0x7fbf6d0b6e36 in js::RunScript(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396:13
#18 0x7fbf6d0e615b in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544:13
#19 0x7fbf6d0e7d5b in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589:8
#20 0x7fbf6d953f62 in JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) /builds/worker/checkouts/gecko/js/src/jsapi.cpp:2849:10
#21 0x7fbf65e76ad4 in mozilla::dom::EventHandlerNonNull::Call(mozilla::dom::BindingCallContext&, JS::Handle<JS::Value>, mozilla::dom::Event&, JS::MutableHandle<JS::Value>, mozilla::ErrorResult&) /builds/worker/workspace/obj-build/dom/bindings/EventHandlerBinding.cpp:279:37
#22 0x7fbf66b21961 in void mozilla::dom::EventHandlerNonNull::Call<nsCOMPtr<mozilla::dom::EventTarget> >(nsCOMPtr<mozilla::dom::EventTarget> const&, mozilla::dom::Event&, JS::MutableHandle<JS::Value>, mozilla::ErrorResult&, char const*, mozilla::dom::CallbackObject::ExceptionHandling, JS::Realm*) /builds/worker/workspace/obj-build/dist/include/mozilla/dom/EventHandlerBinding.h:365:12
#23 0x7fbf66b1fda3 in mozilla::JSEventHandler::HandleEvent(mozilla::dom::Event*) /builds/worker/checkouts/gecko/dom/events/JSEventHandler.cpp:201:12
#24 0x7fbf66ae8cf8 in mozilla::EventListenerManager::HandleEventSubType(mozilla::EventListenerManager::Listener*, mozilla::dom::Event*, mozilla::dom::EventTarget*) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1114:22
#25 0x7fbf66aea287 in mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1305:17
#26 0x7fbf66ad79ae in mozilla::EventTargetChainItem::HandleEvent(mozilla::EventChainPostVisitor&, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:354:17
#27 0x7fbf66ad6440 in mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:592:14
#28 0x7fbf66ada48d in mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:1099:11
#29 0x7fbf66adfc99 in mozilla::EventDispatcher::DispatchDOMEvent(nsISupports*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsPresContext*, nsEventStatus*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp
#30 0x7fbf64a33d3a in nsINode::DispatchEvent(mozilla::dom::Event&, mozilla::dom::CallerType, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/nsINode.cpp:1331:17
#31 0x7fbf6450d1cf in nsContentUtils::DispatchEvent(mozilla::dom::Document*, nsISupports*, nsTSubstring<char16_t> const&, mozilla::CanBubble, mozilla::Cancelable, mozilla::Composed, mozilla::Trusted, bool*, mozilla::ChromeOnlyDispatch) /builds/worker/checkouts/gecko/dom/base/nsContentUtils.cpp:4301:28
#32 0x7fbf6450cf13 in nsContentUtils::DispatchTrustedEvent(mozilla::dom::Document*, nsISupports*, nsTSubstring<char16_t> const&, mozilla::CanBubble, mozilla::Cancelable, mozilla::Composed, bool*) /builds/worker/checkouts/gecko/dom/base/nsContentUtils.cpp:4271:10
#33 0x7fbf648f9975 in DispatchTrustedEvent /builds/worker/workspace/obj-build/dist/include/nsContentUtils.h:1453:12
#34 0x7fbf648f9975 in MaybeDispatchSelectstartEvent(nsRange const&, bool, mozilla::dom::Document*) /builds/worker/checkouts/gecko/dom/base/Selection.cpp:825:5
#35 0x7fbf648f91f2 in mozilla::dom::Selection::AddRangesForUserSelectableNodes(nsRange*, int*, mozilla::dom::Selection::DispatchSelectstartEvent) /builds/worker/checkouts/gecko/dom/base/Selection.cpp:890:41
#36 0x7fbf6490040b in mozilla::dom::Selection::AddRangeAndSelectFramesAndNotifyListeners(nsRange&, mozilla::dom::Document*, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/Selection.cpp:1936:14
#37 0x7fbf649001e5 in mozilla::dom::Selection::AddRangeAndSelectFramesAndNotifyListeners(nsRange&, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/Selection.cpp:1895:10
#38 0x7fbf64905493 in mozilla::dom::Selection::SetStartAndEndInternal(mozilla::dom::Selection::InLimiter, mozilla::RangeBoundaryBase<nsINode*, nsIContent*> const&, mozilla::RangeBoundaryBase<nsINode*, nsIContent*> const&, nsDirection, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/Selection.cpp:3461:3
#39 0x7fbf649051b9 in mozilla::dom::Selection::SelectAllChildren(nsINode&, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/Selection.cpp:2676:3
#40 0x7fbf68edce90 in mozilla::HTMLEditor::SelectAllInternal() /builds/worker/checkouts/gecko/editor/libeditor/HTMLEditor.cpp:3972:18
#41 0x7fbf68e26bc2 in mozilla::EditorBase::SelectAll() /builds/worker/checkouts/gecko/editor/libeditor/EditorBase.cpp:1083:17
#42 0x7fbf64773a31 in mozilla::dom::Document::ExecCommand(nsTSubstring<char16_t> const&, bool, nsTSubstring<char16_t> const&, nsIPrincipal&, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/Document.cpp:5293:37
#43 0x7fbf65eb0e1c in mozilla::dom::Document_Binding::execCommand(JSContext*, JS::Handle<JSObject*>, void*, JSJitMethodCallArgs const&) /builds/worker/workspace/obj-build/dom/bindings/DocumentBinding.cpp:3471:36
#44 0x7fbf6633b4c9 in bool mozilla::dom::binding_detail::GenericMethod<mozilla::dom::binding_detail::NormalThisPolicy, mozilla::dom::binding_detail::ThrowExceptions>(JSContext*, unsigned int, JS::Value*) /builds/worker/checkouts/gecko/dom/bindings/BindingUtils.cpp:3260:13
#45 0x7fbf6d0e6022 in CallJSNative /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:427:13
#46 0x7fbf6d0e6022 in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512:12
#47 0x7fbf6d0cd7c5 in CallFromStack /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:576:10
#48 0x7fbf6d0cd7c5 in Interpret(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227:16
#49 0x7fbf6d0b6e36 in js::RunScript(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396:13
#50 0x7fbf6d0e615b in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544:13
#51 0x7fbf6d0e7d5b in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589:8
#52 0x7fbf6d953f62 in JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) /builds/worker/checkouts/gecko/js/src/jsapi.cpp:2849:10
#53 0x7fbf65e797a9 in mozilla::dom::EventListener::HandleEvent(mozilla::dom::BindingCallContext&, JS::Handle<JS::Value>, mozilla::dom::Event&, mozilla::ErrorResult&) /builds/worker/workspace/obj-build/dom/bindings/EventListenerBinding.cpp:58:8
#54 0x7fbf66ae9168 in void mozilla::dom::EventListener::HandleEvent<mozilla::dom::EventTarget*>(mozilla::dom::EventTarget* const&, mozilla::dom::Event&, mozilla::ErrorResult&, char const*, mozilla::dom::CallbackObject::ExceptionHandling, JS::Realm*) /builds/worker/workspace/obj-build/dist/include/mozilla/dom/EventListenerBinding.h:65:12
#55 0x7fbf66ae8c60 in mozilla::EventListenerManager::HandleEventSubType(mozilla::EventListenerManager::Listener*, mozilla::dom::Event*, mozilla::dom::EventTarget*) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1108:43
#56 0x7fbf66aea287 in mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1305:17
#57 0x7fbf66ad79ae in mozilla::EventTargetChainItem::HandleEvent(mozilla::EventChainPostVisitor&, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:354:17
#58 0x7fbf66ad6440 in mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:592:14
#59 0x7fbf66ada48d in mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:1099:11
#60 0x7fbf66adfc99 in mozilla::EventDispatcher::DispatchDOMEvent(nsISupports*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsPresContext*, nsEventStatus*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp
#61 0x7fbf64a33d3a in nsINode::DispatchEvent(mozilla::dom::Event&, mozilla::dom::CallerType, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/nsINode.cpp:1331:17
#62 0x7fbf66af6a33 in mozilla::dom::EventTarget::DispatchEvent(mozilla::dom::Event&) /builds/worker/checkouts/gecko/dom/events/EventTarget.cpp:177:13
#63 0x7fbf66a6985c in mozilla::AsyncEventDispatcher::Run() /builds/worker/checkouts/gecko/dom/events/AsyncEventDispatcher.cpp:69:12
#64 0x7fbf64518ca4 in nsContentUtils::RemoveScriptBlocker() /builds/worker/checkouts/gecko/dom/base/nsContentUtils.cpp:5682:17
#65 0x7fbf64487569 in mozAutoDocUpdate::~mozAutoDocUpdate() /builds/worker/checkouts/gecko/dom/base/mozAutoDocUpdate.h:36:7
#66 0x7fbf647e8d27 in mozilla::dom::Element::SetAttr(int, nsAtom*, nsAtom*, nsTSubstring<char16_t> const&, nsIPrincipal*, bool) /builds/worker/checkouts/gecko/dom/base/Element.cpp:2362:1
#67 0x7fbf647e85f6 in SetAttr /builds/worker/workspace/obj-build/dist/include/mozilla/dom/Element.h:942:12
#68 0x7fbf647e85f6 in mozilla::dom::Element::SetAttribute(nsTSubstring<char16_t> const&, nsTSubstring<char16_t> const&, nsIPrincipal*, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/Element.cpp:1421:14
#69 0x7fbf65f2f7a5 in mozilla::dom::Element_Binding::setAttribute(JSContext*, JS::Handle<JSObject*>, void*, JSJitMethodCallArgs const&) /builds/worker/workspace/obj-build/dom/bindings/ElementBinding.cpp:1366:24
#70 0x7fbf6633b4c9 in bool mozilla::dom::binding_detail::GenericMethod<mozilla::dom::binding_detail::NormalThisPolicy, mozilla::dom::binding_detail::ThrowExceptions>(JSContext*, unsigned int, JS::Value*) /builds/worker/checkouts/gecko/dom/bindings/BindingUtils.cpp:3260:13
#71 0x7fbf6d0e6022 in CallJSNative /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:427:13
#72 0x7fbf6d0e6022 in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512:12
#73 0x7fbf6d0cd7c5 in CallFromStack /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:576:10
#74 0x7fbf6d0cd7c5 in Interpret(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227:16
#75 0x7fbf6d0b6e36 in js::RunScript(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396:13
#76 0x7fbf6d0e615b in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544:13
#77 0x7fbf6d0e7d5b in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589:8
#78 0x7fbf6d953f62 in JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) /builds/worker/checkouts/gecko/js/src/jsapi.cpp:2849:10
#79 0x7fbf65e797a9 in mozilla::dom::EventListener::HandleEvent(mozilla::dom::BindingCallContext&, JS::Handle<JS::Value>, mozilla::dom::Event&, mozilla::ErrorResult&) /builds/worker/workspace/obj-build/dom/bindings/EventListenerBinding.cpp:58:8
#80 0x7fbf66ae9168 in void mozilla::dom::EventListener::HandleEvent<mozilla::dom::EventTarget*>(mozilla::dom::EventTarget* const&, mozilla::dom::Event&, mozilla::ErrorResult&, char const*, mozilla::dom::CallbackObject::ExceptionHandling, JS::Realm*) /builds/worker/workspace/obj-build/dist/include/mozilla/dom/EventListenerBinding.h:65:12
#81 0x7fbf66ae8c60 in mozilla::EventListenerManager::HandleEventSubType(mozilla::EventListenerManager::Listener*, mozilla::dom::Event*, mozilla::dom::EventTarget*) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1108:43
#82 0x7fbf66aea287 in mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1305:17
#83 0x7fbf66ad79ae in mozilla::EventTargetChainItem::HandleEvent(mozilla::EventChainPostVisitor&, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:354:17
#84 0x7fbf66ad61d1 in mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:556:16
#85 0x7fbf66ada48d in mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:1099:11
#86 0x7fbf66adfc99 in mozilla::EventDispatcher::DispatchDOMEvent(nsISupports*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsPresContext*, nsEventStatus*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp
#87 0x7fbf64a33d3a in nsINode::DispatchEvent(mozilla::dom::Event&, mozilla::dom::CallerType, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/nsINode.cpp:1331:17
#88 0x7fbf66af6a33 in mozilla::dom::EventTarget::DispatchEvent(mozilla::dom::Event&) /builds/worker/checkouts/gecko/dom/events/EventTarget.cpp:177:13
#89 0x7fbf66a6985c in mozilla::AsyncEventDispatcher::Run() /builds/worker/checkouts/gecko/dom/events/AsyncEventDispatcher.cpp:69:12
#90 0x7fbf64518ca4 in nsContentUtils::RemoveScriptBlocker() /builds/worker/checkouts/gecko/dom/base/nsContentUtils.cpp:5682:17
#91 0x7fbf64787e68 in mozilla::dom::Document::EndUpdate() /builds/worker/checkouts/gecko/dom/base/Document.cpp:7582:3
#92 0x7fbf64487526 in mozAutoDocUpdate::~mozAutoDocUpdate() /builds/worker/checkouts/gecko/dom/base/mozAutoDocUpdate.h:34:18
#93 0x7fbf647e8d27 in mozilla::dom::Element::SetAttr(int, nsAtom*, nsAtom*, nsTSubstring<char16_t> const&, nsIPrincipal*, bool) /builds/worker/checkouts/gecko/dom/base/Element.cpp:2362:1
#94 0x7fbf647e868a in mozilla::dom::Element::SetAttribute(nsTSubstring<char16_t> const&, nsTSubstring<char16_t> const&, nsIPrincipal*, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/Element.cpp:1426:12
#95 0x7fbf65f2f7a5 in mozilla::dom::Element_Binding::setAttribute(JSContext*, JS::Handle<JSObject*>, void*, JSJitMethodCallArgs const&) /builds/worker/workspace/obj-build/dom/bindings/ElementBinding.cpp:1366:24
#96 0x7fbf6633b4c9 in bool mozilla::dom::binding_detail::GenericMethod<mozilla::dom::binding_detail::NormalThisPolicy, mozilla::dom::binding_detail::ThrowExceptions>(JSContext*, unsigned int, JS::Value*) /builds/worker/checkouts/gecko/dom/bindings/BindingUtils.cpp:3260:13
#97 0x7fbf6d0e6022 in CallJSNative /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:427:13
#98 0x7fbf6d0e6022 in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512:12
#99 0x7fbf6d0cd7c5 in CallFromStack /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:576:10
#100 0x7fbf6d0cd7c5 in Interpret(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227:16
#101 0x7fbf6d0b6e36 in js::RunScript(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396:13
#102 0x7fbf6d0e615b in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544:13
#103 0x7fbf6d0e7d5b in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589:8
#104 0x7fbf6d953f62 in JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) /builds/worker/checkouts/gecko/js/src/jsapi.cpp:2849:10
#105 0x7fbf65e797a9 in mozilla::dom::EventListener::HandleEvent(mozilla::dom::BindingCallContext&, JS::Handle<JS::Value>, mozilla::dom::Event&, mozilla::ErrorResult&) /builds/worker/workspace/obj-build/dom/bindings/EventListenerBinding.cpp:58:8
#106 0x7fbf66ae9168 in void mozilla::dom::EventListener::HandleEvent<mozilla::dom::EventTarget*>(mozilla::dom::EventTarget* const&, mozilla::dom::Event&, mozilla::ErrorResult&, char const*, mozilla::dom::CallbackObject::ExceptionHandling, JS::Realm*) /builds/worker/workspace/obj-build/dist/include/mozilla/dom/EventListenerBinding.h:65:12
#107 0x7fbf66ae8c60 in mozilla::EventListenerManager::HandleEventSubType(mozilla::EventListenerManager::Listener*, mozilla::dom::Event*, mozilla::dom::EventTarget*) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1108:43
#108 0x7fbf66aea287 in mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1305:17
#109 0x7fbf66ad79ae in mozilla::EventTargetChainItem::HandleEvent(mozilla::EventChainPostVisitor&, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:354:17
#110 0x7fbf66ad61d1 in mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:556:16
#111 0x7fbf66ada48d in mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:1099:11
#112 0x7fbf66adfc99 in mozilla::EventDispatcher::DispatchDOMEvent(nsISupports*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsPresContext*, nsEventStatus*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp
#113 0x7fbf64a33d3a in nsINode::DispatchEvent(mozilla::dom::Event&, mozilla::dom::CallerType, mozilla::ErrorResult&) /builds/worker/checkouts/gecko/dom/base/nsINode.cpp:1331:17
#114 0x7fbf66af6a33 in mozilla::dom::EventTarget::DispatchEvent(mozilla::dom::Event&) /builds/worker/checkouts/gecko/dom/events/EventTarget.cpp:177:13
#115 0x7fbf66a6985c in mozilla::AsyncEventDispatcher::Run() /builds/worker/checkouts/gecko/dom/events/AsyncEventDispatcher.cpp:69:12
#116 0x7fbf64518ca4 in nsContentUtils::RemoveScriptBlocker() /builds/worker/checkouts/gecko/dom/base/nsContentUtils.cpp:5682:17
#117 0x7fbf64787e68 in mozilla::dom::Document::EndUpdate() /builds/worker/checkouts/gecko/dom/base/Document.cpp:7582:3
#118 0x7fbf64487526 in mozAutoDocUpdate::~mozAutoDocUpdate() /builds/worker/checkouts/gecko/dom/base/mozAutoDocUpdate.h:34:18
#119 0x7fbf647e8d27 in mozilla::dom::Element::SetAttr(int, nsAtom*, nsAtom*, nsTSubstring<char16_t> const&, nsIPrincipal*, bool) /builds/worker/checkouts/gecko/dom/base/Element.cpp:2362:1
#120 0x7fbf6612e991 in SetAttr /builds/worker/workspace/obj-build/dist/include/mozilla/dom/Element.h:938:12
#121 0x7fbf6612e991 in SetAttr /builds/worker/workspace/obj-build/dist/include/mozilla/dom/Element.h:934:12
#122 0x7fbf6612e991 in SetAttr /builds/worker/workspace/obj-build/dist/include/mozilla/dom/Element.h:1573:14
#123 0x7fbf6612e991 in SetHTMLAttr /builds/worker/checkouts/gecko/dom/html/nsGenericHTMLElement.h:733:5
#124 0x7fbf6612e991 in SetDraggable /builds/worker/checkouts/gecko/dom/html/nsGenericHTMLElement.h:105:5
#125 0x7fbf6612e991 in mozilla::dom::HTMLElement_Binding::set_draggable(JSContext*, JS::Handle<JSObject*>, void*, JSJitSetterCallArgs) /builds/worker/workspace/obj-build/dom/bindings/HTMLElementBinding.cpp:732:24
#126 0x7fbf66336b64 in bool mozilla::dom::binding_detail::GenericSetter<mozilla::dom::binding_detail::NormalThisPolicy>(JSContext*, unsigned int, JS::Value*) /builds/worker/checkouts/gecko/dom/bindings/BindingUtils.cpp:3208:8
#127 0x7fbf6d0e6022 in CallJSNative /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:427:13
#128 0x7fbf6d0e6022 in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512:12
#129 0x7fbf6d0e7d5b in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589:8
#130 0x7fbf6d0e9573 in js::CallSetter(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::Handle<JS::Value>) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:729:10
#131 0x7fbf6d5ebd91 in SetExistingProperty(JSContext*, JS::Handle<JS::PropertyKey>, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::Handle<js::NativeObject*>, js::PropertyResult const&, JS::ObjectOpResult&) /builds/worker/checkouts/gecko/js/src/vm/NativeObject.cpp:2661:8
#132 0x7fbf6d5e8570 in bool js::NativeSetProperty<(js::QualifiedBool)1>(JSContext*, JS::Handle<js::NativeObject*>, JS::Handle<JS::PropertyKey>, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::ObjectOpResult&) /builds/worker/checkouts/gecko/js/src/vm/NativeObject.cpp:2695:14
#133 0x7fbf6d0cde92 in SetProperty /builds/worker/checkouts/gecko/js/src/vm/ObjectOperations-inl.h:300:10
#134 0x7fbf6d0cde92 in SetPropertyOperation /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:262:10
#135 0x7fbf6d0cde92 in Interpret(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3003:12
#136 0x7fbf6d0b6e36 in js::RunScript(JSContext*, js::RunState&) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396:13
#137 0x7fbf6d0e615b in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544:13
#138 0x7fbf6d0e7d5b in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589:8
#139 0x7fbf6d953f62 in JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) /builds/worker/checkouts/gecko/js/src/jsapi.cpp:2849:10
#140 0x7fbf65e76ad4 in mozilla::dom::EventHandlerNonNull::Call(mozilla::dom::BindingCallContext&, JS::Handle<JS::Value>, mozilla::dom::Event&, JS::MutableHandle<JS::Value>, mozilla::ErrorResult&) /builds/worker/workspace/obj-build/dom/bindings/EventHandlerBinding.cpp:279:37
#141 0x7fbf66b21961 in void mozilla::dom::EventHandlerNonNull::Call<nsCOMPtr<mozilla::dom::EventTarget> >(nsCOMPtr<mozilla::dom::EventTarget> const&, mozilla::dom::Event&, JS::MutableHandle<JS::Value>, mozilla::ErrorResult&, char const*, mozilla::dom::CallbackObject::ExceptionHandling, JS::Realm*) /builds/worker/workspace/obj-build/dist/include/mozilla/dom/EventHandlerBinding.h:365:12
#142 0x7fbf66b1fda3 in mozilla::JSEventHandler::HandleEvent(mozilla::dom::Event*) /builds/worker/checkouts/gecko/dom/events/JSEventHandler.cpp:201:12
#143 0x7fbf66ae8cf8 in mozilla::EventListenerManager::HandleEventSubType(mozilla::EventListenerManager::Listener*, mozilla::dom::Event*, mozilla::dom::EventTarget*) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1114:22
#144 0x7fbf66aea287 in mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1305:17
#145 0x7fbf66ad79ae in mozilla::EventTargetChainItem::HandleEvent(mozilla::EventChainPostVisitor&, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:354:17
#146 0x7fbf66ad61d1 in mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:556:16
#147 0x7fbf66ada48d in mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:1099:11
#148 0x7fbf6926b436 in nsDocumentViewer::LoadComplete(nsresult) /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:1084:7
#149 0x7fbf6c3e3277 in nsDocShell::EndPageLoad(nsIWebProgress*, nsIChannel*, nsresult) /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:6501:20
#150 0x7fbf6c3e2563 in nsDocShell::OnStateChange(nsIWebProgress*, nsIRequest*, unsigned int, nsresult) /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:5891:7
#151 0x7fbf6c3e44ef in non-virtual thunk to nsDocShell::OnStateChange(nsIWebProgress*, nsIRequest*, unsigned int, nsresult) /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp
#152 0x7fbf634d69f9 in nsDocLoader::DoFireOnStateChange(nsIWebProgress*, nsIRequest*, int&, nsresult) /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:1348:3
#153 0x7fbf634d5774 in nsDocLoader::doStopDocumentLoad(nsIRequest*, nsresult) /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:954:14
#154 0x7fbf634d26b3 in nsDocLoader::DocLoaderIsEmpty(bool, mozilla::Maybe<nsresult> const&) /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:773:9
#155 0x7fbf634d4604 in nsDocLoader::OnStopRequest(nsIRequest*, nsresult) /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:656:5
#156 0x7fbf6c41c0af in nsDocShell::OnStopRequest(nsIRequest*, nsresult) /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:13628:23
#157 0x7fbf6172ef4e in mozilla::net::nsLoadGroup::NotifyRemovalObservers(nsIRequest*, nsresult) /builds/worker/checkouts/gecko/netwerk/base/nsLoadGroup.cpp:625:22
#158 0x7fbf61731713 in mozilla::net::nsLoadGroup::RemoveRequest(nsIRequest*, nsISupports*, nsresult) /builds/worker/checkouts/gecko/netwerk/base/nsLoadGroup.cpp:529:10
#159 0x7fbf647aa4f0 in mozilla::dom::Document::DoUnblockOnload() /builds/worker/checkouts/gecko/dom/base/Document.cpp:11309:18
#160 0x7fbf64829caf in mozilla::dom::nsUnblockOnloadEvent::Run() /builds/worker/checkouts/gecko/dom/base/Document.cpp:11263:11
#161 0x7fbf6141961f in mozilla::SchedulerGroup::Runnable::Run() /builds/worker/checkouts/gecko/xpcom/threads/SchedulerGroup.cpp:143:20
#162 0x7fbf6145d2f2 in mozilla::RunnableTask::Run() /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:482:16
#163 0x7fbf61429d00 in mozilla::TaskController::DoExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:766:26
#164 0x7fbf61427807 in mozilla::TaskController::ExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:621:15
#165 0x7fbf61427c5d in mozilla::TaskController::ProcessPendingMTTask(bool) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:405:36
#166 0x7fbf61466ca1 in operator() /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:138:37
#167 0x7fbf61466ca1 in mozilla::detail::RunnableFunction<mozilla::TaskController::InitializeInternal()::$_0>::Run() /builds/worker/checkouts/gecko/xpcom/threads/nsThreadUtils.h:534:5
#168 0x7fbf61444628 in nsThread::ProcessNextEvent(bool, bool*) /builds/worker/checkouts/gecko/xpcom/threads/nsThread.cpp:1159:16
#169 0x7fbf6144f3dc in NS_ProcessNextEvent(nsIThread*, bool) /builds/worker/checkouts/gecko/xpcom/threads/nsThreadUtils.cpp:548:10
#170 0x7fbf625f334f in mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) /builds/worker/checkouts/gecko/ipc/glue/MessagePump.cpp:85:21
#171 0x7fbf624fdb71 in RunInternal /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:335:10
#172 0x7fbf624fdb71 in RunHandler /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:328:3
#173 0x7fbf624fdb71 in MessageLoop::Run() /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:310:3
#174 0x7fbf68c6dc37 in nsBaseAppShell::Run() /builds/worker/checkouts/gecko/widget/nsBaseAppShell.cpp:137:27
#175 0x7fbf6ce946df in XRE_RunAppShell() /builds/worker/checkouts/gecko/toolkit/xre/nsEmbedFunctions.cpp:911:20
#176 0x7fbf624fdb71 in RunInternal /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:335:10
#177 0x7fbf624fdb71 in RunHandler /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:328:3
#178 0x7fbf624fdb71 in MessageLoop::Run() /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:310:3
#179 0x7fbf6ce940b8 in XRE_InitChildProcess(int, char**, XREChildData const*) /builds/worker/checkouts/gecko/toolkit/xre/nsEmbedFunctions.cpp:743:34
#180 0x55c9d35ba5bd in content_process_main(mozilla::Bootstrap*, int, char**) /builds/worker/checkouts/gecko/browser/app/../../ipc/contentproc/plugin-container.cpp:57:28
#181 0x55c9d35ba9ed in main /builds/worker/checkouts/gecko/browser/app/nsBrowserApp.cpp:313:18
#182 0x7fbf821c6b24 in __libc_start_main (/usr/lib/libc.so.6+0x27b24)
#183 0x55c9d350b8b9 in _start (/tmp/m-c-20210506092558-fuzzing-asan-opt/firefox+0x5b8b9)
0x622000051170 is located 112 bytes inside of 4968-byte region [0x622000051100,0x622000052468)
freed by thread T0 (Web Content) here:
#0 0x55c9d35866c2 in free /builds/worker/fetches/llvm-project/llvm/projects/compiler-rt/lib/asan/asan_malloc_linux.cpp:127:3
#1 0x7fbf691948d9 in operator delete /builds/worker/workspace/obj-build/dist/include/mozilla/cxxalloc.h:51:10
#2 0x7fbf691948d9 in mozilla::PresShell::Release() /builds/worker/checkouts/gecko/layout/base/PresShell.cpp:889:1
#3 0x7fbf68fe4119 in ~nsCOMPtr_base /builds/worker/workspace/obj-build/dist/include/nsCOMPtr.h:328:7
#4 0x7fbf68fe4119 in mozilla::TextServicesDocument::~TextServicesDocument() /builds/worker/checkouts/gecko/editor/spellchecker/TextServicesDocument.cpp:78:1
#5 0x7fbf68ff3350 in DeleteCycleCollectable /builds/worker/checkouts/gecko/editor/spellchecker/TextServicesDocument.cpp:81:1
#6 0x7fbf68ff3350 in mozilla::TextServicesDocument::cycleCollection::DeleteCycleCollectable(void*) /builds/worker/checkouts/gecko/editor/spellchecker/TextServicesDocument.h:77:3
#7 0x7fbf612a7fd5 in SnowWhiteKiller::Visit(nsPurpleBuffer&, nsPurpleBufferEntry*) /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:2451:9
#8 0x7fbf612892f6 in void nsPurpleBuffer::VisitEntries<SnowWhiteKiller>(SnowWhiteKiller&) /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:939:23
#9 0x7fbf61289bbe in nsCycleCollector::FreeSnowWhiteWithBudget(js::SliceBudget&) /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:2619:14
#10 0x7fbf632ddae3 in AsyncFreeSnowWhite::Run() /builds/worker/checkouts/gecko/js/xpconnect/src/XPCJSRuntime.cpp:145:9
#11 0x7fbf6145bdb9 in IdleRunnableWrapper::Run() /builds/worker/checkouts/gecko/xpcom/threads/nsThreadUtils.cpp:364:22
#12 0x7fbf6145d2f2 in mozilla::RunnableTask::Run() /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:482:16
#13 0x7fbf61429d00 in mozilla::TaskController::DoExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:766:26
#14 0x7fbf6142799d in mozilla::TaskController::ExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:644:15
#15 0x7fbf61427c5d in mozilla::TaskController::ProcessPendingMTTask(bool) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:405:36
#16 0x7fbf61466ca1 in operator() /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:138:37
#17 0x7fbf61466ca1 in mozilla::detail::RunnableFunction<mozilla::TaskController::InitializeInternal()::$_0>::Run() /builds/worker/checkouts/gecko/xpcom/threads/nsThreadUtils.h:534:5
#18 0x7fbf61444628 in nsThread::ProcessNextEvent(bool, bool*) /builds/worker/checkouts/gecko/xpcom/threads/nsThread.cpp:1159:16
#19 0x7fbf6144f3dc in NS_ProcessNextEvent(nsIThread*, bool) /builds/worker/checkouts/gecko/xpcom/threads/nsThreadUtils.cpp:548:10
#20 0x7fbf625f334f in mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) /builds/worker/checkouts/gecko/ipc/glue/MessagePump.cpp:85:21
#21 0x7fbf624fdb71 in RunInternal /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:335:10
#22 0x7fbf624fdb71 in RunHandler /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:328:3
#23 0x7fbf624fdb71 in MessageLoop::Run() /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:310:3
#24 0x7fbf68c6dc37 in nsBaseAppShell::Run() /builds/worker/checkouts/gecko/widget/nsBaseAppShell.cpp:137:27
#25 0x7fbf6ce946df in XRE_RunAppShell() /builds/worker/checkouts/gecko/toolkit/xre/nsEmbedFunctions.cpp:911:20
previously allocated by thread T0 (Web Content) here:
#0 0x55c9d358692d in malloc /builds/worker/fetches/llvm-project/llvm/projects/compiler-rt/lib/asan/asan_malloc_linux.cpp:145:3
#1 0x55c9d35c0a4d in moz_xmalloc /builds/worker/checkouts/gecko/memory/mozalloc/mozalloc.cpp:52:15
#2 0x7fbf6477e6d1 in operator new /builds/worker/workspace/obj-build/dist/include/mozilla/cxxalloc.h:33:10
#3 0x7fbf6477e6d1 in mozilla::dom::Document::CreatePresShell(nsPresContext*, nsViewManager*) /builds/worker/checkouts/gecko/dom/base/Document.cpp:6600:33
#4 0x7fbf692685c5 in nsDocumentViewer::InitPresentationStuff(bool) /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:705:27
#5 0x7fbf69268089 in nsDocumentViewer::InitInternal(nsIWidget*, nsISupports*, mozilla::dom::WindowGlobalChild*, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&, bool, bool, bool) /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:910:10
#6 0x7fbf69267557 in nsDocumentViewer::Init(nsIWidget*, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&, mozilla::dom::WindowGlobalChild*) /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:681:10
#7 0x7fbf6c3e05dc in nsDocShell::SetupNewViewer(nsIContentViewer*, mozilla::dom::WindowGlobalChild*) /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:8242:7
#8 0x7fbf6c3df65e in nsDocShell::Embed(nsIContentViewer*, mozilla::dom::WindowGlobalChild*, bool, bool) /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:5766:17
#9 0x7fbf6c3a6c65 in nsDocShell::CreateContentViewer(nsTSubstring<char> const&, nsIRequest*, nsIStreamListener**) /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:8055:3
#10 0x7fbf6c3a4c45 in nsDSURIContentListener::DoContent(nsTSubstring<char> const&, bool, nsIRequest*, nsIStreamListener**, bool*) /builds/worker/checkouts/gecko/docshell/base/nsDSURIContentListener.cpp:178:20
#11 0x7fbf634e08e5 in nsDocumentOpenInfo::TryContentListener(nsIURIContentListener*, nsIChannel*) /builds/worker/checkouts/gecko/uriloader/base/nsURILoader.cpp:597:18
#12 0x7fbf634de040 in nsDocumentOpenInfo::DispatchContent(nsIRequest*, nsISupports*) /builds/worker/checkouts/gecko/uriloader/base/nsURILoader.cpp:276:9
#13 0x7fbf634dcf64 in nsDocumentOpenInfo::OnStartRequest(nsIRequest*) /builds/worker/checkouts/gecko/uriloader/base/nsURILoader.cpp:154:8
#14 0x7fbf61fdee4d in mozilla::net::HttpChannelChild::DoOnStartRequest(nsIRequest*, nsISupports*) /builds/worker/checkouts/gecko/netwerk/protocol/http/HttpChannelChild.cpp:575:20
#15 0x7fbf61fdda52 in mozilla::net::HttpChannelChild::OnStartRequest(mozilla::net::nsHttpResponseHead const&, bool const&, mozilla::net::nsHttpHeaderArray const&, mozilla::net::HttpChannelOnStartRequestArgs const&) /builds/worker/checkouts/gecko/netwerk/protocol/http/HttpChannelChild.cpp:506:3
#16 0x7fbf622cf479 in mozilla::net::ChannelEventQueue::FlushQueue() /builds/worker/checkouts/gecko/netwerk/ipc/ChannelEventQueue.cpp:90:12
#17 0x7fbf6231a647 in mozilla::net::ChannelEventQueue::ResumeInternal()::CompleteResumeRunnable::Run() /builds/worker/checkouts/gecko/netwerk/ipc/ChannelEventQueue.cpp:148:17
#18 0x7fbf6145d2f2 in mozilla::RunnableTask::Run() /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:482:16
#19 0x7fbf61429d00 in mozilla::TaskController::DoExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:766:26
#20 0x7fbf61427807 in mozilla::TaskController::ExecuteNextTaskOnlyMainThreadInternal(mozilla::detail::BaseAutoLock<mozilla::Mutex&> const&) /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:621:15
SUMMARY: AddressSanitizer: heap-use-after-free /builds/worker/workspace/obj-build/dist/include/mozilla/RefPtr.h:286:27 in get
Shadow bytes around the buggy address:
0x0c44800021d0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x0c44800021e0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x0c44800021f0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x0c4480002200: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x0c4480002210: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
=>0x0c4480002220: fd fd fd fd fd fd fd fd fd fd fd fd fd fd[fd]fd
0x0c4480002230: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x0c4480002240: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x0c4480002250: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x0c4480002260: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
0x0c4480002270: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
Addressable: 00
Partially addressable: 01 02 03 04 05 06 07
Heap left redzone: fa
Freed heap region: fd
Stack left redzone: f1
Stack mid redzone: f2
Stack right redzone: f3
Stack after return: f5
Stack use after scope: f8
Global redzone: f9
Global init order: f6
Poisoned by user: f7
Container overflow: fc
Array cookie: ac
Intra object redzone: bb
ASan internal: fe
Left alloca redzone: ca
Right alloca redzone: cb
Shadow gap: cc
==1607538==ABORTING
Windows 10
=================================================================
==3420==ERROR: AddressSanitizer: heap-use-after-free on address 0x129b11675970 at pc 0x7ffd203f44df bp 0x00f7383f4f00 sp 0x00f7383f4f48
READ of size 8 at 0x129b11675970 thread T0
#0 0x7ffd203f44de in mozilla::PresShell::RemoveRefreshObserver /builds/worker/checkouts/gecko/layout/base/PresShell.cpp:9914
#1 0x7ffd2359999a in mozilla::a11y::NotificationController::Shutdown /builds/worker/checkouts/gecko/accessible/base/NotificationController.cpp:81
#2 0x7ffd23619b22 in mozilla::a11y::DocAccessible::Shutdown /builds/worker/checkouts/gecko/accessible/generic/DocAccessible.cpp:397
#3 0x7ffd23615021 in mozilla::a11y::DocAccessible::cycleCollection::Unlink /builds/worker/checkouts/gecko/accessible/generic/DocAccessible.cpp:140
#4 0x7ffd165b5580 in nsCycleCollector::CollectWhite /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:3081
#5 0x7ffd165b8abf in nsCycleCollector::Collect /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:3435
#6 0x7ffd165bce7b in nsCycleCollector_collect /builds/worker/checkouts/gecko/xpcom/base/nsCycleCollector.cpp:3910
#7 0x7ffd1a4c82ef in nsJSContext::CycleCollectNow /builds/worker/checkouts/gecko/dom/base/nsJSEnvironment.cpp:1411
#8 0x7ffd1c435b20 in mozilla::dom::FuzzingFunctions_Binding::cycleCollect /builds/worker/workspace/obj-build/dom/bindings/FuzzingFunctionsBinding.cpp:96
#9 0x7ffd24373705 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512
#10 0x7ffd2435fbbe in Interpret /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227
#11 0x7ffd2434569a in js::RunScript /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396
#12 0x7ffd243739f5 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544
#13 0x7ffd24376368 in js::Call /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589
#14 0x7ffd24db97fb in JS::Call /builds/worker/checkouts/gecko/js/src/jsapi.cpp:2849
#15 0x7ffd1c1194cd in mozilla::dom::EventHandlerNonNull::Call /builds/worker/workspace/obj-build/dom/bindings/EventHandlerBinding.cpp:279
#16 0x7ffd1d3521c6 in mozilla::JSEventHandler::HandleEvent /builds/worker/checkouts/gecko/dom/events/JSEventHandler.cpp:201
#17 0x7ffd1d3085e0 in mozilla::EventListenerManager::HandleEventSubType /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1113
#18 0x7ffd1d30a34c in mozilla::EventListenerManager::HandleEventInternal /builds/worker/checkouts/gecko/dom/events/EventListenerManager.cpp:1304
#19 0x7ffd1d2ef856 in mozilla::EventTargetChainItem::HandleEvent /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:354
#20 0x7ffd1d2ed9da in mozilla::EventTargetChainItem::HandleEventTargetChain /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:556
#21 0x7ffd1d2f4093 in mozilla::EventDispatcher::Dispatch /builds/worker/checkouts/gecko/dom/events/EventDispatcher.cpp:1099
#22 0x7ffd204c31b8 in nsDocumentViewer::LoadComplete /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:1084
#23 0x7ffd233b8c1a in nsDocShell::EndPageLoad /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:6501
#24 0x7ffd233b7d15 in nsDocShell::OnStateChange /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:5891
#25 0x7ffd18a0621a in nsDocLoader::DoFireOnStateChange /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:1348
#26 0x7ffd18a04cb6 in nsDocLoader::doStopDocumentLoad /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:954
#27 0x7ffd18a005b9 in nsDocLoader::DocLoaderIsEmpty /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:773
#28 0x7ffd18a03289 in nsDocLoader::OnStopRequest /builds/worker/checkouts/gecko/uriloader/base/nsDocLoader.cpp:656
#29 0x7ffd233fefca in nsDocShell::OnStopRequest /builds/worker/checkouts/gecko/docshell/base/nsDocShell.cpp:13628
#30 0x7ffd16b5a506 in mozilla::net::nsLoadGroup::NotifyRemovalObservers /builds/worker/checkouts/gecko/netwerk/base/nsLoadGroup.cpp:625
#31 0x7ffd16b5d361 in mozilla::net::nsLoadGroup::RemoveRequest /builds/worker/checkouts/gecko/netwerk/base/nsLoadGroup.cpp:529
#32 0x7ffd1a160451 in mozilla::dom::Document::DoUnblockOnload /builds/worker/checkouts/gecko/dom/base/Document.cpp:11309
#33 0x7ffd1a101ddb in mozilla::dom::Document::UnblockOnload /builds/worker/checkouts/gecko/dom/base/Document.cpp:11239
#34 0x7ffd1a132fa1 in mozilla::dom::Document::DispatchContentLoadedEvents /builds/worker/checkouts/gecko/dom/base/Document.cpp:7774
#35 0x7ffd165fe97a in mozilla::detail::RunnableMethodImpl<nsMemoryReporterManager *,nsresult (nsMemoryReporterManager::*)(),1,mozilla::RunnableKind::Standard>::Run /builds/worker/workspace/obj-build/dist/include/nsThreadUtils.h:1201
#36 0x7ffd167ab8d6 in mozilla::SchedulerGroup::Runnable::Run /builds/worker/checkouts/gecko/xpcom/threads/SchedulerGroup.cpp:143
#37 0x7ffd168048fd in mozilla::RunnableTask::Run /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:482
#38 0x7ffd167c2359 in mozilla::TaskController::DoExecuteNextTaskOnlyMainThreadInternal /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:766
#39 0x7ffd167be64e in mozilla::TaskController::ExecuteNextTaskOnlyMainThreadInternal /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:621
#40 0x7ffd167beb60 in mozilla::TaskController::ProcessPendingMTTask /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:405
#41 0x7ffd1680e6f1 in mozilla::detail::RunnableFunction<`lambda at /builds/worker/checkouts/gecko/xpcom/threads/TaskController.cpp:138:7'>::Run /builds/worker/checkouts/gecko/xpcom/threads/nsThreadUtils.h:534
#42 0x7ffd167e667f in nsThread::ProcessNextEvent /builds/worker/checkouts/gecko/xpcom/threads/nsThread.cpp:1159
#43 0x7ffd167f69ec in NS_ProcessNextEvent /builds/worker/checkouts/gecko/xpcom/threads/nsThreadUtils.cpp:548
#44 0x7ffd17aed25e in mozilla::ipc::MessagePump::Run /builds/worker/checkouts/gecko/ipc/glue/MessagePump.cpp:85
#45 0x7ffd17a272c5 in MessageLoop::RunHandler /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:328
#46 0x7ffd17a27095 in MessageLoop::Run /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:310
#47 0x7ffd1fb520da in nsBaseAppShell::Run /builds/worker/checkouts/gecko/widget/nsBaseAppShell.cpp:137
#48 0x7ffd1fd370fb in nsAppShell::Run /builds/worker/checkouts/gecko/widget/windows/nsAppShell.cpp:603
#49 0x7ffd2408a844 in XRE_RunAppShell /builds/worker/checkouts/gecko/toolkit/xre/nsEmbedFunctions.cpp:911
#50 0x7ffd17a272c5 in MessageLoop::RunHandler /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:328
#51 0x7ffd17a27095 in MessageLoop::Run /builds/worker/checkouts/gecko/ipc/chromium/src/base/message_loop.cc:310
#52 0x7ffd24089cbd in XRE_InitChildProcess /builds/worker/checkouts/gecko/toolkit/xre/nsEmbedFunctions.cpp:743
#53 0x7ff78e6c1f3d in NS_internal_main /builds/worker/checkouts/gecko/browser/app/nsBrowserApp.cpp:313
#54 0x7ff78e6c14d4 in wmain /builds/worker/checkouts/gecko/toolkit/xre/nsWindowsWMain.cpp:131
#55 0x7ff78e7bf2d7 in __scrt_common_main_seh f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:288
#56 0x7ffdbe077033 in BaseThreadInitThunk+0x13 (C:\Windows\System32\KERNEL32.DLL+0x180017033)
#57 0x7ffdbfbc2650 in RtlUserThreadStart+0x20 (C:\Windows\SYSTEM32\ntdll.dll+0x180052650)
0x129b11675970 is located 112 bytes inside of 5000-byte region [0x129b11675900,0x129b11676c88)
freed by thread T0 here:
#0 0x7ffd6d4d5afb in free Z:\task_1619604322\fetches\llvm-project\llvm\projects\compiler-rt\lib\asan\asan_malloc_win.cpp:82
#1 0x7ffd203921db in mozilla::PresShell::Release /builds/worker/checkouts/gecko/layout/base/PresShell.cpp:889
#2 0x7ffd204c9ad6 in nsDocumentViewer::DestroyPresShell /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:3572
#3 0x7ffd204c0d77 in nsDocumentViewer::Hide /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:2193
#4 0x7ffd27a60671 in XPTC__InvokebyIndex+0x71 (C:\Users\susah\git\grizzly-framework\browser\m-c-20210506214311-fuzzing-asan-opt\xul.dll+0x191630671)
#5 0x7ffd18808b6a in XPCWrappedNative::CallMethod /builds/worker/checkouts/gecko/js/xpconnect/src/XPCWrappedNative.cpp:1143
#6 0x7ffd1880f04a in XPC_WN_CallMethod /builds/worker/checkouts/gecko/js/xpconnect/src/XPCWrappedNativeJSOps.cpp:925
#7 0x7ffd24373705 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512
#8 0x7ffd2435fbbe in Interpret /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227
#9 0x7ffd2434569a in js::RunScript /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396
#10 0x7ffd243739f5 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544
#11 0x7ffd24376368 in js::Call /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589
#12 0x7ffd2485c596 in js::fun_apply /builds/worker/checkouts/gecko/js/src/vm/JSFunction.cpp:1150
#13 0x7ffd24373705 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512
#14 0x7ffd2435fbbe in Interpret /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227
#15 0x7ffd2434569a in js::RunScript /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396
#16 0x7ffd243739f5 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544
#17 0x7ffd24376368 in js::Call /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589
#18 0x7ffd24db97fb in JS::Call /builds/worker/checkouts/gecko/js/src/jsapi.cpp:2849
previously allocated by thread T0 here:
#0 0x7ffd6d4d5c0b in malloc Z:\task_1619604322\fetches\llvm-project\llvm\projects\compiler-rt\lib\asan\asan_malloc_win.cpp:98
#1 0x7ffd8fe6139d in moz_xmalloc /builds/worker/checkouts/gecko/memory/mozalloc/mozalloc.cpp:52
#2 0x7ffd1a123d69 in mozilla::dom::Document::CreatePresShell /builds/worker/checkouts/gecko/dom/base/Document.cpp:6600
#3 0x7ffd204bee13 in nsDocumentViewer::InitPresentationStuff /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:705
#4 0x7ffd204cc51d in nsDocumentViewer::Show /builds/worker/checkouts/gecko/layout/base/nsDocumentViewer.cpp:2131
#5 0x7ffd27a60671 in XPTC__InvokebyIndex+0x71 (C:\Users\susah\git\grizzly-framework\browser\m-c-20210506214311-fuzzing-asan-opt\xul.dll+0x191630671)
#6 0x7ffd18808b6a in XPCWrappedNative::CallMethod /builds/worker/checkouts/gecko/js/xpconnect/src/XPCWrappedNative.cpp:1143
#7 0x7ffd1880f04a in XPC_WN_CallMethod /builds/worker/checkouts/gecko/js/xpconnect/src/XPCWrappedNativeJSOps.cpp:925
#8 0x7ffd24373705 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512
#9 0x7ffd2435fbbe in Interpret /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227
#10 0x7ffd2434569a in js::RunScript /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396
#11 0x7ffd243739f5 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544
#12 0x7ffd24376368 in js::Call /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589
#13 0x7ffd2485c596 in js::fun_apply /builds/worker/checkouts/gecko/js/src/vm/JSFunction.cpp:1150
#14 0x7ffd24373705 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:512
#15 0x7ffd2435fbbe in Interpret /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:3227
#16 0x7ffd2434569a in js::RunScript /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:396
#17 0x7ffd243739f5 in js::InternalCallOrConstruct /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:544
#18 0x7ffd24376368 in js::Call /builds/worker/checkouts/gecko/js/src/vm/Interpreter.cpp:589
SUMMARY: AddressSanitizer: heap-use-after-free /builds/worker/checkouts/gecko/layout/base/PresShell.cpp:9914 in mozilla::PresShell::RemoveRefreshObserver
Shadow bytes around the buggy address:
0x04aa738cead0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceae0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceaf0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceb00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceb10: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
=>0x04aa738ceb20: fa fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]fa
0x04aa738ceb30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceb40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceb50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceb60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
0x04aa738ceb70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
Addressable: 00
Partially addressable: 01 02 03 04 05 06 07
Heap left redzone: fa
Freed heap region: fd
Stack left redzone: f1
Stack mid redzone: f2
Stack right redzone: f3
Stack after return: f5
Stack use after scope: f8
Global redzone: f9
Global init order: f6
Poisoned by user: f7
Container overflow: fc
Array cookie: ac
Intra object redzone: bb
ASan internal: fe
Left alloca redzone: ca
Right alloca redzone: cb
Shadow gap: cc
==3420==ABORTING
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the accessibility notification controller calls RemoveRefreshObserver on a PresShell whose pres context has already been freed during cycle collection.
Impact
The bug could crash the browser tab, but the report does not show remote code execution or any other impact beyond a denial of service.
What the attacker needed
Accessibility enabled; specific user interactions; cycle collection triggered
How it was found
- Enable accessibility using the fuzzing function.
- Perform a few interactions that trigger selection and attribute changes.
- Run a cycle collection, which frees the pres shell.
- The accessibility shutdown then calls RemoveRefreshObserver on the freed pres shell, causing the crash.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
A use-after-free is a memory bug where a program keeps using a piece of memory after it has been freed. In this case, Firefox's accessibility code tried to remove a refresh observer from a layout object that had already been destroyed, causing a crash. The report is from a fuzzing tool and the testcase is not yet stable.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.