Bug 268410
Summary: | Limit size of target string stored in serialized session state | ||
---|---|---|---|
Product: | WebKit | Reporter: | Ben Nham <nham> |
Component: | WebKit Misc. | Assignee: | Ben Nham <nham> |
Status: | RESOLVED FIXED | ||
Severity: | Normal | CC: | mcatanzaro, nham, webkit-bug-importer |
Priority: | P2 | Keywords: | InRadar |
Version: | WebKit Local Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
See Also: |
https://bugs.webkit.org/show_bug.cgi?id=264879 https://bugs.webkit.org/show_bug.cgi?id=289898 |
Ben Nham
We've seen some MobileSafari launches that take a long time during session restoration because the _WKSessionState object contains a back/forward list item with an absurdly large target string (like >500KB in size).
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Ben Nham
rdar://120213426
Ben Nham
Pull request: https://github.com/WebKit/WebKit/pull/23537
EWS
Committed 273810@main (624a3d6250ec): <https://commits.webkit.org/273810@main>
Reviewed commits have been landed. Closing PR #23537 and removing active labels.
Michael Catanzaro
This looks very similar to bug #264879, but unfortunately the patch that landed here is Mac-specific and therefore cannot help with that bug.
(In reply to Ben Nham from comment #0)
> We've seen some MobileSafari launches that take a long time during session
> restoration
I think this patch also doesn't help mobile Safari? It is a Mac-specific file, not a Cocoa file. It shouldn't be used on iOS. If it's used on iOS, then it's in the wrong location.
Ben Nham
> unfortunately the patch that landed here is Mac-specific and therefore cannot help with that bug
Despite the name of this file, it compiles on all Cocoa platforms.
Ben Nham
That said I think if you want a fix for GTK then you'll probably have to do a platform-specific change for now given the structure of the code at the moment.
For Cocoa, after looking at this some more, there are even more issues in the way this old code handles deserialization of >2MB session states. But we're going to fix that in the future. See https://bugs.webkit.org/show_bug.cgi?id=268994.
Michael Catanzaro
(In reply to Ben Nham from comment #5)
> Despite the name of this file, it compiles on all Cocoa platforms.
Well the file name is actually OK, just the location is not. It should move from Source/WebKit/UIProcess/mac to Source/WebKit/UIProcess/Cocoa. (Unfortunately moving files is hard without XCode, so I won't attempt this myself.)