New issue
Advanced search Search tips

Issue 889471 link

Starred by 1 user

Issue metadata

Status: Started
Owner:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocking:
issue 771911



Sign in to add a comment

Use NSURLSession to query gaia.

Project Member Reported by valeriyas@google.com, Sep 26

Issue description

Use NSURLSession to query gaia after ios11 instead of WKWebView.

Multilogin endpoint has a header content-disposition which prevents javascriptEvaluation of response by WKWebView.
WKWebView should not be used at all for this purpose and the whole thing should be rewritten to NSUrlSession.


 
Description: Show this description
Owner: jlebel@chromium.org
Status: Started (was: Fixed)
Project Member

Comment 4 by bugdroid1@chromium.org, Dec 17

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f201d66dcef87f1173cde3e2cc474f8629aed941

commit f201d66dcef87f1173cde3e2cc474f8629aed941
Author: Jérôme Lebel <jlebel@chromium.org>
Date: Mon Dec 17 10:23:40 2018

[iOS] Preparing GAIA auth fetcher with NSURLSession

GaiaAuthFetcherIOSBridge is removed from gaia_auth_fetcher_ios.mm, and
it is split into 2 classes:

  + GaiaAuthFetcherIOSBridge
This class contains all the generic code related to specific to fetch
request on iOS.

  + GaiaAuthFetcherIOSWKWebViewBridge
This class contains all the code specific to WKWebView.


This patch is to prepare:
crrev.com/c/1373109

Bug: 889471
Change-Id: I145029591f4eab885edcab3cc9e5aead2ecd0978
Reviewed-on: https://chromium-review.googlesource.com/c/1369930
Commit-Queue: Jérôme Lebel <jlebel@chromium.org>
Reviewed-by: David Roger <droger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#617075}
[modify] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/BUILD.gn
[modify] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/gaia_auth_fetcher_ios.h
[modify] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/gaia_auth_fetcher_ios.mm
[add] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/gaia_auth_fetcher_ios_bridge.h
[add] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/gaia_auth_fetcher_ios_bridge.mm
[delete] https://crrev.com/f34ea69cee2b75a99f6439faf467f856e8558a9a/ios/chrome/browser/signin/gaia_auth_fetcher_ios_private.h
[modify] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/gaia_auth_fetcher_ios_unittest.mm
[add] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/gaia_auth_fetcher_ios_wk_webview_bridge.h
[add] https://crrev.com/f201d66dcef87f1173cde3e2cc474f8629aed941/ios/chrome/browser/signin/gaia_auth_fetcher_ios_wk_webview_bridge.mm

Project Member

Comment 5 by bugdroid1@chromium.org, Dec 19

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5717fa850bfd7f40c8c2700d3957bf407994ab9c

commit 5717fa850bfd7f40c8c2700d3957bf407994ab9c
Author: Jérôme Lebel <jlebel@chromium.org>
Date: Wed Dec 19 12:11:13 2018

[iOS] Using NSURLSession for GAIAAuthFetcheriOS

Adding sub class of GaiaAuthFetcherIOSBridge to use NSURLSession:
GaiaAuthFetcherIOSNSURLSessionBridge.

GaiaAuthFetcherIOS can either use GaiaAuthFetcherIOSNSURLSessionBridge
or GaiaAuthFetcherIOSWKWebViewBridge to fetch request.

|use-nsurlsession-for-signin| flag is added to be able to user one or
the other class to fetch request from GaiaAuthFetcherIOS.

GaiaAuthFetcherIOSNSURLSessionBridge can only be used when
|web::features::kWKHTTPSystemCookieStore| is enabled (see
 http://crbug.com/902584 ).

This patch is to replace: crrev.com/c/1280249

Bug: 889471,  898956 
Change-Id: If05acd7c0f2a65a18348689aedbdae1f80c20724
Reviewed-on: https://chromium-review.googlesource.com/c/1373109
Commit-Queue: Jérôme Lebel <jlebel@chromium.org>
Reviewed-by: David Roger <droger@chromium.org>
Reviewed-by: Olivier Robin <olivierrobin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#617805}
[modify] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/about_flags.mm
[modify] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/ios_chrome_flag_descriptions.cc
[modify] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/ios_chrome_flag_descriptions.h
[modify] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/signin/BUILD.gn
[modify] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/signin/feature_flags.h
[modify] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/signin/feature_flags.mm
[modify] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/signin/gaia_auth_fetcher_ios.mm
[add] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/signin/gaia_auth_fetcher_ios_ns_url_session_bridge.h
[add] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/signin/gaia_auth_fetcher_ios_ns_url_session_bridge.mm
[add] https://crrev.com/5717fa850bfd7f40c8c2700d3957bf407994ab9c/ios/chrome/browser/signin/gaia_auth_fetcher_ios_ns_url_session_bridge_unittests.mm

Sign in to add a comment