[WK2][NETWORK_SESSION] Move some authentication-related code to avoid duplication
authorcdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 29 Sep 2017 22:08:33 +0000 (22:08 +0000)
committercdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 29 Sep 2017 22:08:33 +0000 (22:08 +0000)
commit027004eebb83896e3e6eac93fc1d30ee3d0b52f1
tree70e5e1f67f4787ff608d99cf93327dfaf40df021
parent92c2b19b2c57e7a0c79e4fa50e5d1f31c3d551d5
[WK2][NETWORK_SESSION] Move some authentication-related code to avoid duplication
https://bugs.webkit.org/show_bug.cgi?id=177667

Reviewed by Alex Christensen.

Move some authentication-related code to avoid duplication.
This is a preparation code supporting Download authentication
as Download uses a NSURLSessionDownloadTask and not a
NetworkDataTask.

* NetworkProcess/NetworkDataTask.h:
(WebKit::NetworkDataTask::setSuggestedFilename):
* NetworkProcess/NetworkLoad.cpp:
(WebKit::NetworkLoad::didReceiveChallenge):
(WebKit::NetworkLoad::continueCanAuthenticateAgainstProtectionSpace):
* NetworkProcess/NetworkSession.cpp:
(WebKit::NetworkSession::allowsSpecificHTTPSCertificateForHost):
* NetworkProcess/NetworkSession.h:
* NetworkProcess/PreconnectTask.cpp:
(WebKit::PreconnectTask::didReceiveChallenge):
* NetworkProcess/cocoa/NetworkDataTaskCocoa.h:
* NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
(WebKit::NetworkDataTaskCocoa::didReceiveChallenge):
* NetworkProcess/cocoa/NetworkSessionCocoa.h:
* NetworkProcess/cocoa/NetworkSessionCocoa.mm:
(-[WKNetworkSessionDelegate URLSession:task:didReceiveChallenge:completionHandler:]):
(WebKit::certificatesMatch):
(WebKit::NetworkSessionCocoa::allowsSpecificHTTPSCertificateForHost):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@222667 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit/ChangeLog
Source/WebKit/NetworkProcess/NetworkDataTask.h
Source/WebKit/NetworkProcess/NetworkLoad.cpp
Source/WebKit/NetworkProcess/NetworkSession.cpp
Source/WebKit/NetworkProcess/NetworkSession.h
Source/WebKit/NetworkProcess/PreconnectTask.cpp
Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.h
Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm
Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.h
Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm