[Site Isolation] Find-in-page scroll propagation through cross-site iframes
Component: WebKit Site Isolation | ab06c21
Source/WebKit/UIProcess/WebFrameProxy.cpp
Source/WebCore/page/LocalFrameView.cpp
FrameSelection::revealSelection() normally reveals a target by walking up through each <iframe> owner renderer, but a cross-site child under site isolation has no owner element in its own process, so the walk stopped at the child. Now, when a child's parent is a RemoteFrame, the child sends the rect (in its view coordinates) and a newly serialized ScrollRectToVisibleOptions to WebFrameProxy. The UI process checks that the named child's parent is the target proxy and forwards the request to the parent process. The parent converts the rect and scrolls from the owner renderer, and the relay repeats up to the main frame.
Significance
Find-in-page matches inside cross-site iframes now scroll the embedding page, at the cost of a new WebContent-to-UI-to-WebContent relay carrying renderer-controlled geometry and scroll options.
Audit directions
The UI-process check only confirms that childFrameID's parent is this proxy; it does not confirm the connection belongs to the process hosting that child, so a compromised process could name a sibling's frame ID. Look at how scrollRectToVisibleContinuingFromChildFrame() re-checks the relationship when frames detach, reparent, or move between processes mid-flight. Probe convertToContainingView(), viewToContents() and LayoutUnit conversions with extreme rects, and the new ScrollTypes.serialization.in entries for unchecked enums or optionals. scrollRectToVisible() can trigger layout and scroll events, so verify the owner element, the CheckedPtr renderer and the child view stay valid. The refactored scrollRectToVisibleInChildView() now accepts a null ownerElement, so confirm nothing else dereferences it unconditionally. Multi-hop propagation is asynchronous per hop, which opens questions about frame-tree changes between hops and message amplification.