Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 015edd6245b901e1e7cfe6ae8be82e2b0d782c80
https://github.com/WebKit/WebKit/commit/015edd6245b901e1e7cfe6ae8be82e2b0d782c80
Author: Matthew Finkel <[email protected]>
Date: 2023-08-14 (Mon, 14 Aug 2023)
Changed paths:
M Source/WebKit/NetworkProcess/NetworkProcess.cpp
M Source/WebKit/NetworkProcess/NetworkProcess.h
M Source/WebKit/NetworkProcess/NetworkProcess.messages.in
M Source/WebKit/UIProcess/PageLoadState.cpp
M Source/WebKit/UIProcess/PageLoadState.h
M Source/WebKit/UIProcess/WebPageProxy.cpp
M Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp
M Tools/TestWebKitAPI/Tests/WebKitCocoa/Download.mm
Log Message:
-----------
Store committed web page origin
https://bugs.webkit.org/show_bug.cgi?id=260048
rdar://problem/113720677
Reviewed by Alex Christensen.
In 266760@main I missed a path where we need to plumb the top
SecurityOriginData of a request for downloading. In this case, we are setting
firstPartyForCookies using the URL of the originating WebPage. We can't simply
obtain the SecurityOriginData from that URL because an equality check will fail
later if the document has an opaque origin. Instead, we save the frame's
SecurityOriginData when we commit the load and we use that later when we need
it in the download request.
This is already partially covered by existing tests, but this adds another
test, as well.
* Source/WebKit/NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::downloadRequest):
* Source/WebKit/NetworkProcess/NetworkProcess.h:
* Source/WebKit/NetworkProcess/NetworkProcess.messages.in:
* Source/WebKit/UIProcess/PageLoadState.cpp:
(WebKit::PageLoadState::reset):
(WebKit::PageLoadState::didCommitLoad):
* Source/WebKit/UIProcess/PageLoadState.h:
(WebKit::PageLoadState::origin const):
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didCommitLoadForFrame):
* Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::download):
* Tools/TestWebKitAPI/Tests/WebKitCocoa/Download.mm:
Canonical link: https://commits.webkit.org/266870@main
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes