Title: [292431] trunk/Source/WebKit
Revision
292431
Author
achristen...@apple.com
Date
2022-04-05 15:16:44 -0700 (Tue, 05 Apr 2022)

Log Message

Revert r291598
https://bugs.webkit.org/show_bug.cgi?id=238842
<rdar://90677955>

Reviewed by Geoff Garen.

It caused some problems and needs further analysis.

* NetworkProcess/cocoa/NetworkSessionCocoa.mm:
(WebKit::NetworkSessionCocoa::createWebSocketTask):

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (292430 => 292431)


--- trunk/Source/WebKit/ChangeLog	2022-04-05 21:56:44 UTC (rev 292430)
+++ trunk/Source/WebKit/ChangeLog	2022-04-05 22:16:44 UTC (rev 292431)
@@ -1,3 +1,16 @@
+2022-04-05  Alex Christensen  <achristen...@webkit.org>
+
+        Revert r291598
+        https://bugs.webkit.org/show_bug.cgi?id=238842
+        <rdar://90677955>
+
+        Reviewed by Geoff Garen.
+
+        It caused some problems and needs further analysis.
+
+        * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
+        (WebKit::NetworkSessionCocoa::createWebSocketTask):
+
 2022-04-05  Commit Queue  <commit-qu...@webkit.org>
 
         Unreviewed, reverting r291821.

Modified: trunk/Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm (292430 => 292431)


--- trunk/Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm	2022-04-05 21:56:44 UTC (rev 292430)
+++ trunk/Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm	2022-04-05 22:16:44 UTC (rev 292431)
@@ -340,14 +340,6 @@
     RetainPtr<NSURLRequest> nsRequest = request.nsURLRequest(WebCore::HTTPBodyUpdatePolicy::UpdateHTTPBody);
     RetainPtr<NSMutableURLRequest> mutableRequest = adoptNS([nsRequest.get() mutableCopy]);
 
-    if (parameters.isMainFrameNavigation
-        || parameters.hadMainFrameMainResourcePrivateRelayed // This means it did not fail. FIXME: adjust names to reflect this.
-        || !parameters.topOrigin
-        || request.url().host() == parameters.topOrigin->host()) {
-        if ([mutableRequest respondsToSelector:@selector(_setPrivacyProxyFailClosedForUnreachableNonMainHosts:)])
-            [mutableRequest _setPrivacyProxyFailClosedForUnreachableNonMainHosts:YES];
-    }
-
 #if ENABLE(APP_PRIVACY_REPORT)
     mutableRequest.get().attribution = request.isAppInitiated() ? NSURLRequestAttributionDeveloper : NSURLRequestAttributionUser;
 #endif

Modified: trunk/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm (292430 => 292431)


--- trunk/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm	2022-04-05 21:56:44 UTC (rev 292430)
+++ trunk/Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm	2022-04-05 22:16:44 UTC (rev 292431)
@@ -1713,17 +1713,6 @@
     appPrivacyReportTestingData().didLoadAppInitiatedRequest(nsRequest.get().attribution == NSURLRequestAttributionDeveloper);
 #endif
 
-    // FIXME: This function can make up to 3 copies of a request.
-    // Reduce that to one if the protocol is null, the request isn't app initiated,
-    // or the main frame main resource was private relayed, then set all properties
-    // on the one copy.
-    if (hadMainFrameMainResourcePrivateRelayed || request.url().host() == clientOrigin.topOrigin.host) {
-        RetainPtr<NSMutableURLRequest> mutableRequest = adoptNS([nsRequest.get() mutableCopy]);
-        if ([mutableRequest respondsToSelector:@selector(_setPrivacyProxyFailClosedForUnreachableNonMainHosts:)])
-            [mutableRequest _setPrivacyProxyFailClosedForUnreachableNonMainHosts:YES];
-        nsRequest = WTFMove(mutableRequest);
-    }
-
     auto& sessionSet = sessionSetForPage(webPageProxyID);
     RetainPtr<NSURLSessionWebSocketTask> task = [sessionSet.sessionWithCredentialStorage.session webSocketTaskWithRequest:nsRequest.get()];
     
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to