diff options
author | Andras Becsi <andras.becsi@digia.com> | 2013-12-11 21:33:03 +0100 |
---|---|---|
committer | Andras Becsi <andras.becsi@digia.com> | 2013-12-13 12:34:07 +0100 |
commit | f2a33ff9cbc6d19943f1c7fbddd1f23d23975577 (patch) | |
tree | 0586a32aa390ade8557dfd6b4897f43a07449578 /chromium/google_apis/gaia/gaia_auth_fetcher.cc | |
parent | 5362912cdb5eea702b68ebe23702468d17c3017a (diff) | |
download | qtwebengine-chromium-f2a33ff9cbc6d19943f1c7fbddd1f23d23975577.tar.gz |
Update Chromium to branch 1650 (31.0.1650.63)
Change-Id: I57d8c832eaec1eb2364e0a8e7352a6dd354db99f
Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
Diffstat (limited to 'chromium/google_apis/gaia/gaia_auth_fetcher.cc')
-rw-r--r-- | chromium/google_apis/gaia/gaia_auth_fetcher.cc | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/chromium/google_apis/gaia/gaia_auth_fetcher.cc b/chromium/google_apis/gaia/gaia_auth_fetcher.cc index 67756deb99b..f0e26445a52 100644 --- a/chromium/google_apis/gaia/gaia_auth_fetcher.cc +++ b/chromium/google_apis/gaia/gaia_auth_fetcher.cc @@ -103,7 +103,7 @@ const char GaiaAuthFetcher::kMergeSessionFormat[] = "source=%s"; // static const char GaiaAuthFetcher::kUberAuthTokenURLFormat[] = - "%s?source=%s&" + "?source=%s&" "issueuberauth=1"; const char GaiaAuthFetcher::kOAuthLoginFormat[] = "service=%s&source=%s"; @@ -179,8 +179,8 @@ GaiaAuthFetcher::GaiaAuthFetcher(GaiaAuthConsumer* consumer, oauth2_revoke_gurl_(GaiaUrls::GetInstance()->oauth2_revoke_url()), get_user_info_gurl_(GaiaUrls::GetInstance()->get_user_info_url()), merge_session_gurl_(GaiaUrls::GetInstance()->merge_session_url()), - uberauth_token_gurl_(base::StringPrintf(kUberAuthTokenURLFormat, - GaiaUrls::GetInstance()->oauth1_login_url().c_str(), source.c_str())), + uberauth_token_gurl_(GaiaUrls::GetInstance()->oauth1_login_url().Resolve( + base::StringPrintf(kUberAuthTokenURLFormat, source.c_str()))), oauth_login_gurl_(GaiaUrls::GetInstance()->oauth1_login_url()), client_login_to_oauth2_gurl_( GaiaUrls::GetInstance()->client_login_to_oauth2_url()), @@ -517,7 +517,7 @@ void GaiaAuthFetcher::StartLsoForOAuthLoginTokenExchange( DVLOG(1) << "Starting OAuth login token exchange with auth_token"; request_body_ = MakeGetAuthCodeBody(); client_login_to_oauth2_gurl_ = - GURL(GaiaUrls::GetInstance()->client_login_to_oauth2_url()); + GaiaUrls::GetInstance()->client_login_to_oauth2_url(); fetcher_.reset(CreateGaiaFetcher(getter_, request_body_, @@ -551,11 +551,12 @@ void GaiaAuthFetcher::StartCookieForOAuthLoginTokenExchange( DVLOG(1) << "Starting OAuth login token fetch with cookie jar"; request_body_ = MakeGetAuthCodeBody(); - std::string url = GaiaUrls::GetInstance()->client_login_to_oauth2_url(); - if (!session_index.empty()) - url += "?authuser=" + session_index; - - client_login_to_oauth2_gurl_ = GURL(url); + client_login_to_oauth2_gurl_ = + GaiaUrls::GetInstance()->client_login_to_oauth2_url(); + if (!session_index.empty()) { + client_login_to_oauth2_gurl_ = + client_login_to_oauth2_gurl_.Resolve("?authuser=" + session_index); + } fetcher_.reset(CreateGaiaFetcher(getter_, request_body_, @@ -684,7 +685,7 @@ GoogleServiceAuthError GaiaAuthFetcher::GenerateAuthError( if (error == kCaptchaError) { GURL image_url( - GaiaUrls::GetInstance()->captcha_url_prefix() + captcha_url); + GaiaUrls::GetInstance()->captcha_base_url().Resolve(captcha_url)); GURL unlock_url(url); return GoogleServiceAuthError::FromClientLoginCaptchaChallenge( captcha_token, image_url, unlock_url); @@ -737,7 +738,7 @@ GoogleServiceAuthError GaiaAuthFetcher::GenerateOAuthLoginError( if (error == kCaptchaErrorCode) { GURL image_url( - GaiaUrls::GetInstance()->captcha_url_prefix() + captcha_url); + GaiaUrls::GetInstance()->captcha_base_url().Resolve(captcha_url)); GURL unlock_url(url); return GoogleServiceAuthError::FromClientLoginCaptchaChallenge( captcha_token, image_url, unlock_url); |