I'm afraid it looks like it requires somebody more experienced. This is what I've found so far:
I've logged places where the handlers are registered/removed and queried and other interesting places. It seems some service worker's requests are called from frame for which registration of the handler never happened.
The log immediately from start of the cefclient looks like this
- Code: Select all
23:15:36:740 [1016/231536.592:WARNING:policy_logger.cc(148)] :components\enterprise\browser\controller\chrome_browser_cloud_management_controller.cc(88) Could not create policy manager as CBCM is not enabled.
23:15:51:410 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 5
23:15:51:522 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 5
23:15:53:818 content::NavigationControllerImpl::NavigateWithoutEntry(const content::NavigationController::LoadURLParams &)
23:15:53:818 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 5
23:15:55:427 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 6
23:15:55:531 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:15:55:787 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:15:55:787 CefRequestContextHandlerMap::RemoveHandler(const content::GlobalRenderFrameHostId &): global_id.child_id = 5
23:15:56:036 CefRequestContextHandlerMap::RemoveHandler(const content::GlobalRenderFrameHostId &): global_id.child_id = 5
23:15:58:289 content::RenderFrameHostImpl::CreateChildFrame(int, mojo::PendingAssociatedRemote<content::mojom::Frame>, mojo::PendingReceiver<blink::mojom::BrowserInterfaceBroker>, mojo::StructPtr<blink::mojom::PolicyContainerBindParams>, mojo::PendingAssociatedReceiver<blink::mojom::AssociatedInterfaceProvider>, blink::mojom::TreeScopeType, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, bool, const blink::FramePolicy &, mojo::StructPtr<blink::mojom::FrameOwnerProperties>, blink::FrameOwnerElementType, __int64) child_id = 6
23:15:58:289 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 6
23:15:58:537 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:15:58:537 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:15:58:797 content::RenderFrameHostImpl::CreateChildFrame(int, mojo::PendingAssociatedRemote<content::mojom::Frame>, mojo::PendingReceiver<blink::mojom::BrowserInterfaceBroker>, mojo::StructPtr<blink::mojom::PolicyContainerBindParams>, mojo::PendingAssociatedReceiver<blink::mojom::AssociatedInterfaceProvider>, blink::mojom::TreeScopeType, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, bool, const blink::FramePolicy &, mojo::StructPtr<blink::mojom::FrameOwnerProperties>, blink::FrameOwnerElementType, __int64) child_id = 6
23:15:58:797 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 6
23:15:59:041 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:15:59:041 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:15:59:041 content::Navigator::OnBeginNavigation(content::FrameTreeNode *, mojo::StructPtr<blink::mojom::CommonNavigationParams>, mojo::StructPtr<blink::mojom::BeginNavigationParams>, scoped_refptr<network::SharedURLLoaderFactory>, mojo::PendingAssociatedRemote<content::mojom::NavigationClient>, scoped_refptr<content::PrefetchedSignedExchangeCache>, int, mojo::PendingReceiver<content::mojom::NavigationRendererCancellationListener>)
23:15:59:325 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 7
23:15:59:325 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 7
23:15:59:325 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 7
23:15:59:545 [1016/231559.328:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771078 [7,6]
23:15:59:545 content::Navigator::OnBeginNavigation(content::FrameTreeNode *, mojo::StructPtr<blink::mojom::CommonNavigationParams>, mojo::StructPtr<blink::mojom::BeginNavigationParams>, scoped_refptr<network::SharedURLLoaderFactory>, mojo::PendingAssociatedRemote<content::mojom::NavigationClient>, scoped_refptr<content::PrefetchedSignedExchangeCache>, int, mojo::PendingReceiver<content::mojom::NavigationRendererCancellationListener>)
23:15:59:545 content::RenderFrameHostImpl::CreateChildFrame(int, mojo::PendingAssociatedRemote<content::mojom::Frame>, mojo::PendingReceiver<blink::mojom::BrowserInterfaceBroker>, mojo::StructPtr<blink::mojom::PolicyContainerBindParams>, mojo::PendingAssociatedReceiver<blink::mojom::AssociatedInterfaceProvider>, blink::mojom::TreeScopeType, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, bool, const blink::FramePolicy &, mojo::StructPtr<blink::mojom::FrameOwnerProperties>, blink::FrameOwnerElementType, __int64) child_id = 6
23:15:59:815 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 6
23:15:59:815 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:15:59:815 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:16:00:102 content::Navigator::OnBeginNavigation(content::FrameTreeNode *, mojo::StructPtr<blink::mojom::CommonNavigationParams>, mojo::StructPtr<blink::mojom::BeginNavigationParams>, scoped_refptr<network::SharedURLLoaderFactory>, mojo::PendingAssociatedRemote<content::mojom::NavigationClient>, scoped_refptr<content::PrefetchedSignedExchangeCache>, int, mojo::PendingReceiver<content::mojom::NavigationRendererCancellationListener>)
23:16:00:102 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 7
23:16:00:102 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 7
23:16:00:288 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 7
23:16:00:288 content::Navigator::OnBeginNavigation(content::FrameTreeNode *, mojo::StructPtr<blink::mojom::CommonNavigationParams>, mojo::StructPtr<blink::mojom::BeginNavigationParams>, scoped_refptr<network::SharedURLLoaderFactory>, mojo::PendingAssociatedRemote<content::mojom::NavigationClient>, scoped_refptr<content::PrefetchedSignedExchangeCache>, int, mojo::PendingReceiver<content::mojom::NavigationRendererCancellationListener>)
23:16:00:547 CefRequestContextHandlerMap::GetHandler(const content::GlobalRenderFrameHostId &, bool): global_id.child_id = -1
23:16:00:547 [1016/231600.498:ERROR:cert_issuer_source_aia.cc(36)] Error parsing cert retrieved from AIA (as DER):
23:16:00:547 ERROR: Couldn't read tbsCertificate as SEQUENCE
23:16:00:547 ERROR: Failed parsing Certificate
23:16:00:547
23:16:00:790 CefRequestContextHandlerMap::GetHandler(const content::GlobalRenderFrameHostId &, bool): global_id.child_id = 8
23:16:01:041 content::RenderFrameHostImpl::CreateChildFrame(int, mojo::PendingAssociatedRemote<content::mojom::Frame>, mojo::PendingReceiver<blink::mojom::BrowserInterfaceBroker>, mojo::StructPtr<blink::mojom::PolicyContainerBindParams>, mojo::PendingAssociatedReceiver<blink::mojom::AssociatedInterfaceProvider>, blink::mojom::TreeScopeType, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, const std::__Cr::basic_string<char,std::__Cr::char_traits<char>,std::__Cr::allocator<char>> &, bool, const blink::FramePolicy &, mojo::StructPtr<blink::mojom::FrameOwnerProperties>, blink::FrameOwnerElementType, __int64) child_id = 6
23:16:01:041 content::RenderFrameHostImpl::RenderFrameCreated(void) child_id = 6
23:16:01:292 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:16:01:292 CefRequestContextHandlerMap::AddHandler(const content::GlobalRenderFrameHostId &, scoped_refptr<CefRequestContextHandler>): global_id.child_id = 6
23:16:01:292 [1016/231601.214:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771081 [7,9]
23:16:01:292 [1016/231601.215:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771081 [7,9]
23:16:01:292 [1016/231601.216:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771081 [7,9]
23:16:01:292 [1016/231601.216:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771081 [7,9]
23:16:01:292 [1016/231601.221:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771078 [7,6]
23:16:01:292 [1016/231601.222:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771078 [7,6]
23:16:01:292 [1016/231601.222:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771078 [7,6]
23:16:01:292 [1016/231601.223:WARNING:browser_info.cc(309)] Returning a speculative frame for 30064771078 [7,6]
23:16:01:539 CefRequestContextHandlerMap::GetHandler(const content::GlobalRenderFrameHostId &, bool): global_id.child_id = 8
23:16:01:793 CefRequestContextHandlerMap::RemoveHandler(const content::GlobalRenderFrameHostId &): global_id.child_id = 6
23:16:01:793 CefRequestContextHandlerMap::RemoveHandler(const content::GlobalRenderFrameHostId &): global_id.child_id = 6
....
...
...
Problematic requests have global_id.child_id = 8. I can see in the log, this ID was never registered before or after GetHandler(). Also after closing the app the RemoveHandler is never called for global_id.child_id = 8.
It seems like browser process is never notified about this child, but I don't know who is supposed to send the notification.