Title: [196461] trunk/Source/WebKit2
Revision
196461
Author
[email protected]
Date
2016-02-11 17:30:45 -0800 (Thu, 11 Feb 2016)

Log Message

Unreviewed, rolling out r196453.
https://bugs.webkit.org/show_bug.cgi?id=154142

This change broke internal iOS builds (Requested by ryanhaddad
on #webkit).

Reverted changeset:

"Move Download authentication code to AuthenticationManager"
https://bugs.webkit.org/show_bug.cgi?id=154132
http://trac.webkit.org/changeset/196453

Patch by Commit Queue <[email protected]> on 2016-02-11

Modified Paths

Removed Paths

  • trunk/Source/WebKit2/Shared/Authentication/cocoa/
  • trunk/Source/WebKit2/Shared/Authentication/soup/

Diff

Modified: trunk/Source/WebKit2/ChangeLog (196460 => 196461)


--- trunk/Source/WebKit2/ChangeLog	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/ChangeLog	2016-02-12 01:30:45 UTC (rev 196461)
@@ -1,3 +1,17 @@
+2016-02-11  Commit Queue  <[email protected]>
+
+        Unreviewed, rolling out r196453.
+        https://bugs.webkit.org/show_bug.cgi?id=154142
+
+        This change broke internal iOS builds (Requested by ryanhaddad
+        on #webkit).
+
+        Reverted changeset:
+
+        "Move Download authentication code to AuthenticationManager"
+        https://bugs.webkit.org/show_bug.cgi?id=154132
+        http://trac.webkit.org/changeset/196453
+
 2016-02-11  Anders Carlsson  <[email protected]>
 
         Use the system PluginProcess.app for generating plug-in MIME type preferences

Modified: trunk/Source/WebKit2/NetworkProcess/Downloads/Download.h (196460 => 196461)


--- trunk/Source/WebKit2/NetworkProcess/Downloads/Download.h	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/NetworkProcess/Downloads/Download.h	2016-02-12 01:30:45 UTC (rev 196461)
@@ -113,6 +113,19 @@
     DownloadAuthenticationClient* authenticationClient();
 #endif
 
+#if !USE(NETWORK_SESSION)
+    // Authentication
+    static void receivedCredential(const WebCore::AuthenticationChallenge&, const WebCore::Credential&);
+    static void receivedRequestToContinueWithoutCredential(const WebCore::AuthenticationChallenge&);
+    static void receivedCancellation(const WebCore::AuthenticationChallenge&);
+    static void receivedRequestToPerformDefaultHandling(const WebCore::AuthenticationChallenge&);
+    static void receivedChallengeRejection(const WebCore::AuthenticationChallenge&);
+
+    void useCredential(const WebCore::AuthenticationChallenge&, const WebCore::Credential&);
+    void continueWithoutCredential(const WebCore::AuthenticationChallenge&);
+    void cancelAuthenticationChallenge(const WebCore::AuthenticationChallenge&);
+#endif
+
 private:
     // IPC::MessageSender
     virtual IPC::Connection* messageSenderConnection() override;

Modified: trunk/Source/WebKit2/NetworkProcess/Downloads/ios/DownloadIOS.mm (196460 => 196461)


--- trunk/Source/WebKit2/NetworkProcess/Downloads/ios/DownloadIOS.mm	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/NetworkProcess/Downloads/ios/DownloadIOS.mm	2016-02-12 01:30:45 UTC (rev 196461)
@@ -157,6 +157,31 @@
     notImplemented();
 }
 
+void Download::receivedCredential(const AuthenticationChallenge&, const Credential&)
+{
+    notImplemented();
+}
+
+void Download::receivedRequestToContinueWithoutCredential(const AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
+void Download::receivedCancellation(const AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
+void Download::receivedRequestToPerformDefaultHandling(const WebCore::AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
+void Download::receivedChallengeRejection(const WebCore::AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
 } // namespace WebKit
 
 #endif // USE(CFNETWORK) && !USE(NETWORK_SESSION)

Modified: trunk/Source/WebKit2/NetworkProcess/Downloads/mac/DownloadMac.mm (196460 => 196461)


--- trunk/Source/WebKit2/NetworkProcess/Downloads/mac/DownloadMac.mm	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/NetworkProcess/Downloads/mac/DownloadMac.mm	2016-02-12 01:30:45 UTC (rev 196461)
@@ -131,6 +131,31 @@
 {
 }
 
+void Download::receivedCredential(const AuthenticationChallenge& authenticationChallenge, const Credential& credential)
+{
+    [authenticationChallenge.sender() useCredential:credential.nsCredential() forAuthenticationChallenge:authenticationChallenge.nsURLAuthenticationChallenge()];
+}
+
+void Download::receivedRequestToContinueWithoutCredential(const AuthenticationChallenge& authenticationChallenge)
+{
+    [authenticationChallenge.sender() continueWithoutCredentialForAuthenticationChallenge:authenticationChallenge.nsURLAuthenticationChallenge()];
+}
+
+void Download::receivedCancellation(const AuthenticationChallenge& authenticationChallenge)
+{
+    [authenticationChallenge.sender() cancelAuthenticationChallenge:authenticationChallenge.nsURLAuthenticationChallenge()];
+}
+
+void Download::receivedRequestToPerformDefaultHandling(const AuthenticationChallenge& authenticationChallenge)
+{
+    [authenticationChallenge.sender() performDefaultHandlingForAuthenticationChallenge:authenticationChallenge.nsURLAuthenticationChallenge()];
+}
+
+void Download::receivedChallengeRejection(const AuthenticationChallenge& authenticationChallenge)
+{
+    [authenticationChallenge.sender() rejectProtectionSpaceAndContinueWithChallenge:authenticationChallenge.nsURLAuthenticationChallenge()];
+}
+
 } // namespace WebKit
 
 @implementation WKDownloadAsDelegate

Modified: trunk/Source/WebKit2/NetworkProcess/Downloads/soup/DownloadSoup.cpp (196460 => 196461)


--- trunk/Source/WebKit2/NetworkProcess/Downloads/soup/DownloadSoup.cpp	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/NetworkProcess/Downloads/soup/DownloadSoup.cpp	2016-02-12 01:30:45 UTC (rev 196461)
@@ -269,4 +269,44 @@
     m_resourceHandle = nullptr;
 }
 
+void Download::receivedCredential(const AuthenticationChallenge&, const Credential&)
+{
+    notImplemented();
+}
+
+void Download::receivedRequestToContinueWithoutCredential(const AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
+void Download::receivedCancellation(const AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
+void Download::continueWithoutCredential(const AuthenticationChallenge &)
+{
+    notImplemented();
+}
+
+void Download::useCredential(const AuthenticationChallenge&, const Credential&)
+{
+    notImplemented();
+}
+
+void Download::cancelAuthenticationChallenge(const AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
+void Download::receivedRequestToPerformDefaultHandling(const AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
+void Download::receivedChallengeRejection(const AuthenticationChallenge&)
+{
+    notImplemented();
+}
+
 } // namespace WebKit

Modified: trunk/Source/WebKit2/PlatformEfl.cmake (196460 => 196461)


--- trunk/Source/WebKit2/PlatformEfl.cmake	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/PlatformEfl.cmake	2016-02-12 01:30:45 UTC (rev 196461)
@@ -29,8 +29,6 @@
 
     Shared/API/c/efl/WKArrayEfl.cpp
 
-    Shared/Authentication/soup/AuthenticationManagerSoup.cpp
-
     Shared/CoordinatedGraphics/CoordinatedBackingStore.cpp
     Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp
     Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp

Modified: trunk/Source/WebKit2/PlatformGTK.cmake (196460 => 196461)


--- trunk/Source/WebKit2/PlatformGTK.cmake	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/PlatformGTK.cmake	2016-02-12 01:30:45 UTC (rev 196461)
@@ -57,8 +57,6 @@
 
     Shared/API/c/cairo/WKImageCairo.cpp
 
-    Shared/Authentication/soup/AuthenticationManagerSoup.cpp
-
     Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp
 
     Shared/Plugins/unix/PluginSearchPath.cpp

Modified: trunk/Source/WebKit2/PlatformMac.cmake (196460 => 196461)


--- trunk/Source/WebKit2/PlatformMac.cmake	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/PlatformMac.cmake	2016-02-12 01:30:45 UTC (rev 196461)
@@ -54,8 +54,6 @@
     Shared/APIWebArchive.mm
     Shared/APIWebArchiveResource.mm
 
-    Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm
-
     Shared/API/Cocoa/RemoteObjectInvocation.mm
     Shared/API/Cocoa/RemoteObjectRegistry.mm
     Shared/API/Cocoa/WKBrowsingContextHandle.mm

Modified: trunk/Source/WebKit2/Shared/Authentication/AuthenticationManager.cpp (196460 => 196461)


--- trunk/Source/WebKit2/Shared/Authentication/AuthenticationManager.cpp	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/Shared/Authentication/AuthenticationManager.cpp	2016-02-12 01:30:45 UTC (rev 196461)
@@ -116,7 +116,7 @@
     auto pageID = frame->page()->pageID();
     uint64_t challengeID = addChallengeToChallengeMap({pageID, authenticationChallenge
 #if USE(NETWORK_SESSION)
-        , { }
+        , ChallengeCompletionHandler()
 #endif
     });
 
@@ -161,7 +161,7 @@
 
     uint64_t challengeID = addChallengeToChallengeMap({pageID, authenticationChallenge
 #if USE(NETWORK_SESSION)
-        , { }
+        , ChallengeCompletionHandler()
 #endif
     });
 
@@ -219,12 +219,17 @@
         challenge.completionHandler(AuthenticationChallengeDisposition::UseCredential, credential);
         return;
     }
+#else
+    if (!coreClient) {
+        // FIXME: The authentication client is null for downloads, but it can also be null for canceled loads.
+        // We should not call Download::receivedCredential in the latter case.
+        Download::receivedCredential(challenge.challenge, credential);
+        return;
+    }
 #endif
 
-    if (coreClient)
-        coreClient->receivedCredential(challenge.challenge, credential);
-    else
-        receivedCredential(challenge.challenge, credential);
+    ASSERT(coreClient);
+    coreClient->receivedCredential(challenge.challenge, credential);
 }
 
 void AuthenticationManager::continueWithoutCredentialForChallenge(uint64_t challengeID)
@@ -247,12 +252,17 @@
         challenge.completionHandler(AuthenticationChallengeDisposition::UseCredential, Credential());
         return;
     }
+#else
+    if (!coreClient) {
+        // FIXME: The authentication client is null for downloads, but it can also be null for canceled loads.
+        // We should not call Download::receivedCredential in the latter case.
+        Download::receivedRequestToContinueWithoutCredential(challenge.challenge);
+        return;
+    }
 #endif
 
-    if (coreClient)
-        coreClient->receivedRequestToContinueWithoutCredential(challenge.challenge);
-    else
-        receivedRequestToContinueWithoutCredential(challenge.challenge);
+    ASSERT(coreClient);
+    coreClient->receivedRequestToContinueWithoutCredential(challenge.challenge);
 }
 
 void AuthenticationManager::cancelChallenge(uint64_t challengeID)
@@ -275,12 +285,17 @@
         challenge.completionHandler(AuthenticationChallengeDisposition::Cancel, Credential());
         return;
     }
+#else
+    if (!coreClient) {
+        // FIXME: The authentication client is null for downloads, but it can also be null for canceled loads.
+        // We should not call Download::receivedCredential in the latter case.
+        Download::receivedCancellation(challenge.challenge);
+        return;
+    }
 #endif
 
-    if (coreClient)
-        coreClient->receivedCancellation(challenge.challenge);
-    else
-        receivedCancellation(challenge.challenge);
+    ASSERT(coreClient);
+    coreClient->receivedCancellation(challenge.challenge);
 }
 
 void AuthenticationManager::performDefaultHandling(uint64_t challengeID)
@@ -303,12 +318,17 @@
         challenge.completionHandler(AuthenticationChallengeDisposition::PerformDefaultHandling, Credential());
         return;
     }
+#else
+    if (!coreClient) {
+        // FIXME: The authentication client is null for downloads, but it can also be null for canceled loads.
+        // We should not call Download::receivedCredential in the latter case.
+        Download::receivedRequestToPerformDefaultHandling(challenge.challenge);
+        return;
+    }
 #endif
 
-    if (coreClient)
-        coreClient->receivedRequestToPerformDefaultHandling(challenge.challenge);
-    else
-        receivedRequestToPerformDefaultHandling(challenge.challenge);
+    ASSERT(coreClient);
+    coreClient->receivedRequestToPerformDefaultHandling(challenge.challenge);
 }
 
 void AuthenticationManager::rejectProtectionSpaceAndContinue(uint64_t challengeID)
@@ -331,12 +351,17 @@
         challenge.completionHandler(AuthenticationChallengeDisposition::RejectProtectionSpace, Credential());
         return;
     }
+#else
+    if (!coreClient) {
+        // FIXME: The authentication client is null for downloads, but it can also be null for canceled loads.
+        // We should not call Download::receivedCredential in the latter case.
+        Download::receivedChallengeRejection(challenge.challenge);
+        return;
+    }
 #endif
 
-    if (coreClient)
-        coreClient->receivedChallengeRejection(challenge.challenge);
-    else
-        receivedChallengeRejection(challenge.challenge);
+    ASSERT(coreClient);
+    coreClient->receivedChallengeRejection(challenge.challenge);
 }
 
 } // namespace WebKit

Modified: trunk/Source/WebKit2/Shared/Authentication/AuthenticationManager.h (196460 => 196461)


--- trunk/Source/WebKit2/Shared/Authentication/AuthenticationManager.h	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/Shared/Authentication/AuthenticationManager.h	2016-02-12 01:30:45 UTC (rev 196461)
@@ -76,12 +76,6 @@
 
     uint64_t outstandingAuthenticationChallengeCount() const { return m_challenges.size(); }
 
-    static void receivedCredential(const WebCore::AuthenticationChallenge&, const WebCore::Credential&);
-    static void receivedRequestToContinueWithoutCredential(const WebCore::AuthenticationChallenge&);
-    static void receivedCancellation(const WebCore::AuthenticationChallenge&);
-    static void receivedRequestToPerformDefaultHandling(const WebCore::AuthenticationChallenge&);
-    static void receivedChallengeRejection(const WebCore::AuthenticationChallenge&);
-
 private:
     struct Challenge {
         uint64_t pageID;

Modified: trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj (196460 => 196461)


--- trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj	2016-02-12 01:05:48 UTC (rev 196460)
+++ trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj	2016-02-12 01:30:45 UTC (rev 196461)
@@ -1039,7 +1039,6 @@
 		52D5A1B01C57495A00DE34A3 /* WebVideoFullscreenManagerProxy.h in Headers */ = {isa = PBXBuildFile; fileRef = 52D5A1AA1C57494E00DE34A3 /* WebVideoFullscreenManagerProxy.h */; };
 		52D5A1B11C57496200DE34A3 /* WebVideoFullscreenManagerProxy.mm in Sources */ = {isa = PBXBuildFile; fileRef = 52D5A1AC1C57494E00DE34A3 /* WebVideoFullscreenManagerProxy.mm */; };
 		52D5A1B71C574A0200DE34A3 /* WebVideoFullscreenManager.mm in Sources */ = {isa = PBXBuildFile; fileRef = 52D5A1B41C5749F200DE34A3 /* WebVideoFullscreenManager.mm */; };
-		5C052F261C6D3BD30076E919 /* AuthenticationManagerCocoa.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5C052F241C6D3AB60076E919 /* AuthenticationManagerCocoa.mm */; };
 		5C1426EC1C23F80900D41183 /* NetworkProcessCreationParameters.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5C1426E21C23F80500D41183 /* NetworkProcessCreationParameters.cpp */; };
 		5C1426ED1C23F80900D41183 /* NetworkProcessCreationParameters.h in Headers */ = {isa = PBXBuildFile; fileRef = 5C1426E31C23F80500D41183 /* NetworkProcessCreationParameters.h */; };
 		5C1426EE1C23F80900D41183 /* NetworkProcessSupplement.h in Headers */ = {isa = PBXBuildFile; fileRef = 5C1426E41C23F80500D41183 /* NetworkProcessSupplement.h */; };
@@ -3131,7 +3130,6 @@
 		52D5A1B21C5749F200DE34A3 /* WebVideoFullscreenManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebVideoFullscreenManager.h; sourceTree = "<group>"; };
 		52D5A1B31C5749F200DE34A3 /* WebVideoFullscreenManager.messages.in */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = WebVideoFullscreenManager.messages.in; sourceTree = "<group>"; };
 		52D5A1B41C5749F200DE34A3 /* WebVideoFullscreenManager.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebVideoFullscreenManager.mm; sourceTree = "<group>"; };
-		5C052F241C6D3AB60076E919 /* AuthenticationManagerCocoa.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = AuthenticationManagerCocoa.mm; path = Authentication/cocoa/AuthenticationManagerCocoa.mm; sourceTree = "<group>"; };
 		5C1426E21C23F80500D41183 /* NetworkProcessCreationParameters.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = NetworkProcessCreationParameters.cpp; path = NetworkProcess/NetworkProcessCreationParameters.cpp; sourceTree = "<group>"; };
 		5C1426E31C23F80500D41183 /* NetworkProcessCreationParameters.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = NetworkProcessCreationParameters.h; path = NetworkProcess/NetworkProcessCreationParameters.h; sourceTree = "<group>"; };
 		5C1426E41C23F80500D41183 /* NetworkProcessSupplement.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = NetworkProcessSupplement.h; path = NetworkProcess/NetworkProcessSupplement.h; sourceTree = "<group>"; };
@@ -5533,7 +5531,6 @@
 		518E8EF116B208F000E91429 /* Authentication */ = {
 			isa = PBXGroup;
 			children = (
-				5C052F231C6D3AA10076E919 /* cocoa */,
 				518E8EF616B2091C00E91429 /* mac */,
 				518E8EF316B2091C00E91429 /* AuthenticationManager.cpp */,
 				518E8EF416B2091C00E91429 /* AuthenticationManager.h */,
@@ -5652,14 +5649,6 @@
 			name = IconDatabase;
 			sourceTree = "<group>";
 		};
-		5C052F231C6D3AA10076E919 /* cocoa */ = {
-			isa = PBXGroup;
-			children = (
-				5C052F241C6D3AB60076E919 /* AuthenticationManagerCocoa.mm */,
-			);
-			name = cocoa;
-			sourceTree = "<group>";
-		};
 		5C1426F11C23F81700D41183 /* Downloads */ = {
 			isa = PBXGroup;
 			children = (
@@ -9251,7 +9240,6 @@
 				BC8ACA1416670D89004C1941 /* ObjCObjectGraph.mm in Sources */,
 				BCCF673312C7F15C008F9C35 /* OriginAndDatabases.cpp in Sources */,
 				7C387434172F5615001BD88A /* PageBanner.cpp in Sources */,
-				5C052F261C6D3BD30076E919 /* AuthenticationManagerCocoa.mm in Sources */,
 				7C6D37FC172F555F009D2847 /* PageBannerMac.mm in Sources */,
 				0FCB4E6318BBE3D9000FCFC9 /* PageClientImpl.mm in Sources */,
 				0FCB4E4718BBE044000FCFC9 /* PageClientImplIOS.mm in Sources */,
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to