Title: [293503] trunk/Source/WebCore
- Revision
- 293503
- Author
- [email protected]
- Date
- 2022-04-27 03:36:07 -0700 (Wed, 27 Apr 2022)
Log Message
<link rel=preconnect> always sends credentials to different-origin, ignoring crossorigin=anonymous
https://bugs.webkit.org/show_bug.cgi?id=239119
<rdar://problem/91643534>
Reviewed by John Wilander.
Update the check as per spec, step 5 of
https://html.spec.whatwg.org/multipage/links.html#link-type-preconnect
This is difficult to test as preconnect can only expose TLS credentials.
* loader/LinkLoader.cpp:
(WebCore::LinkLoader::preconnectIfNeeded):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (293502 => 293503)
--- trunk/Source/WebCore/ChangeLog 2022-04-27 09:10:04 UTC (rev 293502)
+++ trunk/Source/WebCore/ChangeLog 2022-04-27 10:36:07 UTC (rev 293503)
@@ -1,5 +1,21 @@
2022-04-27 Youenn Fablet <[email protected]>
+ <link rel=preconnect> always sends credentials to different-origin, ignoring crossorigin=anonymous
+ https://bugs.webkit.org/show_bug.cgi?id=239119
+ <rdar://problem/91643534>
+
+ Reviewed by John Wilander.
+
+ Update the check as per spec, step 5 of
+ https://html.spec.whatwg.org/multipage/links.html#link-type-preconnect
+
+ This is difficult to test as preconnect can only expose TLS credentials.
+
+ * loader/LinkLoader.cpp:
+ (WebCore::LinkLoader::preconnectIfNeeded):
+
+2022-04-27 Youenn Fablet <[email protected]>
+
Add testRunner API to clear memory cache
https://bugs.webkit.org/show_bug.cgi?id=239804
rdar://92033309
Modified: trunk/Source/WebCore/loader/LinkLoader.cpp (293502 => 293503)
--- trunk/Source/WebCore/loader/LinkLoader.cpp 2022-04-27 09:10:04 UTC (rev 293502)
+++ trunk/Source/WebCore/loader/LinkLoader.cpp 2022-04-27 10:36:07 UTC (rev 293503)
@@ -214,7 +214,7 @@
return;
ASSERT(document.settings().linkPreconnectEnabled());
StoredCredentialsPolicy storageCredentialsPolicy = StoredCredentialsPolicy::Use;
- if (equalLettersIgnoringASCIICase(params.crossOrigin, "anonymous"_s) && document.securityOrigin().isSameOriginDomain(SecurityOrigin::create(href)))
+ if (equalLettersIgnoringASCIICase(params.crossOrigin, "anonymous"_s) && !document.securityOrigin().isSameOriginDomain(SecurityOrigin::create(href)))
storageCredentialsPolicy = StoredCredentialsPolicy::DoNotUse;
ASSERT(document.frame()->loader().networkingContext());
platformStrategies()->loaderStrategy()->preconnectTo(document.frame()->loader(), href, storageCredentialsPolicy, LoaderStrategy::ShouldPreconnectAsFirstParty::No, [weakDocument = WeakPtr { document }, href](ResourceError error) {
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes