Diff
Modified: branches/safari-609-branch/Source/WebCore/ChangeLog (256409 => 256410)
--- branches/safari-609-branch/Source/WebCore/ChangeLog 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebCore/ChangeLog 2020-02-12 01:00:08 UTC (rev 256410)
@@ -1,5 +1,87 @@
2020-02-11 Alan Coon <alanc...@apple.com>
+ Cherry-pick r256073. rdar://problem/59299148
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Patch by Alex Christensen <achristen...@apple.com> on 2020-02-07
+ Reviewed by Chris Dumez.
+
+ Source/WebCore:
+
+ Covered by an API test.
+
+ * history/CachedFrame.cpp:
+ (WebCore::CachedFrame::setHasInsecureContent):
+ * history/CachedFrame.h:
+ (WebCore::CachedFrame::usedLegacyTLS const):
+ * loader/EmptyFrameLoaderClient.h:
+ * loader/FrameLoader.cpp:
+ (WebCore::FrameLoader::receivedFirstData):
+ (WebCore::FrameLoader::commitProvisionalLoad):
+ (WebCore::FrameLoader::dispatchDidCommitLoad):
+ * loader/FrameLoader.h:
+ * loader/FrameLoaderClient.h:
+
+ Source/WebKit:
+
+ * Scripts/webkit/messages.py:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::hasInsecureContent):
+ * UIProcess/WebPageProxy.h:
+ * UIProcess/WebPageProxy.messages.in:
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
+ (WebKit::WebFrameLoaderClient::savePlatformDataToCachedFrame):
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+
+ Source/WebKitLegacy/mac:
+
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+
+ Source/WebKitLegacy/win:
+
+ * WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+ * WebCoreSupport/WebFrameLoaderClient.h:
+
+ Tools:
+
+ * TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm:
+ (TestWebKitAPI::TEST):
+
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@256073 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-02-07 Alex Christensen <achristen...@apple.com>
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Reviewed by Chris Dumez.
+
+ Covered by an API test.
+
+ * history/CachedFrame.cpp:
+ (WebCore::CachedFrame::setHasInsecureContent):
+ * history/CachedFrame.h:
+ (WebCore::CachedFrame::usedLegacyTLS const):
+ * loader/EmptyFrameLoaderClient.h:
+ * loader/FrameLoader.cpp:
+ (WebCore::FrameLoader::receivedFirstData):
+ (WebCore::FrameLoader::commitProvisionalLoad):
+ (WebCore::FrameLoader::dispatchDidCommitLoad):
+ * loader/FrameLoader.h:
+ * loader/FrameLoaderClient.h:
+
+2020-02-11 Alan Coon <alanc...@apple.com>
+
Cherry-pick r256060. rdar://problem/59298138
Captions sometimes render at the wrong size when in fullscreen and PiP
Modified: branches/safari-609-branch/Source/WebCore/history/CachedFrame.cpp (256409 => 256410)
--- branches/safari-609-branch/Source/WebCore/history/CachedFrame.cpp 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebCore/history/CachedFrame.cpp 2020-02-12 01:00:08 UTC (rev 256410)
@@ -302,9 +302,10 @@
return m_cachedFramePlatformData.get();
}
-void CachedFrame::setHasInsecureContent(HasInsecureContent hasInsecureContent)
+void CachedFrame::setHasInsecureContent(HasInsecureContent hasInsecureContent, UsedLegacyTLS usedLegacyTLS)
{
m_hasInsecureContent = hasInsecureContent;
+ m_usedLegacyTLS = usedLegacyTLS;
}
int CachedFrame::descendantFrameCount() const
Modified: branches/safari-609-branch/Source/WebCore/history/CachedFrame.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebCore/history/CachedFrame.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebCore/history/CachedFrame.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -39,6 +39,7 @@
class FrameView;
class Node;
enum class HasInsecureContent : bool;
+enum class UsedLegacyTLS : bool;
class CachedFrameBase {
public:
@@ -63,6 +64,7 @@
std::unique_ptr<CachedFramePlatformData> m_cachedFramePlatformData;
bool m_isMainFrame;
Optional<HasInsecureContent> m_hasInsecureContent;
+ Optional<UsedLegacyTLS> m_usedLegacyTLS;
Vector<std::unique_ptr<CachedFrame>> m_childFrames;
};
@@ -79,8 +81,9 @@
WEBCORE_EXPORT void setCachedFramePlatformData(std::unique_ptr<CachedFramePlatformData>);
WEBCORE_EXPORT CachedFramePlatformData* cachedFramePlatformData();
- WEBCORE_EXPORT void setHasInsecureContent(HasInsecureContent);
+ WEBCORE_EXPORT void setHasInsecureContent(HasInsecureContent, UsedLegacyTLS);
Optional<HasInsecureContent> hasInsecureContent() const { return m_hasInsecureContent; }
+ Optional<UsedLegacyTLS> usedLegacyTLS() const { return m_usedLegacyTLS; }
using CachedFrameBase::document;
using CachedFrameBase::view;
Modified: branches/safari-609-branch/Source/WebCore/loader/EmptyFrameLoaderClient.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebCore/loader/EmptyFrameLoaderClient.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebCore/loader/EmptyFrameLoaderClient.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -89,7 +89,7 @@
void dispatchWillClose() final { }
void dispatchDidStartProvisionalLoad() final { }
void dispatchDidReceiveTitle(const StringWithDirection&) final { }
- void dispatchDidCommitLoad(Optional<HasInsecureContent>) final { }
+ void dispatchDidCommitLoad(Optional<HasInsecureContent>, Optional<UsedLegacyTLS>) final { }
void dispatchDidFailProvisionalLoad(const ResourceError&, WillContinueLoading) final { }
void dispatchDidFailLoad(const ResourceError&) final { }
void dispatchDidFinishDocumentLoad() final { }
Modified: branches/safari-609-branch/Source/WebCore/loader/FrameLoader.cpp (256409 => 256410)
--- branches/safari-609-branch/Source/WebCore/loader/FrameLoader.cpp 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebCore/loader/FrameLoader.cpp 2020-02-12 01:00:08 UTC (rev 256410)
@@ -705,7 +705,7 @@
void FrameLoader::receivedFirstData()
{
- dispatchDidCommitLoad(WTF::nullopt);
+ dispatchDidCommitLoad(WTF::nullopt, WTF::nullopt);
dispatchDidClearWindowObjectsInAllWorlds();
dispatchGlobalObjectAvailableInAllWorlds();
@@ -2070,8 +2070,9 @@
notifier().dispatchDidReceiveResponse(cachedPage->documentLoader(), mainResourceIdentifier, cachedPage->documentLoader()->response());
Optional<HasInsecureContent> hasInsecureContent = cachedPage->cachedMainFrame()->hasInsecureContent();
+ Optional<UsedLegacyTLS> usedLegacyTLS = cachedPage->cachedMainFrame()->usedLegacyTLS();
- dispatchDidCommitLoad(hasInsecureContent);
+ dispatchDidCommitLoad(hasInsecureContent, usedLegacyTLS);
// FIXME: This API should be turned around so that we ground CachedPage into the Page.
cachedPage->restore(*m_frame.page());
@@ -4005,12 +4006,12 @@
#endif
}
-void FrameLoader::dispatchDidCommitLoad(Optional<HasInsecureContent> initialHasInsecureContent)
+void FrameLoader::dispatchDidCommitLoad(Optional<HasInsecureContent> initialHasInsecureContent, Optional<UsedLegacyTLS> initialUsedLegacyTLS)
{
if (m_stateMachine.creatingInitialEmptyDocument())
return;
- m_client.dispatchDidCommitLoad(initialHasInsecureContent);
+ m_client.dispatchDidCommitLoad(initialHasInsecureContent, initialUsedLegacyTLS);
if (m_frame.isMainFrame()) {
m_frame.page()->resetSeenPlugins();
Modified: branches/safari-609-branch/Source/WebCore/loader/FrameLoader.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebCore/loader/FrameLoader.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebCore/loader/FrameLoader.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -87,6 +87,7 @@
enum class NewLoadInProgress : bool;
enum class NavigationPolicyDecision : uint8_t;
enum class ShouldTreatAsContinuingLoad : bool;
+enum class UsedLegacyTLS : bool;
struct WindowFeatures;
@@ -377,7 +378,7 @@
bool shouldReloadToHandleUnreachableURL(DocumentLoader&);
- void dispatchDidCommitLoad(Optional<HasInsecureContent> initialHasInsecureContent);
+ void dispatchDidCommitLoad(Optional<HasInsecureContent> initialHasInsecureContent, Optional<UsedLegacyTLS> initialUsedLegacyTLS);
void urlSelected(FrameLoadRequest&&, Event*, Optional<AdClickAttribution>&& = WTF::nullopt);
Modified: branches/safari-609-branch/Source/WebCore/loader/FrameLoaderClient.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebCore/loader/FrameLoaderClient.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebCore/loader/FrameLoaderClient.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -102,6 +102,7 @@
enum class LockBackForwardList : bool;
enum class PolicyDecisionMode;
+enum class UsedLegacyTLS : bool;
struct StringWithDirection;
@@ -173,7 +174,7 @@
virtual void dispatchDidReceiveIcon() { }
virtual void dispatchDidStartProvisionalLoad() = 0;
virtual void dispatchDidReceiveTitle(const StringWithDirection&) = 0;
- virtual void dispatchDidCommitLoad(Optional<HasInsecureContent>) = 0;
+ virtual void dispatchDidCommitLoad(Optional<HasInsecureContent>, Optional<UsedLegacyTLS>) = 0;
virtual void dispatchDidFailProvisionalLoad(const ResourceError&, WillContinueLoading) = 0;
virtual void dispatchDidFailLoad(const ResourceError&) = 0;
virtual void dispatchDidFinishDocumentLoad() = 0;
Modified: branches/safari-609-branch/Source/WebKit/ChangeLog (256409 => 256410)
--- branches/safari-609-branch/Source/WebKit/ChangeLog 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKit/ChangeLog 2020-02-12 01:00:08 UTC (rev 256410)
@@ -1,5 +1,83 @@
2020-02-11 Alan Coon <alanc...@apple.com>
+ Cherry-pick r256073. rdar://problem/59299148
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Patch by Alex Christensen <achristen...@apple.com> on 2020-02-07
+ Reviewed by Chris Dumez.
+
+ Source/WebCore:
+
+ Covered by an API test.
+
+ * history/CachedFrame.cpp:
+ (WebCore::CachedFrame::setHasInsecureContent):
+ * history/CachedFrame.h:
+ (WebCore::CachedFrame::usedLegacyTLS const):
+ * loader/EmptyFrameLoaderClient.h:
+ * loader/FrameLoader.cpp:
+ (WebCore::FrameLoader::receivedFirstData):
+ (WebCore::FrameLoader::commitProvisionalLoad):
+ (WebCore::FrameLoader::dispatchDidCommitLoad):
+ * loader/FrameLoader.h:
+ * loader/FrameLoaderClient.h:
+
+ Source/WebKit:
+
+ * Scripts/webkit/messages.py:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::hasInsecureContent):
+ * UIProcess/WebPageProxy.h:
+ * UIProcess/WebPageProxy.messages.in:
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
+ (WebKit::WebFrameLoaderClient::savePlatformDataToCachedFrame):
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+
+ Source/WebKitLegacy/mac:
+
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+
+ Source/WebKitLegacy/win:
+
+ * WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+ * WebCoreSupport/WebFrameLoaderClient.h:
+
+ Tools:
+
+ * TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm:
+ (TestWebKitAPI::TEST):
+
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@256073 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-02-07 Alex Christensen <achristen...@apple.com>
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Reviewed by Chris Dumez.
+
+ * Scripts/webkit/messages.py:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::hasInsecureContent):
+ * UIProcess/WebPageProxy.h:
+ * UIProcess/WebPageProxy.messages.in:
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
+ (WebKit::WebFrameLoaderClient::savePlatformDataToCachedFrame):
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+
+2020-02-11 Alan Coon <alanc...@apple.com>
+
Cherry-pick r255992. rdar://problem/59298165
[WK2][iOS] Add WKWebviewConfiguration SPI to run client navigations at foreground priority, even if the view is background
Modified: branches/safari-609-branch/Source/WebKit/Scripts/webkit/messages.py (256409 => 256410)
--- branches/safari-609-branch/Source/WebKit/Scripts/webkit/messages.py 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKit/Scripts/webkit/messages.py 2020-02-12 01:00:08 UTC (rev 256410)
@@ -593,6 +593,7 @@
'WebCore::TextIndicatorData': ['<WebCore/TextIndicator.h>'],
'WebCore::ThirdPartyCookieBlockingMode': ['<WebCore/NetworkStorageSession.h>'],
'WebCore::FirstPartyWebsiteDataRemovalMode': ['<WebCore/NetworkStorageSession.h>'],
+ 'WebCore::UsedLegacyTLS': ['<WebCore/ResourceResponseBase.h>'],
'WebCore::ViewportAttributes': ['<WebCore/ViewportArguments.h>'],
'WebCore::WillContinueLoading': ['<WebCore/FrameLoaderTypes.h>'],
'WebCore::SelectionRect': ['"EditorState.h"'],
Modified: branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.cpp (256409 => 256410)
--- branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.cpp 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.cpp 2020-02-12 01:00:08 UTC (rev 256410)
@@ -4198,9 +4198,12 @@
m_pageLoadState.setNetworkRequestsInProgress(transaction, networkRequestsInProgress);
}
-void WebPageProxy::hasInsecureContent(CompletionHandler<void(WebCore::HasInsecureContent)>&& completionHandler)
+void WebPageProxy::hasInsecureContent(CompletionHandler<void(WebCore::HasInsecureContent, WebCore::UsedLegacyTLS)>&& completionHandler)
{
- completionHandler(m_pageLoadState.committedHasInsecureContent() ? HasInsecureContent::Yes : HasInsecureContent::No);
+ completionHandler(
+ m_pageLoadState.committedHasInsecureContent() ? HasInsecureContent::Yes : HasInsecureContent::No,
+ m_pageLoadState.hasNegotiatedLegacyTLS() ? UsedLegacyTLS::Yes : UsedLegacyTLS::No
+ );
}
void WebPageProxy::didDestroyNavigation(uint64_t navigationID)
Modified: branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -1725,7 +1725,7 @@
void didFinishProgress();
void setNetworkRequestsInProgress(bool);
- void hasInsecureContent(CompletionHandler<void(WebCore::HasInsecureContent)>&&);
+ void hasInsecureContent(CompletionHandler<void(WebCore::HasInsecureContent, WebCore::UsedLegacyTLS)>&&);
void didDestroyNavigation(uint64_t navigationID);
Modified: branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.messages.in (256409 => 256410)
--- branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.messages.in 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKit/UIProcess/WebPageProxy.messages.in 2020-02-12 01:00:08 UTC (rev 256410)
@@ -142,7 +142,7 @@
DidExplicitOpenForFrame(WebCore::FrameIdentifier frameID, URL url, String mimeType)
DidDestroyNavigation(uint64_t navigationID)
- HasInsecureContent() -> (enum:bool WebCore::HasInsecureContent hasInsecureContent) Synchronous
+ HasInsecureContent() -> (enum:bool WebCore::HasInsecureContent hasInsecureContent, enum:bool WebCore::UsedLegacyTLS usedLegacyTLS) Synchronous
MainFramePluginHandlesPageScaleGestureDidChange(bool mainFramePluginHandlesPageScaleGesture)
Modified: branches/safari-609-branch/Source/WebKit/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp (256409 => 256410)
--- branches/safari-609-branch/Source/WebKit/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKit/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp 2020-02-12 01:00:08 UTC (rev 256410)
@@ -545,7 +545,7 @@
webPage->send(Messages::WebPageProxy::DidReceiveTitleForFrame(m_frame->frameID(), truncatedTitle.string, UserData(WebProcess::singleton().transformObjectsToHandles(userData.get()).get())));
}
-void WebFrameLoaderClient::dispatchDidCommitLoad(Optional<HasInsecureContent> hasInsecureContent)
+void WebFrameLoaderClient::dispatchDidCommitLoad(Optional<HasInsecureContent> hasInsecureContent, Optional<UsedLegacyTLS> usedLegacyTLSFromPageCache)
{
WebPage* webPage = m_frame->page();
if (!webPage)
@@ -559,8 +559,12 @@
webPage->sandboxExtensionTracker().didCommitProvisionalLoad(m_frame);
+ bool usedLegacyTLS = documentLoader.response().usedLegacyTLS();
+ if (!usedLegacyTLS && usedLegacyTLSFromPageCache)
+ usedLegacyTLS = usedLegacyTLSFromPageCache == UsedLegacyTLS::Yes;
+
// Notify the UIProcess.
- webPage->send(Messages::WebPageProxy::DidCommitLoadForFrame(m_frame->frameID(), documentLoader.navigationID(), documentLoader.response().mimeType(), m_frameHasCustomContentProvider, static_cast<uint32_t>(m_frame->coreFrame()->loader().loadType()), valueOrCompute(documentLoader.response().certificateInfo(), [] { return CertificateInfo(); }), documentLoader.response().usedLegacyTLS(), m_frame->coreFrame()->document()->isPluginDocument(), hasInsecureContent, UserData(WebProcess::singleton().transformObjectsToHandles(userData.get()).get())));
+ webPage->send(Messages::WebPageProxy::DidCommitLoadForFrame(m_frame->frameID(), documentLoader.navigationID(), documentLoader.response().mimeType(), m_frameHasCustomContentProvider, static_cast<uint32_t>(m_frame->coreFrame()->loader().loadType()), valueOrCompute(documentLoader.response().certificateInfo(), [] { return CertificateInfo(); }), usedLegacyTLS, m_frame->coreFrame()->document()->isPluginDocument(), hasInsecureContent, UserData(WebProcess::singleton().transformObjectsToHandles(userData.get()).get())));
webPage->didCommitLoad(m_frame);
}
@@ -1467,8 +1471,9 @@
return;
HasInsecureContent hasInsecureContent;
- if (webPage->sendSync(Messages::WebPageProxy::HasInsecureContent(), Messages::WebPageProxy::HasInsecureContent::Reply(hasInsecureContent)))
- cachedFrame->setHasInsecureContent(hasInsecureContent);
+ UsedLegacyTLS usedLegacyTLS;
+ if (webPage->sendSync(Messages::WebPageProxy::HasInsecureContent(), Messages::WebPageProxy::HasInsecureContent::Reply(hasInsecureContent, usedLegacyTLS)))
+ cachedFrame->setHasInsecureContent(hasInsecureContent, usedLegacyTLS);
}
void WebFrameLoaderClient::transitionToCommittedFromCachedFrame(CachedFrame*)
Modified: branches/safari-609-branch/Source/WebKit/WebProcess/WebCoreSupport/WebFrameLoaderClient.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebKit/WebProcess/WebCoreSupport/WebFrameLoaderClient.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKit/WebProcess/WebCoreSupport/WebFrameLoaderClient.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -114,7 +114,7 @@
void dispatchWillClose() final;
void dispatchDidStartProvisionalLoad() final;
void dispatchDidReceiveTitle(const WebCore::StringWithDirection&) final;
- void dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>) final;
+ void dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>, Optional<WebCore::UsedLegacyTLS>) final;
void dispatchDidFailProvisionalLoad(const WebCore::ResourceError&, WebCore::WillContinueLoading) final;
void dispatchDidFailLoad(const WebCore::ResourceError&) final;
void dispatchDidFinishDocumentLoad() final;
Modified: branches/safari-609-branch/Source/WebKitLegacy/mac/ChangeLog (256409 => 256410)
--- branches/safari-609-branch/Source/WebKitLegacy/mac/ChangeLog 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKitLegacy/mac/ChangeLog 2020-02-12 01:00:08 UTC (rev 256410)
@@ -1,5 +1,77 @@
2020-02-11 Alan Coon <alanc...@apple.com>
+ Cherry-pick r256073. rdar://problem/59299148
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Patch by Alex Christensen <achristen...@apple.com> on 2020-02-07
+ Reviewed by Chris Dumez.
+
+ Source/WebCore:
+
+ Covered by an API test.
+
+ * history/CachedFrame.cpp:
+ (WebCore::CachedFrame::setHasInsecureContent):
+ * history/CachedFrame.h:
+ (WebCore::CachedFrame::usedLegacyTLS const):
+ * loader/EmptyFrameLoaderClient.h:
+ * loader/FrameLoader.cpp:
+ (WebCore::FrameLoader::receivedFirstData):
+ (WebCore::FrameLoader::commitProvisionalLoad):
+ (WebCore::FrameLoader::dispatchDidCommitLoad):
+ * loader/FrameLoader.h:
+ * loader/FrameLoaderClient.h:
+
+ Source/WebKit:
+
+ * Scripts/webkit/messages.py:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::hasInsecureContent):
+ * UIProcess/WebPageProxy.h:
+ * UIProcess/WebPageProxy.messages.in:
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
+ (WebKit::WebFrameLoaderClient::savePlatformDataToCachedFrame):
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+
+ Source/WebKitLegacy/mac:
+
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+
+ Source/WebKitLegacy/win:
+
+ * WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+ * WebCoreSupport/WebFrameLoaderClient.h:
+
+ Tools:
+
+ * TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm:
+ (TestWebKitAPI::TEST):
+
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@256073 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-02-07 Alex Christensen <achristen...@apple.com>
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Reviewed by Chris Dumez.
+
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+
+2020-02-11 Alan Coon <alanc...@apple.com>
+
Cherry-pick r255158. rdar://problem/59298137
Throttling requestAnimationFrame should be controlled by RenderingUpdateScheduler
Modified: branches/safari-609-branch/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -115,7 +115,7 @@
void dispatchWillClose() final;
void dispatchDidStartProvisionalLoad() final;
void dispatchDidReceiveTitle(const WebCore::StringWithDirection&) final;
- void dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>) final;
+ void dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>, Optional<WebCore::UsedLegacyTLS>) final;
void dispatchDidFailProvisionalLoad(const WebCore::ResourceError&, WebCore::WillContinueLoading) final;
void dispatchDidFailLoad(const WebCore::ResourceError&) final;
void dispatchDidFinishDocumentLoad() final;
Modified: branches/safari-609-branch/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm (256409 => 256410)
--- branches/safari-609-branch/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm 2020-02-12 01:00:08 UTC (rev 256410)
@@ -697,7 +697,7 @@
}
}
-void WebFrameLoaderClient::dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>)
+void WebFrameLoaderClient::dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>, Optional<WebCore::UsedLegacyTLS>)
{
// Tell the client we've committed this URL.
ASSERT([m_webFrame->_private->webFrameView documentView] != nil);
Modified: branches/safari-609-branch/Source/WebKitLegacy/win/ChangeLog (256409 => 256410)
--- branches/safari-609-branch/Source/WebKitLegacy/win/ChangeLog 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKitLegacy/win/ChangeLog 2020-02-12 01:00:08 UTC (rev 256410)
@@ -1,5 +1,77 @@
2020-02-11 Alan Coon <alanc...@apple.com>
+ Cherry-pick r256073. rdar://problem/59299148
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Patch by Alex Christensen <achristen...@apple.com> on 2020-02-07
+ Reviewed by Chris Dumez.
+
+ Source/WebCore:
+
+ Covered by an API test.
+
+ * history/CachedFrame.cpp:
+ (WebCore::CachedFrame::setHasInsecureContent):
+ * history/CachedFrame.h:
+ (WebCore::CachedFrame::usedLegacyTLS const):
+ * loader/EmptyFrameLoaderClient.h:
+ * loader/FrameLoader.cpp:
+ (WebCore::FrameLoader::receivedFirstData):
+ (WebCore::FrameLoader::commitProvisionalLoad):
+ (WebCore::FrameLoader::dispatchDidCommitLoad):
+ * loader/FrameLoader.h:
+ * loader/FrameLoaderClient.h:
+
+ Source/WebKit:
+
+ * Scripts/webkit/messages.py:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::hasInsecureContent):
+ * UIProcess/WebPageProxy.h:
+ * UIProcess/WebPageProxy.messages.in:
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
+ (WebKit::WebFrameLoaderClient::savePlatformDataToCachedFrame):
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+
+ Source/WebKitLegacy/mac:
+
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+
+ Source/WebKitLegacy/win:
+
+ * WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+ * WebCoreSupport/WebFrameLoaderClient.h:
+
+ Tools:
+
+ * TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm:
+ (TestWebKitAPI::TEST):
+
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@256073 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-02-07 Alex Christensen <achristen...@apple.com>
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Reviewed by Chris Dumez.
+
+ * WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+ * WebCoreSupport/WebFrameLoaderClient.h:
+
+2020-02-11 Alan Coon <alanc...@apple.com>
+
Cherry-pick r255158. rdar://problem/59298137
Throttling requestAnimationFrame should be controlled by RenderingUpdateScheduler
Modified: branches/safari-609-branch/Source/WebKitLegacy/win/WebCoreSupport/WebFrameLoaderClient.cpp (256409 => 256410)
--- branches/safari-609-branch/Source/WebKitLegacy/win/WebCoreSupport/WebFrameLoaderClient.cpp 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKitLegacy/win/WebCoreSupport/WebFrameLoaderClient.cpp 2020-02-12 01:00:08 UTC (rev 256410)
@@ -438,7 +438,7 @@
frameLoadDelegate->didReceiveTitle(webView, BString(title.string), m_webFrame);
}
-void WebFrameLoaderClient::dispatchDidCommitLoad(Optional<HasInsecureContent>)
+void WebFrameLoaderClient::dispatchDidCommitLoad(Optional<HasInsecureContent>, Optional<UsedLegacyTLS>)
{
WebView* webView = m_webFrame->webView();
COMPtr<IWebFrameLoadDelegate> frameLoadDelegate;
Modified: branches/safari-609-branch/Source/WebKitLegacy/win/WebCoreSupport/WebFrameLoaderClient.h (256409 => 256410)
--- branches/safari-609-branch/Source/WebKitLegacy/win/WebCoreSupport/WebFrameLoaderClient.h 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Source/WebKitLegacy/win/WebCoreSupport/WebFrameLoaderClient.h 2020-02-12 01:00:08 UTC (rev 256410)
@@ -92,7 +92,7 @@
void dispatchWillClose() override;
void dispatchDidStartProvisionalLoad() override;
void dispatchDidReceiveTitle(const WebCore::StringWithDirection&) override;
- void dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>) override;
+ void dispatchDidCommitLoad(Optional<WebCore::HasInsecureContent>, Optional<WebCore::UsedLegacyTLS>) override;
void dispatchDidFailProvisionalLoad(const WebCore::ResourceError&, WebCore::WillContinueLoading) override;
void dispatchDidFailLoad(const WebCore::ResourceError&) override;
void dispatchDidFinishDocumentLoad() override;
Modified: branches/safari-609-branch/Tools/ChangeLog (256409 => 256410)
--- branches/safari-609-branch/Tools/ChangeLog 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Tools/ChangeLog 2020-02-12 01:00:08 UTC (rev 256410)
@@ -1,5 +1,76 @@
2020-02-11 Alan Coon <alanc...@apple.com>
+ Cherry-pick r256073. rdar://problem/59299148
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Patch by Alex Christensen <achristen...@apple.com> on 2020-02-07
+ Reviewed by Chris Dumez.
+
+ Source/WebCore:
+
+ Covered by an API test.
+
+ * history/CachedFrame.cpp:
+ (WebCore::CachedFrame::setHasInsecureContent):
+ * history/CachedFrame.h:
+ (WebCore::CachedFrame::usedLegacyTLS const):
+ * loader/EmptyFrameLoaderClient.h:
+ * loader/FrameLoader.cpp:
+ (WebCore::FrameLoader::receivedFirstData):
+ (WebCore::FrameLoader::commitProvisionalLoad):
+ (WebCore::FrameLoader::dispatchDidCommitLoad):
+ * loader/FrameLoader.h:
+ * loader/FrameLoaderClient.h:
+
+ Source/WebKit:
+
+ * Scripts/webkit/messages.py:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::hasInsecureContent):
+ * UIProcess/WebPageProxy.h:
+ * UIProcess/WebPageProxy.messages.in:
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
+ (WebKit::WebFrameLoaderClient::savePlatformDataToCachedFrame):
+ * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+
+ Source/WebKitLegacy/mac:
+
+ * WebCoreSupport/WebFrameLoaderClient.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+
+ Source/WebKitLegacy/win:
+
+ * WebCoreSupport/WebFrameLoaderClient.cpp:
+ (WebFrameLoaderClient::dispatchDidCommitLoad):
+ * WebCoreSupport/WebFrameLoaderClient.h:
+
+ Tools:
+
+ * TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm:
+ (TestWebKitAPI::TEST):
+
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@256073 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-02-07 Alex Christensen <achristen...@apple.com>
+
+ Remember if we used legacy TLS in the back/forward cache like we remember if we have only secure content
+ https://bugs.webkit.org/show_bug.cgi?id=207409
+ rdar://problem/59275641
+
+ Reviewed by Chris Dumez.
+
+ * TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm:
+ (TestWebKitAPI::TEST):
+
+2020-02-11 Alan Coon <alanc...@apple.com>
+
Cherry-pick r255880. rdar://problem/59299151
Unreviewed, another build fix after r255846
Modified: branches/safari-609-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm (256409 => 256410)
--- branches/safari-609-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm 2020-02-12 01:00:02 UTC (rev 256409)
+++ branches/safari-609-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/TLSDeprecation.mm 2020-02-12 01:00:08 UTC (rev 256410)
@@ -312,7 +312,8 @@
}, HTTPServer::Protocol::HttpsWithLegacyTLS);
HTTPServer modernTLSServer({
- { "/", { makeString("<script>fetch('https://127.0.0.1:", static_cast<unsigned>(legacyTLSServer.port()), "/',{mode:'no-cors'})</script>") } }
+ { "/", { makeString("<script>fetch('https://127.0.0.1:", static_cast<unsigned>(legacyTLSServer.port()), "/',{mode:'no-cors'})</script>") } },
+ { "/pageWithoutSubresource", { "hello" }}
}, HTTPServer::Protocol::Https);
auto [webView, delegate] = webViewWithNavigationDelegate();
@@ -323,7 +324,16 @@
[webView loadRequest:modernTLSServer.request()];
while (![webView _negotiatedLegacyTLS])
[observer waitUntilNegotiatedLegacyTLSChanged];
+
+ EXPECT_TRUE([webView _negotiatedLegacyTLS]);
+ [webView loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"https://127.0.0.1:%d/pageWithoutSubresource", modernTLSServer.port()]]]];
+ [delegate waitForDidFinishNavigation];
+ EXPECT_FALSE([webView _negotiatedLegacyTLS]);
+ [webView goBack];
+ [delegate waitForDidFinishNavigation];
+ EXPECT_TRUE([webView _negotiatedLegacyTLS]);
+
[webView removeObserver:observer.get() forKeyPath:@"_negotiatedLegacyTLS"];
}