New issue
Advanced search Search tips

Issue 884727 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Sep 18
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: iOS
Pri: 3
Type: Bug



Sign in to add a comment

HEAD request sent after GET to pre-signed GET S3 URL

Reported by nyogen...@zynga.com, Sep 17

Issue description

Steps to reproduce the problem:
1. paste a pre-signed GET url in address bar and press enter
2. observe that two requests are sent 1. GET 2. HEAD
3. observe that GET succeeds and HEAD fails and download fails

What is the expected behavior?
download should succeed

What went wrong?
download failed

Did this work before? N/A 

Chrome version: 68.3440.83  Channel: n/a
OS Version: OS X 11.4.1
Flash Version:
 
Components: Internals>Network
Labels: Needs-Feedback
Can you include a specific set of repro steps?
We have a S3 bucket, and we host some zip files in it. We allow users to download zip files from S3 bucket via a pre-signed S3 GET URL. Downloading of zip file fails in chrome 68 on ios. We analyzed the issue and found out that chrome sends two requests to the pre-signed S3 URL. It makes a GET request which succeeds. Then it makes a HEAD requests which fails with 403 Forbidden error. We want to understand why chrome is making a HEAD request after GET request. 

We cannot give a sample S3 URL here because we cannot expose it outside of our organization.
Project Member

Comment 3 by sheriffbot@chromium.org, Sep 18

Cc: eroman@chromium.org
Labels: -Needs-Feedback
Thank you for providing more feedback. Adding the requester to the cc list.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Cc: dtrainor@chromium.org
Components: UI>Browser>Downloads
Owner: eugene...@chromium.org
Status: Assigned (was: Unconfirmed)
Hi Eugene!  I think you're the right person to help out on this for iOS downloads.  Could you help us triage?  Thanks! :)
Cc: eugene...@chromium.org
Components: -Internals>Network
Labels: -Pri-2 Pri-3
Owner: ----
Status: ExternalDependency (was: Assigned)
Per AppStore guidelines the browsers have to use UIWebView or WKWebView as rendering engine. Neither UIWebView nor WKWebView support public download API, so as a workaround Chrome uses NSURLSession to download the response which can not be displayed in web view. Safari has access to private WKWebView API, which allows downloading nonce urls.

First GET request is sent by web view when the URL is loaded in the browser. Second HEAD request is sent by NSURLSession to actually download the response. We filed WebKit bug and asked Apple to make Downloads API available for 3rd browsers: https://bugs.webkit.org/show_bug.cgi?id=158801
Do you know why this issue is not there in chrome 69 version?
Status: WontFix (was: ExternalDependency)
I think both M68 and M69 send 2 requests for downloads. It is possible that M68 used old downloads manager backend for the small percentage of the users and sent GET->HEAD->GET, while new backend only sends GET->GET.

Thanks for confirming that bug is not reproducible in M69. Marking as WontFix. Feel free to comment on this bug if you have further questions.
chrome 69 sends only one request i.e. GET

Sign in to add a comment