New issue
Advanced search Search tips

Issue 913392 link

Starred by 4 users

Issue metadata

Status: Fixed
Owner:
Closed: Jan 18
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 1
Type: Bug

Blocked on:
issue 907901

Blocking:
issue 883318



Sign in to add a comment

Convert inline_login_handler_impl.cc to use AccountsMutator rather than PO2TS for setting the refresh token

Project Member Reported by blundell@chromium.org, Dec 10

Issue description

Should be straightforward once the API surface is filled in in AccountsMutator (see blocking bug).
 
Blockedon: 907901
As far as I can see in InlineSigninHelper::OnClientOAuthSuccessAndBrowserOpened() there are situations where the current code would seed the account information in the ATS but never get to update the PO2TS with a valid refresh token, which is something that the current API in AccountsMutator does not support (we can only call AddOrUpdateAccount, which would do both things, one right after the other).

@blundell Could you clarify a bit on what's the expected way to handle this situation? Looks like we must to either add some extra API or refactor how things are written in there.
Hi Mario,

Good catch, thank you! For now let's just port the call to UpdateCredentials() to AddOrUpdateAccount() together with a bugref/TODO for folding in the call to AccountTrackerService::SeedAccountInfo(). I'll file the latter bug.

Comment 4 by ma...@igalia.com, Jan 16 (6 days ago)

Blockedon: 922026
Owner: ma...@igalia.com
Status: Started (was: Available)
Thanks Colin, I'll do it that way then. Blocking on 922026 for now too.

Comment 6 by blundell@chromium.org, Jan 16 (6 days ago)

Blockedon: -922026
Minor clarification: Removing PO2TS isn't blocked on figuring out the ATS issue :).
Project Member

Comment 7 by bugdroid1@chromium.org, Jan 16 (6 days ago)

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

commit 19540192d96c5b6f82de25e9716c58436e0cd84c
Author: Mario Sanchez Prada <mario@igalia.com>
Date: Wed Jan 16 17:28:39 2019

Call ATS::SetIsAdvancedProtectionAccount() from InlineSigninHelper

We're currently not explicitly setting the |is_under_advanced_protection|
flag when updating the refresh token for a given account from there, which
hasn't been a problem for now, but it would be good to add it to explicitly
track this change before migrating to AccountsMutator::AddOrUpdateAccount(),
which will always set this flag before calling PO2TS::UpdateCredentials().

Bug:  913392 
Change-Id: I0915de8210e1877b337b9bfaf62ff9709a3733dc
Reviewed-on: https://chromium-review.googlesource.com/c/1411889
Reviewed-by: Mihai Sardarescu <msarda@chromium.org>
Commit-Queue: Mario Sanchez Prada <mario@igalia.com>
Cr-Commit-Position: refs/heads/master@{#623271}
[modify] https://crrev.com/19540192d96c5b6f82de25e9716c58436e0cd84c/chrome/browser/ui/webui/signin/inline_login_handler_impl.cc

Project Member

Comment 8 by bugdroid1@chromium.org, Jan 18 (4 days ago)

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

commit 76ec273db6e52343010095b5d031b89753193a05
Author: Mario Sanchez Prada <mario@igalia.com>
Date: Fri Jan 18 11:14:52 2019

Migrate inline_login_handler_impl.cc away from ProfileOAut2TokenService

Use AccountsMutator's API instead, and get rid of the PO2TS dependency.

Bug:  913392 
Change-Id: Ibdcf6ea228ca760588cdb2e5416994c8d82fd8df
Reviewed-on: https://chromium-review.googlesource.com/c/1414857
Reviewed-by: Colin Blundell <blundell@chromium.org>
Reviewed-by: Mihai Sardarescu <msarda@chromium.org>
Commit-Queue: Mario Sanchez Prada <mario@igalia.com>
Cr-Commit-Position: refs/heads/master@{#624070}
[modify] https://crrev.com/76ec273db6e52343010095b5d031b89753193a05/chrome/browser/ui/webui/signin/inline_login_handler_impl.cc

Comment 9 by ma...@igalia.com, Jan 18 (4 days ago)

Status: Fixed (was: Started)

Sign in to add a comment