WebKit Bugzilla
Attachment 340114 Details for
Bug 185522
: NetworkCORSPreflightChecker should proceed when having a ProtectionSpaceAuthenticationSchemeServerTrustEvaluationRequested challenge
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-185522-20180510205554.patch (text/plain), 2.61 KB, created by
youenn fablet
on 2018-05-10 11:55:56 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
youenn fablet
Created:
2018-05-10 11:55:56 PDT
Size:
2.61 KB
patch
obsolete
>Subversion Revision: 231552 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 50d7034fab50c7a55f822305efe53349809fc980..59fa4fe2150e58245fd411d7375bcb6c8ea7ae72 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,19 @@ >+2018-05-10 Youenn Fablet <youenn@apple.com> >+ >+ NetworkCORSPreflightChecker should proceed when having a ProtectionSpaceAuthenticationSchemeServerTrustEvaluationRequested challenge >+ https://bugs.webkit.org/show_bug.cgi?id=185522 >+ <rdar://problem/39987152> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ In case of such challenge, refuse to proceed with authentication since preflight is not using credentials. >+ Previously, we were failing right away which is not right in case preflight is the request triggering the connection. >+ >+ Manually tested. >+ >+ * NetworkProcess/NetworkCORSPreflightChecker.cpp: >+ (WebKit::NetworkCORSPreflightChecker::didReceiveChallenge): >+ > 2018-05-09 Youenn Fablet <youenn@apple.com> > > Allow WebResourceLoader to cancel a load served from a service worker >diff --git a/Source/WebKit/NetworkProcess/NetworkCORSPreflightChecker.cpp b/Source/WebKit/NetworkProcess/NetworkCORSPreflightChecker.cpp >index 7b770a7c808c0a569bb9433da35a7a36f12ce094..3274326b5dfc60061d989ec88cac35635d571b12 100644 >--- a/Source/WebKit/NetworkProcess/NetworkCORSPreflightChecker.cpp >+++ b/Source/WebKit/NetworkProcess/NetworkCORSPreflightChecker.cpp >@@ -78,9 +78,15 @@ void NetworkCORSPreflightChecker::willPerformHTTPRedirection(WebCore::ResourceRe > m_completionCallback(ResourceError { errorDomainWebKitInternal, 0, m_parameters.originalRequest.url(), ASCIILiteral("Preflight response is not successful"), ResourceError::Type::AccessControl }); > } > >-void NetworkCORSPreflightChecker::didReceiveChallenge(const WebCore::AuthenticationChallenge&, ChallengeCompletionHandler&& completionHandler) >+void NetworkCORSPreflightChecker::didReceiveChallenge(const WebCore::AuthenticationChallenge& challenge, ChallengeCompletionHandler&& completionHandler) > { > RELEASE_LOG_IF_ALLOWED("didReceiveChallenge"); >+ >+ if (challenge.protectionSpace().authenticationScheme() == ProtectionSpaceAuthenticationSchemeServerTrustEvaluationRequested) { >+ completionHandler(AuthenticationChallengeDisposition::RejectProtectionSpace, { }); >+ return; >+ } >+ > completionHandler(AuthenticationChallengeDisposition::Cancel, { }); > m_completionCallback(ResourceError { errorDomainWebKitInternal, 0, m_parameters.originalRequest.url(), ASCIILiteral("Preflight response is not successful"), ResourceError::Type::AccessControl }); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 185522
: 340114