Network process crash under WebKit::AuthenticationManager::rejectProtectionSpaceAndCo...
authorpvollan@apple.com <pvollan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 25 Oct 2017 23:24:15 +0000 (23:24 +0000)
committerpvollan@apple.com <pvollan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 25 Oct 2017 23:24:15 +0000 (23:24 +0000)
commitc6e02314f87e1cf2a0114c3309710ae09b431633
tree43251c5b0da39043832e084dea521c61ac927c78
parent42321ceb437fdf8c7e3d40f9a92efabf6504069f
Network process crash under WebKit::AuthenticationManager::rejectProtectionSpaceAndContinueForSingleChallenge.
https://bugs.webkit.org/show_bug.cgi?id=160234
rdar://problem/30675510

Reviewed by Geoffrey Garen.

An exception is raised because we call the method rejectProtectionSpaceAndContinueWithChallenge on the CFNetwork
challenge sender, which does not implement this optional method. The methods on the authentication challenge
sender are deprecated when network session is used, so we should not call them in that case.

* Shared/Authentication/AuthenticationManager.cpp:
(WebKit::AuthenticationManager::useCredentialForSingleChallenge):
(WebKit::AuthenticationManager::continueWithoutCredentialForSingleChallenge):
(WebKit::AuthenticationManager::cancelSingleChallenge):
(WebKit::AuthenticationManager::performDefaultHandlingForSingleChallenge):
(WebKit::AuthenticationManager::rejectProtectionSpaceAndContinueForSingleChallenge):
* Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm:
(WebKit::AuthenticationManager::receivedCredential):
(WebKit::AuthenticationManager::receivedRequestToContinueWithoutCredential):
(WebKit::AuthenticationManager::receivedCancellation):
(WebKit::AuthenticationManager::receivedRequestToPerformDefaultHandling):
(WebKit::AuthenticationManager::receivedChallengeRejection):
* Shared/Authentication/soup/AuthenticationManagerSoup.cpp:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@223993 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit/ChangeLog
Source/WebKit/Shared/Authentication/AuthenticationManager.cpp
Source/WebKit/Shared/Authentication/cocoa/AuthenticationManagerCocoa.mm
Source/WebKit/Shared/Authentication/soup/AuthenticationManagerSoup.cpp