Title: [282048] trunk/Source/WebKit
Revision
282048
Author
[email protected]
Date
2021-09-05 10:03:42 -0700 (Sun, 05 Sep 2021)

Log Message

Use a strongly typed identifier for authentication challenge IDs
https://bugs.webkit.org/show_bug.cgi?id=229890

Reviewed by Anders Carlsson.

Add AuthenticationChallengeIdentifier and use it to replace uint64_t values that
represent authentication challenge identifiers.

* Scripts/webkit/messages.py:
(types_that_cannot_be_forward_declared):
(headers_for_type):
* Shared/Authentication/AuthenticationManager.cpp:
(WebKit::AuthenticationManager::addChallengeToChallengeMap):
(WebKit::AuthenticationManager::shouldCoalesceChallenge const):
(WebKit::AuthenticationManager::coalesceChallengesMatching const):
(WebKit::AuthenticationManager::didReceiveAuthenticationChallenge):
(WebKit::AuthenticationManager::completeAuthenticationChallenge):
(WebKit::generateAuthenticationChallengeID): Deleted.
* Shared/Authentication/AuthenticationManager.h:
* Shared/Authentication/AuthenticationManager.messages.in:
* Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm:
(WebKit::AuthenticationManager::initializeConnection):
* Shared/IdentifierTypes.h:
* UIProcess/Authentication/AuthenticationChallengeProxy.cpp:
(WebKit::AuthenticationChallengeProxy::AuthenticationChallengeProxy):
* UIProcess/Authentication/AuthenticationChallengeProxy.h:
(WebKit::AuthenticationChallengeProxy::create):
* UIProcess/Authentication/cocoa/AuthenticationChallengeProxyCocoa.mm:
(WebKit::AuthenticationChallengeProxy::sendClientCertificateCredentialOverXpc):
* UIProcess/Downloads/DownloadProxy.cpp:
(WebKit::DownloadProxy::didReceiveAuthenticationChallenge):
* UIProcess/Downloads/DownloadProxy.h:
* UIProcess/Downloads/DownloadProxy.messages.in:
* UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::didReceiveAuthenticationChallenge):
* UIProcess/Network/NetworkProcessProxy.h:
* UIProcess/Network/NetworkProcessProxy.messages.in:

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (282047 => 282048)


--- trunk/Source/WebKit/ChangeLog	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/ChangeLog	2021-09-05 17:03:42 UTC (rev 282048)
@@ -1,3 +1,43 @@
+2021-09-05  Simon Fraser  <[email protected]>
+
+        Use a strongly typed identifier for authentication challenge IDs
+        https://bugs.webkit.org/show_bug.cgi?id=229890
+
+        Reviewed by Anders Carlsson.
+
+        Add AuthenticationChallengeIdentifier and use it to replace uint64_t values that
+        represent authentication challenge identifiers.
+
+        * Scripts/webkit/messages.py:
+        (types_that_cannot_be_forward_declared):
+        (headers_for_type):
+        * Shared/Authentication/AuthenticationManager.cpp:
+        (WebKit::AuthenticationManager::addChallengeToChallengeMap):
+        (WebKit::AuthenticationManager::shouldCoalesceChallenge const):
+        (WebKit::AuthenticationManager::coalesceChallengesMatching const):
+        (WebKit::AuthenticationManager::didReceiveAuthenticationChallenge):
+        (WebKit::AuthenticationManager::completeAuthenticationChallenge):
+        (WebKit::generateAuthenticationChallengeID): Deleted.
+        * Shared/Authentication/AuthenticationManager.h:
+        * Shared/Authentication/AuthenticationManager.messages.in:
+        * Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm:
+        (WebKit::AuthenticationManager::initializeConnection):
+        * Shared/IdentifierTypes.h:
+        * UIProcess/Authentication/AuthenticationChallengeProxy.cpp:
+        (WebKit::AuthenticationChallengeProxy::AuthenticationChallengeProxy):
+        * UIProcess/Authentication/AuthenticationChallengeProxy.h:
+        (WebKit::AuthenticationChallengeProxy::create):
+        * UIProcess/Authentication/cocoa/AuthenticationChallengeProxyCocoa.mm:
+        (WebKit::AuthenticationChallengeProxy::sendClientCertificateCredentialOverXpc):
+        * UIProcess/Downloads/DownloadProxy.cpp:
+        (WebKit::DownloadProxy::didReceiveAuthenticationChallenge):
+        * UIProcess/Downloads/DownloadProxy.h:
+        * UIProcess/Downloads/DownloadProxy.messages.in:
+        * UIProcess/Network/NetworkProcessProxy.cpp:
+        (WebKit::NetworkProcessProxy::didReceiveAuthenticationChallenge):
+        * UIProcess/Network/NetworkProcessProxy.h:
+        * UIProcess/Network/NetworkProcessProxy.messages.in:
+
 2021-09-03  Stephan Szabo  <[email protected]>
 
         Fix for debug mode on MSVC after r281998

Modified: trunk/Source/WebKit/Scripts/webkit/messages.py (282047 => 282048)


--- trunk/Source/WebKit/Scripts/webkit/messages.py	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/Scripts/webkit/messages.py	2021-09-05 17:03:42 UTC (rev 282048)
@@ -311,6 +311,7 @@
         'WebCore::WebSocketIdentifier',
         'WebKit::ActivityStateChangeID',
         'WebKit::AudioMediaStreamTrackRendererInternalUnitIdentifier',
+        'WebKit::AuthenticationChallengeIdentifier',
         'WebKit::ContentWorldIdentifier',
         'WebKit::DisplayLinkObserverID',
         'WebKit::DownloadID',
@@ -770,6 +771,7 @@
         'WebCore::WebGLLoadPolicy': ['<WebCore/FrameLoaderTypes.h>'],
         'WebCore::WillContinueLoading': ['<WebCore/FrameLoaderTypes.h>'],
         'WebKit::ActivityStateChangeID': ['"DrawingAreaInfo.h"'],
+        'WebKit::AuthenticationChallengeIdentifier': ['"IdentifierTypes.h"'],
         'WebKit::AllowOverwrite': ['"DownloadID.h"'],
         'WebKit::AppPrivacyReportTestingData': ['"AppPrivacyReport.h"'],
         'WebKit::BackForwardListItemState': ['"SessionState.h"'],

Modified: trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.cpp (282047 => 282048)


--- trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.cpp	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.cpp	2021-09-05 17:03:42 UTC (rev 282048)
@@ -42,14 +42,6 @@
 namespace WebKit {
 using namespace WebCore;
 
-static uint64_t generateAuthenticationChallengeID()
-{
-    ASSERT(RunLoop::isMain());
-
-    static int64_t uniqueAuthenticationChallengeID;
-    return ++uniqueAuthenticationChallengeID;
-}
-
 static bool canCoalesceChallenge(const WebCore::AuthenticationChallenge& challenge)
 {
     // Do not coalesce server trust evaluation requests because ProtectionSpace comparison does not evaluate server trust (e.g. certificate).
@@ -67,16 +59,16 @@
     m_process.addMessageReceiver(Messages::AuthenticationManager::messageReceiverName(), *this);
 }
 
-uint64_t AuthenticationManager::addChallengeToChallengeMap(UniqueRef<Challenge>&& challenge)
+AuthenticationChallengeIdentifier AuthenticationManager::addChallengeToChallengeMap(UniqueRef<Challenge>&& challenge)
 {
     ASSERT(RunLoop::isMain());
 
-    uint64_t challengeID = generateAuthenticationChallengeID();
+    auto challengeID = AuthenticationChallengeIdentifier::generate();
     m_challenges.set(challengeID, WTFMove(challenge));
     return challengeID;
 }
 
-bool AuthenticationManager::shouldCoalesceChallenge(WebPageProxyIdentifier pageID, uint64_t challengeID, const AuthenticationChallenge& challenge) const
+bool AuthenticationManager::shouldCoalesceChallenge(WebPageProxyIdentifier pageID, AuthenticationChallengeIdentifier challengeID, const AuthenticationChallenge& challenge) const
 {
     if (!canCoalesceChallenge(challenge))
         return false;
@@ -88,7 +80,7 @@
     return false;
 }
 
-Vector<uint64_t> AuthenticationManager::coalesceChallengesMatching(uint64_t challengeID) const
+Vector<AuthenticationChallengeIdentifier> AuthenticationManager::coalesceChallengesMatching(AuthenticationChallengeIdentifier challengeID) const
 {
     auto* challenge = m_challenges.get(challengeID);
     if (!challenge) {
@@ -96,7 +88,7 @@
         return { };
     }
 
-    Vector<uint64_t> challengesToCoalesce;
+    Vector<AuthenticationChallengeIdentifier> challengesToCoalesce;
     challengesToCoalesce.append(challengeID);
 
     if (!canCoalesceChallenge(challenge->challenge))
@@ -115,7 +107,7 @@
     if (!pageID)
         return completionHandler(AuthenticationChallengeDisposition::PerformDefaultHandling, { });
 
-    uint64_t challengeID = addChallengeToChallengeMap(makeUniqueRef<Challenge>(pageID, authenticationChallenge, WTFMove(completionHandler)));
+    auto challengeID = addChallengeToChallengeMap(makeUniqueRef<Challenge>(pageID, authenticationChallenge, WTFMove(completionHandler)));
 
     // Coalesce challenges in the same protection space and in the same page.
     if (shouldCoalesceChallenge(pageID, challengeID, authenticationChallenge))
@@ -130,7 +122,7 @@
 void AuthenticationManager::didReceiveAuthenticationChallenge(IPC::MessageSender& download, const WebCore::AuthenticationChallenge& authenticationChallenge, ChallengeCompletionHandler&& completionHandler)
 {
     WebPageProxyIdentifier dummyPageID;
-    uint64_t challengeID = addChallengeToChallengeMap(makeUniqueRef<Challenge>(dummyPageID, authenticationChallenge, WTFMove(completionHandler)));
+    auto challengeID = addChallengeToChallengeMap(makeUniqueRef<Challenge>(dummyPageID, authenticationChallenge, WTFMove(completionHandler)));
     
     // Coalesce challenges in the same protection space and in the same page.
     if (shouldCoalesceChallenge(dummyPageID, challengeID, authenticationChallenge))
@@ -139,7 +131,7 @@
     download.send(Messages::DownloadProxy::DidReceiveAuthenticationChallenge(authenticationChallenge, challengeID));
 }
 
-void AuthenticationManager::completeAuthenticationChallenge(uint64_t challengeID, AuthenticationChallengeDisposition disposition, WebCore::Credential&& credential)
+void AuthenticationManager::completeAuthenticationChallenge(AuthenticationChallengeIdentifier challengeID, AuthenticationChallengeDisposition disposition, WebCore::Credential&& credential)
 {
     ASSERT(RunLoop::isMain());
 

Modified: trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.h (282047 => 282048)


--- trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.h	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.h	2021-09-05 17:03:42 UTC (rev 282048)
@@ -26,6 +26,7 @@
 #pragma once
 
 #include "DownloadID.h"
+#include "IdentifierTypes.h"
 #include "MessageReceiver.h"
 #include "NetworkProcessSupplement.h"
 #include "WebPageProxyIdentifier.h"
@@ -73,7 +74,7 @@
     void didReceiveAuthenticationChallenge(PAL::SessionID, WebPageProxyIdentifier, const WebCore::SecurityOriginData* , const WebCore::AuthenticationChallenge&, NegotiatedLegacyTLS, ChallengeCompletionHandler&&);
     void didReceiveAuthenticationChallenge(IPC::MessageSender& download, const WebCore::AuthenticationChallenge&, ChallengeCompletionHandler&&);
 
-    void completeAuthenticationChallenge(uint64_t challengeID, AuthenticationChallengeDisposition, WebCore::Credential&&);
+    void completeAuthenticationChallenge(AuthenticationChallengeIdentifier, AuthenticationChallengeDisposition, WebCore::Credential&&);
 
     void negotiatedLegacyTLS(WebPageProxyIdentifier) const;
 
@@ -98,14 +99,14 @@
     // IPC::MessageReceiver
     void didReceiveMessage(IPC::Connection&, IPC::Decoder&) override;
 
-    uint64_t addChallengeToChallengeMap(UniqueRef<Challenge>&&);
-    bool shouldCoalesceChallenge(WebPageProxyIdentifier, uint64_t challengeID, const WebCore::AuthenticationChallenge&) const;
+    AuthenticationChallengeIdentifier addChallengeToChallengeMap(UniqueRef<Challenge>&&);
+    bool shouldCoalesceChallenge(WebPageProxyIdentifier, AuthenticationChallengeIdentifier, const WebCore::AuthenticationChallenge&) const;
 
-    Vector<uint64_t> coalesceChallengesMatching(uint64_t challengeID) const;
+    Vector<AuthenticationChallengeIdentifier> coalesceChallengesMatching(AuthenticationChallengeIdentifier) const;
 
     NetworkProcess& m_process;
 
-    HashMap<uint64_t, UniqueRef<Challenge>> m_challenges;
+    HashMap<AuthenticationChallengeIdentifier, UniqueRef<Challenge>> m_challenges;
 };
 
 } // namespace WebKit

Modified: trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.messages.in (282047 => 282048)


--- trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.messages.in	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/Shared/Authentication/AuthenticationManager.messages.in	2021-09-05 17:03:42 UTC (rev 282048)
@@ -21,5 +21,5 @@
 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 messages -> AuthenticationManager NotRefCounted {
-    void CompleteAuthenticationChallenge(uint64_t challengeID, enum:uint8_t WebKit::AuthenticationChallengeDisposition disposition, WebCore::Credential credential);
+    void CompleteAuthenticationChallenge(WebKit::AuthenticationChallengeIdentifier challengeID, enum:uint8_t WebKit::AuthenticationChallengeDisposition disposition, WebCore::Credential credential);
 }

Modified: trunk/Source/WebKit/Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm (282047 => 282048)


--- trunk/Source/WebKit/Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm	2021-09-05 17:03:42 UTC (rev 282048)
@@ -98,7 +98,7 @@
             if (persistence > static_cast<uint64_t>(NSURLCredentialPersistenceSynchronizable))
                 return;
 
-            weakThis->completeAuthenticationChallenge(challengeID, AuthenticationChallengeDisposition::UseCredential, WebCore::Credential(adoptNS([[NSURLCredential alloc] initWithIdentity:identity.get() certificates:certificates persistence:(NSURLCredentialPersistence)persistence]).get()));
+            weakThis->completeAuthenticationChallenge(makeObjectIdentifier<AuthenticationChallengeIdentifierType>(challengeID), AuthenticationChallengeDisposition::UseCredential, WebCore::Credential(adoptNS([[NSURLCredential alloc] initWithIdentity:identity.get() certificates:certificates persistence:(NSURLCredentialPersistence)persistence]).get()));
         });
     });
 }

Modified: trunk/Source/WebKit/Shared/IdentifierTypes.h (282047 => 282048)


--- trunk/Source/WebKit/Shared/IdentifierTypes.h	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/Shared/IdentifierTypes.h	2021-09-05 17:03:42 UTC (rev 282048)
@@ -30,6 +30,9 @@
 
 namespace WebKit {
 
+enum AuthenticationChallengeIdentifierType { };
+using AuthenticationChallengeIdentifier = ObjectIdentifier<AuthenticationChallengeIdentifierType>;
+
 enum FormSubmitListenerIdentifierType { };
 using FormSubmitListenerIdentifier = ObjectIdentifier<FormSubmitListenerIdentifierType>;
 

Modified: trunk/Source/WebKit/UIProcess/Authentication/AuthenticationChallengeProxy.cpp (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Authentication/AuthenticationChallengeProxy.cpp	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Authentication/AuthenticationChallengeProxy.cpp	2021-09-05 17:03:42 UTC (rev 282048)
@@ -43,7 +43,7 @@
 
 namespace WebKit {
 
-AuthenticationChallengeProxy::AuthenticationChallengeProxy(WebCore::AuthenticationChallenge&& authenticationChallenge, uint64_t challengeID, Ref<IPC::Connection>&& connection, WeakPtr<SecKeyProxyStore>&& secKeyProxyStore)
+AuthenticationChallengeProxy::AuthenticationChallengeProxy(WebCore::AuthenticationChallenge&& authenticationChallenge, AuthenticationChallengeIdentifier challengeID, Ref<IPC::Connection>&& connection, WeakPtr<SecKeyProxyStore>&& secKeyProxyStore)
     : m_coreAuthenticationChallenge(WTFMove(authenticationChallenge))
     , m_listener(AuthenticationDecisionListener::create([challengeID, connection = WTFMove(connection), secKeyProxyStore = WTFMove(secKeyProxyStore)](AuthenticationChallengeDisposition disposition, const WebCore::Credential& credential) {
 #if HAVE(SEC_KEY_PROXY)

Modified: trunk/Source/WebKit/UIProcess/Authentication/AuthenticationChallengeProxy.h (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Authentication/AuthenticationChallengeProxy.h	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Authentication/AuthenticationChallengeProxy.h	2021-09-05 17:03:42 UTC (rev 282048)
@@ -26,6 +26,7 @@
 #pragma once
 
 #include "APIObject.h"
+#include "IdentifierTypes.h"
 #include <WebCore/AuthenticationChallenge.h>
 #include <wtf/WeakPtr.h>
 
@@ -42,7 +43,7 @@
 
 class AuthenticationChallengeProxy : public API::ObjectImpl<API::Object::Type::AuthenticationChallenge> {
 public:
-    static Ref<AuthenticationChallengeProxy> create(WebCore::AuthenticationChallenge&& authenticationChallenge, uint64_t challengeID, Ref<IPC::Connection>&& connection, WeakPtr<SecKeyProxyStore>&& secKeyProxyStore)
+    static Ref<AuthenticationChallengeProxy> create(WebCore::AuthenticationChallenge&& authenticationChallenge, AuthenticationChallengeIdentifier challengeID, Ref<IPC::Connection>&& connection, WeakPtr<SecKeyProxyStore>&& secKeyProxyStore)
     {
         return adoptRef(*new AuthenticationChallengeProxy(WTFMove(authenticationChallenge), challengeID, WTFMove(connection), WTFMove(secKeyProxyStore)));
     }
@@ -54,10 +55,10 @@
     const WebCore::AuthenticationChallenge& core() { return m_coreAuthenticationChallenge; }
 
 private:
-    AuthenticationChallengeProxy(WebCore::AuthenticationChallenge&&, uint64_t challengeID, Ref<IPC::Connection>&&, WeakPtr<SecKeyProxyStore>&&);
+    AuthenticationChallengeProxy(WebCore::AuthenticationChallenge&&, AuthenticationChallengeIdentifier, Ref<IPC::Connection>&&, WeakPtr<SecKeyProxyStore>&&);
 
 #if HAVE(SEC_KEY_PROXY)
-    static void sendClientCertificateCredentialOverXpc(IPC::Connection&, SecKeyProxyStore&, uint64_t challengeID, const WebCore::Credential&);
+    static void sendClientCertificateCredentialOverXpc(IPC::Connection&, SecKeyProxyStore&, AuthenticationChallengeIdentifier, const WebCore::Credential&);
 #endif
 
     WebCore::AuthenticationChallenge m_coreAuthenticationChallenge;

Modified: trunk/Source/WebKit/UIProcess/Authentication/cocoa/AuthenticationChallengeProxyCocoa.mm (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Authentication/cocoa/AuthenticationChallengeProxyCocoa.mm	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Authentication/cocoa/AuthenticationChallengeProxyCocoa.mm	2021-09-05 17:03:42 UTC (rev 282048)
@@ -36,13 +36,13 @@
 
 namespace WebKit {
 
-void AuthenticationChallengeProxy::sendClientCertificateCredentialOverXpc(IPC::Connection& connection, SecKeyProxyStore& secKeyProxyStore, uint64_t challengeID, const WebCore::Credential& credential)
+void AuthenticationChallengeProxy::sendClientCertificateCredentialOverXpc(IPC::Connection& connection, SecKeyProxyStore& secKeyProxyStore, AuthenticationChallengeIdentifier challengeID, const WebCore::Credential& credential)
 {
     ASSERT(secKeyProxyStore.isInitialized());
 
     auto message = adoptOSObject(xpc_dictionary_create(nullptr, nullptr, 0));
     xpc_dictionary_set_string(message.get(), ClientCertificateAuthentication::XPCMessageNameKey, ClientCertificateAuthentication::XPCMessageNameValue);
-    xpc_dictionary_set_uint64(message.get(), ClientCertificateAuthentication::XPCChallengeIDKey, challengeID);
+    xpc_dictionary_set_uint64(message.get(), ClientCertificateAuthentication::XPCChallengeIDKey, challengeID.toUInt64());
     xpc_dictionary_set_value(message.get(), ClientCertificateAuthentication::XPCSecKeyProxyEndpointKey, secKeyProxyStore.get().endpoint._endpoint);
     auto certificateDataArray = adoptOSObject(xpc_array_create(nullptr, 0));
     for (id certificate in credential.nsCredential().certificates) {

Modified: trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp	2021-09-05 17:03:42 UTC (rev 282048)
@@ -129,7 +129,7 @@
     m_client->legacyDidStart(*this);
 }
 
-void DownloadProxy::didReceiveAuthenticationChallenge(AuthenticationChallenge&& authenticationChallenge, uint64_t challengeID)
+void DownloadProxy::didReceiveAuthenticationChallenge(AuthenticationChallenge&& authenticationChallenge, AuthenticationChallengeIdentifier challengeID)
 {
     if (!m_dataStore)
         return;

Modified: trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.h (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.h	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.h	2021-09-05 17:03:42 UTC (rev 282048)
@@ -29,6 +29,7 @@
 #include "Connection.h"
 #include "DataReference.h"
 #include "DownloadID.h"
+#include "IdentifierTypes.h"
 #include "SandboxExtension.h"
 #include <WebCore/ResourceRequest.h>
 #include <wtf/Forward.h>
@@ -113,7 +114,7 @@
 
     // Message handlers.
     void didStart(const WebCore::ResourceRequest&, const String& suggestedFilename);
-    void didReceiveAuthenticationChallenge(WebCore::AuthenticationChallenge&&, uint64_t challengeID);
+    void didReceiveAuthenticationChallenge(WebCore::AuthenticationChallenge&&, AuthenticationChallengeIdentifier);
     void didReceiveData(uint64_t bytesWritten, uint64_t totalBytesWritten, uint64_t totalBytesExpectedToWrite);
     void shouldDecodeSourceDataOfMIMEType(const String& mimeType, bool& result);
     void didCreateDestination(const String& path);

Modified: trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.messages.in (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.messages.in	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Downloads/DownloadProxy.messages.in	2021-09-05 17:03:42 UTC (rev 282048)
@@ -22,7 +22,7 @@
 
 messages -> DownloadProxy {
     DidStart(WebCore::ResourceRequest request, AtomString suggestedFilename)
-    DidReceiveAuthenticationChallenge(WebCore::AuthenticationChallenge challenge, uint64_t challengeID)
+    DidReceiveAuthenticationChallenge(WebCore::AuthenticationChallenge challenge, WebKit::AuthenticationChallengeIdentifier challengeID)
     WillSendRequest(WebCore::ResourceRequest redirectRequest, WebCore::ResourceResponse redirectResponse))
     DecideDestinationWithSuggestedFilename(WebCore::ResourceResponse response, String suggestedFilename) -> (String filename, WebKit::SandboxExtension::Handle handle, enum:bool WebKit::AllowOverwrite allowOverwrite) Async
 

Modified: trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp	2021-09-05 17:03:42 UTC (rev 282048)
@@ -378,7 +378,7 @@
     store->client().didReceiveAuthenticationChallenge(WTFMove(authenticationChallenge));
 }
 
-void NetworkProcessProxy::didReceiveAuthenticationChallenge(PAL::SessionID sessionID, WebPageProxyIdentifier pageID, const std::optional<SecurityOriginData>& topOrigin, WebCore::AuthenticationChallenge&& coreChallenge, bool negotiatedLegacyTLS, uint64_t challengeID)
+void NetworkProcessProxy::didReceiveAuthenticationChallenge(PAL::SessionID sessionID, WebPageProxyIdentifier pageID, const std::optional<SecurityOriginData>& topOrigin, WebCore::AuthenticationChallenge&& coreChallenge, bool negotiatedLegacyTLS, AuthenticationChallengeIdentifier challengeID)
 {
 #if HAVE(SEC_KEY_PROXY)
     WeakPtr<SecKeyProxyStore> secKeyProxyStore;

Modified: trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.h (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.h	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.h	2021-09-05 17:03:42 UTC (rev 282048)
@@ -27,6 +27,7 @@
 
 #include "AppPrivacyReport.h"
 #include "AuxiliaryProcessProxy.h"
+#include "IdentifierTypes.h"
 #include "NetworkProcessProxyMessagesReplies.h"
 #include "NetworkResourceLoadIdentifier.h"
 #include "ProcessLauncher.h"
@@ -292,7 +293,7 @@
 
     // Message handlers
     void didReceiveNetworkProcessProxyMessage(IPC::Connection&, IPC::Decoder&);
-    void didReceiveAuthenticationChallenge(PAL::SessionID, WebPageProxyIdentifier, const std::optional<WebCore::SecurityOriginData>&, WebCore::AuthenticationChallenge&&, bool, uint64_t challengeID);
+    void didReceiveAuthenticationChallenge(PAL::SessionID, WebPageProxyIdentifier, const std::optional<WebCore::SecurityOriginData>&, WebCore::AuthenticationChallenge&&, bool, AuthenticationChallengeIdentifier);
     void negotiatedLegacyTLS(WebPageProxyIdentifier);
     void didNegotiateModernTLS(WebPageProxyIdentifier, const URL&);
     void setWebProcessHasUploads(WebCore::ProcessIdentifier, bool);

Modified: trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.messages.in (282047 => 282048)


--- trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.messages.in	2021-09-05 13:44:12 UTC (rev 282047)
+++ trunk/Source/WebKit/UIProcess/Network/NetworkProcessProxy.messages.in	2021-09-05 17:03:42 UTC (rev 282048)
@@ -21,7 +21,7 @@
 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 messages -> NetworkProcessProxy LegacyReceiver {
-    DidReceiveAuthenticationChallenge(PAL::SessionID sessionID, WebKit::WebPageProxyIdentifier pageID, std::optional<WebCore::SecurityOriginData> topOrigin, WebCore::AuthenticationChallenge challenge, bool negotiatedLegacyTLS, uint64_t challengeID)
+    DidReceiveAuthenticationChallenge(PAL::SessionID sessionID, WebKit::WebPageProxyIdentifier pageID, std::optional<WebCore::SecurityOriginData> topOrigin, WebCore::AuthenticationChallenge challenge, bool negotiatedLegacyTLS, WebKit::AuthenticationChallengeIdentifier challengeID)
     NegotiatedLegacyTLS(WebKit::WebPageProxyIdentifier pageID)
     DidNegotiateModernTLS(WebKit::WebPageProxyIdentifier pageID, URL url)
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to