WebKit Bugzilla
Attachment 356175 Details for
Bug 114965
: [Mac] HEAD requests changed to GET after 301, 302, and 303 redirections (http/tests/xmlhttprequest/head-redirection.html)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-114965-20181130163155.patch (text/plain), 6.87 KB, created by
Rob Buis
on 2018-11-30 07:31:56 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Rob Buis
Created:
2018-11-30 07:31:56 PST
Size:
6.87 KB
patch
obsolete
>Subversion Revision: 238666 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 8b6cc709f37589783ac64814b6e2b6e020d6b0c9..dc5628480366349514f55ab1bfa7777941a2b38d 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,13 @@ >+2018-11-30 Rob Buis <rbuis@igalia.com> >+ >+ [Mac] HEAD requests changed to GET after 301, 302, and 303 redirections (http/tests/xmlhttprequest/head-redirection.html) >+ https://bugs.webkit.org/show_bug.cgi?id=114965 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * NetworkProcess/cocoa/NetworkDataTaskCocoa.mm: >+ (WebKit::NetworkDataTaskCocoa::willPerformHTTPRedirection): >+ > 2018-11-29 Tomas Popela <tpopela@redhat.com> > > [GTK][WPE] Fix BubblewrapLauncher clang warnings >diff --git a/Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm b/Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm >index 5e832b7a1bd25b41d7bc00e9eef083b29fefc202..43c00e565f3b85ebfb819652b1949e7e0a9a456b 100644 >--- a/Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm >+++ b/Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm >@@ -306,7 +306,8 @@ void NetworkDataTaskCocoa::willPerformHTTPRedirection(WebCore::ResourceResponse& > String originalContentType = m_firstRequest.httpContentType(); > if (!originalContentType.isEmpty()) > request.setHTTPHeaderField(WebCore::HTTPHeaderName::ContentType, originalContentType); >- } >+ } else if (redirectResponse.httpStatusCode() == 303 && equalLettersIgnoringASCIICase(m_firstRequest.httpMethod(), "head")) >+ request.setHTTPMethod("HEAD"_s); > > // Should not set Referer after a redirect from a secure resource to non-secure one. > if (m_shouldClearReferrerOnHTTPSToHTTPRedirect && !request.url().protocolIs("https") && WebCore::protocolIs(request.httpReferrer(), "https")) >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 7257553e71bfa3a1436fa80c98be72c58f810a34..c78726f47b281299f068a81640c28572de5ca287 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,13 @@ >+2018-11-30 Rob Buis <rbuis@igalia.com> >+ >+ [Mac] HEAD requests changed to GET after 301, 302, and 303 redirections (http/tests/xmlhttprequest/head-redirection.html) >+ https://bugs.webkit.org/show_bug.cgi?id=114965 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * platform/ios/TestExpectations: >+ * platform/mac/http/tests/xmlhttprequest/head-redirection-expected.txt: Removed. >+ > 2018-11-28 Said Abou-Hallawa <sabouhallawa@apple.com> > > Updating href on linearGradient and radialGradient doesn't update its rendering >diff --git a/LayoutTests/imported/w3c/ChangeLog b/LayoutTests/imported/w3c/ChangeLog >index 7f749a246da770f1205cca1da468586500c4a800..c067010a6331c1ba7ce496e814341c2b140091df 100644 >--- a/LayoutTests/imported/w3c/ChangeLog >+++ b/LayoutTests/imported/w3c/ChangeLog >@@ -1,3 +1,13 @@ >+2018-11-30 Rob Buis <rbuis@igalia.com> >+ >+ [Mac] HEAD requests changed to GET after 301, 302, and 303 redirections (http/tests/xmlhttprequest/head-redirection.html) >+ https://bugs.webkit.org/show_bug.cgi?id=114965 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * web-platform-tests/fetch/api/redirect/redirect-method-expected.txt: >+ * web-platform-tests/fetch/api/redirect/redirect-method-worker-expected.txt: >+ > 2018-11-29 Rob Buis <rbuis@igalia.com> > > Import fetch/api/cors tests >diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-expected.txt >index 24af5ffe774d10ce6e1bc09037a91623279b111e..ae32d5146630f4ab54bb46487700646d606dd68f 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-expected.txt >+++ b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-expected.txt >@@ -8,7 +8,7 @@ PASS Redirect 302 with POST > PASS Redirect 302 with HEAD > PASS Redirect 303 with GET > PASS Redirect 303 with POST >-FAIL Redirect 303 with HEAD assert_equals: Request method after redirection is HEAD expected "HEAD" but got "GET" >+PASS Redirect 303 with HEAD > PASS Redirect 307 with GET > PASS Redirect 307 with POST (string body) > PASS Redirect 307 with POST (blob body) >diff --git a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-worker-expected.txt b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-worker-expected.txt >index 24af5ffe774d10ce6e1bc09037a91623279b111e..ae32d5146630f4ab54bb46487700646d606dd68f 100644 >--- a/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-worker-expected.txt >+++ b/LayoutTests/imported/w3c/web-platform-tests/fetch/api/redirect/redirect-method-worker-expected.txt >@@ -8,7 +8,7 @@ PASS Redirect 302 with POST > PASS Redirect 302 with HEAD > PASS Redirect 303 with GET > PASS Redirect 303 with POST >-FAIL Redirect 303 with HEAD assert_equals: Request method after redirection is HEAD expected "HEAD" but got "GET" >+PASS Redirect 303 with HEAD > PASS Redirect 307 with GET > PASS Redirect 307 with POST (string body) > PASS Redirect 307 with POST (blob body) >diff --git a/LayoutTests/platform/ios/TestExpectations b/LayoutTests/platform/ios/TestExpectations >index a1d3e7823b47651ef65ca3dcae08b8d14196a9ee..5e356b2f5364e58606a7e20d2fa4b7b3352db00d 100644 >--- a/LayoutTests/platform/ios/TestExpectations >+++ b/LayoutTests/platform/ios/TestExpectations >@@ -1550,7 +1550,6 @@ http/tests/webarchive/test-css-url-encoding.html > # XMLHttpRequest tests that fail: > http/tests/xmlhttprequest/basic-auth-nopassword.html [ Failure ] > http/tests/xmlhttprequest/default-content-type-dashboard.html [ Failure ] >-http/tests/xmlhttprequest/head-redirection.html [ Failure ] > > # DeviceMotion tests that time out: > fast/dom/DeviceMotion/no-page-cache.html >diff --git a/LayoutTests/platform/mac/http/tests/xmlhttprequest/head-redirection-expected.txt b/LayoutTests/platform/mac/http/tests/xmlhttprequest/head-redirection-expected.txt >deleted file mode 100644 >index 005ac614571745c1ca9c7dec3bfb74bd56454167..0000000000000000000000000000000000000000 >--- a/LayoutTests/platform/mac/http/tests/xmlhttprequest/head-redirection-expected.txt >+++ /dev/null >@@ -1,10 +0,0 @@ >-This page tests redirection of HEAD requests with different codes (301, 302, 303, 307). >-As described in http://tools.ietf.org/html/draft-ietf-httpbis-p2-semantics (in particular sections 7.4.2, 7.4.3, 7.4.4 and 7.4.7 as of version 22 of the document), a redirected HEAD request is expected to remain a HEAD request. >- >-This test loads a web page that does a XHR HEAD request to a first script. This script does a redirection to a second script that sends a response containing the request method as a HTTP header. >- >-HEAD-301 - expected HEAD and received HEAD >-HEAD-302 - expected HEAD and received HEAD >-HEAD-303 - expected HEAD and received GET >-HEAD-307 - expected HEAD and received HEAD >-
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 114965
:
356168
|
356169
|
356175
|
356181
|
356186
|
356199
|
356233
|
356593